diff --git a/.github/workflows/airbyte-ci-release.yml b/.github/workflows/airbyte-ci-release.yml index aad8f7629559c..026d54801b95d 100644 --- a/.github/workflows/airbyte-ci-release.yml +++ b/.github/workflows/airbyte-ci-release.yml @@ -54,7 +54,7 @@ jobs: working-directory: airbyte-ci/connectors/pipelines/ run: poetry run poe build-release-binary ${{ env.BINARY_FILE_NAME }} - - uses: actions/upload-artifact@v2 + - uses: actions/upload-artifact@v3 with: name: airbyte-ci-${{ matrix.os }}-${{ steps.get_short_sha.outputs.sha }} path: airbyte-ci/connectors/pipelines/dist/${{ env.BINARY_FILE_NAME }} diff --git a/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/AirbyteConnectorRunner.kt b/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/AirbyteConnectorRunner.kt index 1ebccfac61e33..4dd9866911998 100644 --- a/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/AirbyteConnectorRunner.kt +++ b/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/AirbyteConnectorRunner.kt @@ -5,6 +5,7 @@ import io.airbyte.cdk.command.ConnectorCommandLinePropertySource import io.airbyte.cdk.command.MetadataYamlPropertySource import io.micronaut.configuration.picocli.MicronautFactory import io.micronaut.context.ApplicationContext +import io.micronaut.context.RuntimeBeanDefinition import io.micronaut.context.env.CommandLinePropertySource import io.micronaut.context.env.Environment import io.micronaut.core.cli.CommandLine as MicronautCommandLine @@ -17,8 +18,11 @@ import picocli.CommandLine.Model.UsageMessageSpec /** Source connector entry point. */ class AirbyteSourceRunner( + /** CLI args. */ args: Array, -) : AirbyteConnectorRunner("source", args) { + /** Micronaut bean definition overrides, used only for tests. */ + vararg testBeanDefinitions: RuntimeBeanDefinition<*>, +) : AirbyteConnectorRunner("source", args, testBeanDefinitions) { companion object { @JvmStatic fun run(vararg args: String) { @@ -29,8 +33,11 @@ class AirbyteSourceRunner( /** Destination connector entry point. */ class AirbyteDestinationRunner( + /** CLI args. */ args: Array, -) : AirbyteConnectorRunner("destination", args) { + /** Micronaut bean definition overrides, used only for tests. */ + vararg testBeanDefinitions: RuntimeBeanDefinition<*>, +) : AirbyteConnectorRunner("destination", args, testBeanDefinitions) { companion object { @JvmStatic fun run(vararg args: String) { @@ -46,6 +53,7 @@ class AirbyteDestinationRunner( sealed class AirbyteConnectorRunner( val connectorType: String, val args: Array, + val testBeanDefinitions: Array>, ) { val envs: Array = arrayOf(Environment.CLI, connectorType) @@ -65,11 +73,12 @@ sealed class AirbyteConnectorRunner( commandLinePropertySource, MetadataYamlPropertySource(), ) + .beanDefinitions(*testBeanDefinitions) .start() val isTest: Boolean = ctx.environment.activeNames.contains(Environment.TEST) val picocliFactory: CommandLine.IFactory = MicronautFactory(ctx) val picocliCommandLine: CommandLine = - picocliCommandLineFactory.build(picocliFactory, isTest) + picocliCommandLineFactory.build(picocliFactory) val exitCode: Int = picocliCommandLine.execute(*args) if (!isTest) { // Required by the platform, otherwise syncs may hang. @@ -82,10 +91,7 @@ sealed class AirbyteConnectorRunner( class PicocliCommandLineFactory( val runner: AirbyteConnectorRunner, ) { - inline fun build( - factory: CommandLine.IFactory, - isTest: Boolean, - ): CommandLine { + inline fun build(factory: CommandLine.IFactory): CommandLine { val commandSpec: CommandLine.Model.CommandSpec = CommandLine.Model.CommandSpec.wrapWithoutInspection(R::class.java, factory) .name("airbyte-${runner.connectorType}-connector") @@ -95,10 +101,6 @@ class PicocliCommandLineFactory( .addOption(config) .addOption(catalog) .addOption(state) - - if (isTest) { - commandSpec.addOption(output) - } return CommandLine(commandSpec, factory) } @@ -168,10 +170,4 @@ class PicocliCommandLineFactory( "path to the json-encoded state file", "Required by the following commands: read", ) - val output: OptionSpec = - fileOption( - "output", - "path to the output file", - "When present, the connector writes to this file instead of stdout", - ) } diff --git a/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/command/ConnectorCommandLinePropertySource.kt b/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/command/ConnectorCommandLinePropertySource.kt index d4fd9c5a4527b..0dd3f8bb3a987 100644 --- a/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/command/ConnectorCommandLinePropertySource.kt +++ b/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/command/ConnectorCommandLinePropertySource.kt @@ -23,7 +23,6 @@ class ConnectorCommandLinePropertySource( const val CONNECTOR_CONFIG_PREFIX: String = "airbyte.connector.config" const val CONNECTOR_CATALOG_PREFIX: String = "airbyte.connector.catalog" const val CONNECTOR_STATE_PREFIX: String = "airbyte.connector.state" -const val CONNECTOR_OUTPUT_FILE = "airbyte.connector.output.file" private fun resolveValues( commandLine: CommandLine, @@ -39,7 +38,6 @@ private fun resolveValues( } val values: MutableMap = mutableMapOf() values[Operation.PROPERTY] = ops.first() - commandLine.optionValue("output")?.let { values[CONNECTOR_OUTPUT_FILE] = it } for ((cliOptionKey, prefix) in mapOf( "config" to CONNECTOR_CONFIG_PREFIX, diff --git a/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/output/OutputConsumer.kt b/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/output/OutputConsumer.kt index 29849b1408f49..71c0e2025a4b8 100644 --- a/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/output/OutputConsumer.kt +++ b/airbyte-cdk/bulk/core/base/src/main/kotlin/io/airbyte/cdk/output/OutputConsumer.kt @@ -25,9 +25,7 @@ import io.micronaut.context.annotation.Value import io.micronaut.context.env.Environment import jakarta.inject.Singleton import java.io.ByteArrayOutputStream -import java.io.FileOutputStream import java.io.PrintStream -import java.nio.file.Path import java.time.Clock import java.time.Instant import java.util.concurrent.ConcurrentHashMap @@ -104,9 +102,6 @@ interface OutputConsumer : Consumer, AutoCloseable { /** Configuration properties prefix for [StdoutOutputConsumer]. */ const val CONNECTOR_OUTPUT_PREFIX = "airbyte.connector.output" -// Used for integration tests. -const val CONNECTOR_OUTPUT_FILE = "$CONNECTOR_OUTPUT_PREFIX.file" - /** Default implementation of [OutputConsumer]. */ @Singleton @Secondary @@ -293,10 +288,4 @@ private class RecordTemplate( private class PrintStreamFactory { @Singleton @Requires(notEnv = [Environment.TEST]) fun stdout(): PrintStream = System.out - - @Singleton - @Requires(env = [Environment.TEST]) - @Requires(property = CONNECTOR_OUTPUT_FILE) - fun file(@Value("\${$CONNECTOR_OUTPUT_FILE}") filePath: Path): PrintStream = - PrintStream(FileOutputStream(filePath.toFile()), false, Charsets.UTF_8) } diff --git a/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunnable.kt b/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunnable.kt new file mode 100644 index 0000000000000..a78d7624182a5 --- /dev/null +++ b/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunnable.kt @@ -0,0 +1,27 @@ +/* + * Copyright (c) 2024 Airbyte, Inc., all rights reserved. + */ + +package io.airbyte.cdk.command + +import io.airbyte.cdk.output.BufferingOutputConsumer +import io.airbyte.protocol.models.v0.AirbyteMessage + +/** Convenience object for return values in [CliRunner]. */ +data class CliRunnable( + val runnable: Runnable, + val results: BufferingOutputConsumer, +) { + + /** Decorates the [BufferingOutputConsumer] with a callback, which should return quickly. */ + fun withCallback(nonBlockingFn: (AirbyteMessage) -> Unit): CliRunnable { + results.callback = nonBlockingFn + return this + } + + /** Runs the [Runnable]. */ + fun run(): BufferingOutputConsumer { + runnable.run() + return results + } +} diff --git a/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunner.kt b/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunner.kt index dd5eba61417da..fa7666a8f240a 100644 --- a/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunner.kt +++ b/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunner.kt @@ -5,19 +5,22 @@ import io.airbyte.cdk.AirbyteConnectorRunnable import io.airbyte.cdk.AirbyteConnectorRunner import io.airbyte.cdk.AirbyteDestinationRunner import io.airbyte.cdk.AirbyteSourceRunner -import io.airbyte.cdk.ClockFactory import io.airbyte.cdk.output.BufferingOutputConsumer import io.airbyte.cdk.util.Jsons import io.airbyte.protocol.models.v0.AirbyteMessage import io.airbyte.protocol.models.v0.AirbyteStateMessage import io.airbyte.protocol.models.v0.ConfiguredAirbyteCatalog +import io.micronaut.context.RuntimeBeanDefinition +import java.io.ByteArrayInputStream +import java.io.ByteArrayOutputStream +import java.io.InputStream import java.nio.file.Files import java.nio.file.Path import kotlin.io.path.deleteIfExists data object CliRunner { /** - * Runs a source connector with the given arguments and returns the results. + * Builds a [CliRunnable] which runs a source connector with the given arguments. * * This is useful for writing connector integration tests: * - the [config], [catalog] and [state] get written to temporary files; @@ -26,61 +29,88 @@ data object CliRunner { * - that file name gets passed with the test-only `--output` CLI argument; * - [AirbyteSourceRunner] takes the CLI arguments and runs them in a new Micronaut context; * - after it's done, the output file contents are read and parsed into [AirbyteMessage]s. - * - those are stored in a [BufferingOutputConsumer] which is returned. + * - those are stored in the [BufferingOutputConsumer] which is returned in the [CliRunnable]. */ - fun runSource( + fun source( op: String, config: ConfigurationJsonObjectBase? = null, catalog: ConfiguredAirbyteCatalog? = null, state: List? = null, - ): BufferingOutputConsumer = - runConnector(op, config, catalog, state) { args: Array -> - AirbyteSourceRunner(args) - } + ): CliRunnable { + val out = CliRunnerOutputStream() + val runnable: Runnable = + makeRunnable(op, config, catalog, state) { args: Array -> + AirbyteSourceRunner(args, out.beanDefinition) + } + return CliRunnable(runnable, out.results) + } - /** Same as [runSource] but for destinations. */ - fun runDestination( + /** Same as [source] but for destinations. */ + fun destination( op: String, config: ConfigurationJsonObjectBase? = null, catalog: ConfiguredAirbyteCatalog? = null, state: List? = null, - ): BufferingOutputConsumer = - runConnector(op, config, catalog, state) { args: Array -> - AirbyteDestinationRunner(args) - } + inputStream: InputStream, + ): CliRunnable { + val inputBeanDefinition: RuntimeBeanDefinition = + RuntimeBeanDefinition.builder(InputStream::class.java) { inputStream } + .singleton(true) + .build() + val out = CliRunnerOutputStream() + val runnable: Runnable = + makeRunnable(op, config, catalog, state) { args: Array -> + AirbyteDestinationRunner(args, inputBeanDefinition, out.beanDefinition) + } + return CliRunnable(runnable, out.results) + } + + /** Same as the other [destination] but with [AirbyteMessage] input. */ + fun destination( + op: String, + config: ConfigurationJsonObjectBase? = null, + catalog: ConfiguredAirbyteCatalog? = null, + state: List? = null, + vararg input: AirbyteMessage, + ): CliRunnable { + val inputJsonBytes: ByteArray = + ByteArrayOutputStream().use { baos -> + for (msg in input) { + Jsons.writeValue(baos, msg) + baos.write('\n'.code) + } + baos.toByteArray() + } + val inputStream: InputStream = ByteArrayInputStream(inputJsonBytes) + return destination(op, config, catalog, state, inputStream) + } - private fun runConnector( + private fun makeRunnable( op: String, config: ConfigurationJsonObjectBase?, catalog: ConfiguredAirbyteCatalog?, state: List?, connectorRunnerConstructor: (Array) -> AirbyteConnectorRunner, - ): BufferingOutputConsumer { - val result = BufferingOutputConsumer(ClockFactory().fixed()) + ): Runnable { val configFile: Path? = inputFile(config) val catalogFile: Path? = inputFile(catalog) val stateFile: Path? = inputFile(state) - val outputFile: Path = Files.createTempFile(null, null) val args: List = listOfNotNull( "--$op", configFile?.let { "--config=$it" }, catalogFile?.let { "--catalog=$it" }, stateFile?.let { "--state=$it" }, - "--output=$outputFile", ) - try { - connectorRunnerConstructor(args.toTypedArray()).run() - Files.readAllLines(outputFile) - .filter { it.isNotBlank() } - .map { Jsons.readValue(it, AirbyteMessage::class.java) } - .forEach { result.accept(it) } - return result - } finally { - configFile?.deleteIfExists() - catalogFile?.deleteIfExists() - stateFile?.deleteIfExists() - outputFile.deleteIfExists() + val runner: AirbyteConnectorRunner = connectorRunnerConstructor(args.toTypedArray()) + return Runnable { + try { + runner.run() + } finally { + configFile?.deleteIfExists() + catalogFile?.deleteIfExists() + stateFile?.deleteIfExists() + } } } diff --git a/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunnerOutputStream.kt b/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunnerOutputStream.kt new file mode 100644 index 0000000000000..4472699622dcf --- /dev/null +++ b/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/command/CliRunnerOutputStream.kt @@ -0,0 +1,50 @@ +/* + * Copyright (c) 2024 Airbyte, Inc., all rights reserved. + */ + +package io.airbyte.cdk.command + +import io.airbyte.cdk.ClockFactory +import io.airbyte.cdk.output.BufferingOutputConsumer +import io.airbyte.cdk.util.Jsons +import io.airbyte.protocol.models.v0.AirbyteMessage +import io.micronaut.context.RuntimeBeanDefinition +import java.io.ByteArrayOutputStream +import java.io.OutputStream +import java.io.PrintStream + +/** Used by [CliRunner] to populate a [BufferingOutputConsumer] instance. */ +class CliRunnerOutputStream : OutputStream() { + + val results = BufferingOutputConsumer(ClockFactory().fixed()) + private val lineStream = ByteArrayOutputStream() + private val printStream = PrintStream(this, true, Charsets.UTF_8) + + val beanDefinition: RuntimeBeanDefinition = + RuntimeBeanDefinition.builder(PrintStream::class.java) { printStream } + .singleton(true) + .build() + + override fun write(b: Int) { + if (b == '\n'.code) { + readLine() + } else { + lineStream.write(b) + } + } + + override fun close() { + readLine() + lineStream.close() + results.close() + super.close() + } + + private fun readLine() { + val line: String = lineStream.toString(Charsets.UTF_8).trim() + lineStream.reset() + if (line.isNotBlank()) { + results.accept(Jsons.readValue(line, AirbyteMessage::class.java)) + } + } +} diff --git a/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/output/BufferingOutputConsumer.kt b/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/output/BufferingOutputConsumer.kt index 4ec1779c1c0b2..26a93fe180477 100644 --- a/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/output/BufferingOutputConsumer.kt +++ b/airbyte-cdk/bulk/core/base/src/testFixtures/kotlin/io/airbyte/cdk/output/BufferingOutputConsumer.kt @@ -20,7 +20,6 @@ import java.time.Instant /** [OutputConsumer] implementation for unit tests. Collects everything into thread-safe buffers. */ @Singleton @Requires(notEnv = [Environment.CLI]) -@Requires(missingProperty = CONNECTOR_OUTPUT_FILE) @Replaces(OutputConsumer::class) class BufferingOutputConsumer( clock: Clock, @@ -36,6 +35,11 @@ class BufferingOutputConsumer( private val traces = mutableListOf() private val messages = mutableListOf() + var callback: (AirbyteMessage) -> Unit = {} + set(value) { + synchronized(this) { field = value } + } + override fun accept(input: AirbyteMessage) { // Deep copy the input, which may be reused and mutated later on. val m: AirbyteMessage = @@ -52,6 +56,7 @@ class BufferingOutputConsumer( AirbyteMessage.Type.TRACE -> traces.add(m.trace) else -> TODO("${m.type} not supported") } + callback(m) } } diff --git a/airbyte-cdk/bulk/core/extract/src/testFixtures/kotlin/io/airbyte/cdk/command/SyncsTestFixture.kt b/airbyte-cdk/bulk/core/extract/src/testFixtures/kotlin/io/airbyte/cdk/command/SyncsTestFixture.kt index 3bf5015426b41..671c9777c8ffd 100644 --- a/airbyte-cdk/bulk/core/extract/src/testFixtures/kotlin/io/airbyte/cdk/command/SyncsTestFixture.kt +++ b/airbyte-cdk/bulk/core/extract/src/testFixtures/kotlin/io/airbyte/cdk/command/SyncsTestFixture.kt @@ -25,7 +25,7 @@ import org.junit.jupiter.api.Assertions data object SyncsTestFixture { fun testSpec(expectedSpec: ConnectorSpecification) { val expected: String = Jsons.writeValueAsString(expectedSpec) - val output: BufferingOutputConsumer = CliRunner.runSource("spec") + val output: BufferingOutputConsumer = CliRunner.source("spec").run() val actual: String = Jsons.writeValueAsString(output.specs().last()) val jsonMatcher: JsonMatcher = @@ -52,7 +52,7 @@ data object SyncsTestFixture { configPojo: ConfigurationJsonObjectBase, expectedFailure: String? = null, ) { - val checkOutput: BufferingOutputConsumer = CliRunner.runSource("check", configPojo) + val checkOutput: BufferingOutputConsumer = CliRunner.source("check", configPojo).run() Assertions.assertEquals(1, checkOutput.statuses().size, checkOutput.statuses().toString()) if (expectedFailure == null) { Assertions.assertEquals( @@ -73,7 +73,7 @@ data object SyncsTestFixture { configPojo: ConfigurationJsonObjectBase, expectedCatalog: AirbyteCatalog, ) { - val discoverOutput: BufferingOutputConsumer = CliRunner.runSource("discover", configPojo) + val discoverOutput: BufferingOutputConsumer = CliRunner.source("discover", configPojo).run() Assertions.assertEquals(listOf(expectedCatalog), discoverOutput.catalogs()) } @@ -102,7 +102,7 @@ data object SyncsTestFixture { var state: List = initialState for (step in afterRead) { val readOutput: BufferingOutputConsumer = - CliRunner.runSource("read", configPojo, configuredCatalog, state) + CliRunner.source("read", configPojo, configuredCatalog, state).run() step.validate(readOutput) connectionSupplier.get().use(step::update) state = readOutput.states() @@ -141,7 +141,7 @@ data object SyncsTestFixture { var state: List = listOf() for (step in afterRead) { val readOutput: BufferingOutputConsumer = - CliRunner.runSource("read", configPojo, configuredCatalog, state) + CliRunner.source("read", configPojo, configuredCatalog, state).run() step.validate(readOutput) connectionSupplier.get().use(step::update) state = readOutput.states() diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/check/CheckOperation.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/check/CheckOperation.kt new file mode 100644 index 0000000000000..5da8da2df22fe --- /dev/null +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/check/CheckOperation.kt @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2024 Airbyte, Inc., all rights reserved. + */ + +package io.airbyte.cdk.check + +import io.airbyte.cdk.Operation +import io.airbyte.cdk.output.ExceptionHandler +import io.micronaut.context.annotation.Requires +import jakarta.inject.Singleton + +@Singleton +@Requires(property = Operation.PROPERTY, value = "check") +@Requires(env = ["destination"]) +class CheckOperation( + private val destination: DestinationCheck, + private val exceptionHandler: ExceptionHandler, +) : Operation { + override fun execute() { + try { + destination.check() + } catch (e: Exception) { + exceptionHandler.handle(e) + } finally { + destination.cleanup() + } + } +} diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/check/DestinationCheck.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/check/DestinationCheck.kt new file mode 100644 index 0000000000000..bbf07446fe37b --- /dev/null +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/check/DestinationCheck.kt @@ -0,0 +1,10 @@ +/* + * Copyright (c) 2024 Airbyte, Inc., all rights reserved. + */ + +package io.airbyte.cdk.check + +interface DestinationCheck { + fun check() + fun cleanup() {} +} diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/state/MemoryManager.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/state/MemoryManager.kt index d191223b08fd6..f5511f58fcc1e 100644 --- a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/state/MemoryManager.kt +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/state/MemoryManager.kt @@ -19,7 +19,7 @@ import kotlinx.coroutines.sync.withLock * TODO: Some degree of logging/monitoring around how accurate we're actually being? */ @Singleton -class MemoryManager(availableMemoryProvider: AvailableMemoryProvider) { +class MemoryManager(private val availableMemoryProvider: AvailableMemoryProvider) { private val totalMemoryBytes: Long = availableMemoryProvider.availableMemoryBytes private var usedMemoryBytes = AtomicLong(0L) private val mutex = Mutex() diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/OpenStreamTask.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/OpenStreamTask.kt index b36f64c14a160..ffd56eb48d272 100644 --- a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/OpenStreamTask.kt +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/OpenStreamTask.kt @@ -5,13 +5,13 @@ package io.airbyte.cdk.task import io.airbyte.cdk.command.DestinationStream -import io.airbyte.cdk.write.Destination +import io.airbyte.cdk.write.DestinationWrite import io.airbyte.cdk.write.StreamLoader import io.micronaut.context.annotation.Secondary import jakarta.inject.Singleton /** - * Wraps @[StreamLoader.open] and starts the spill-to-disk tasks. + * Wraps @[StreamLoader.start] and starts the spill-to-disk tasks. * * TODO: There's no reason to wait on initialization to start spilling to disk. */ @@ -20,7 +20,7 @@ class OpenStreamTask( private val taskLauncher: DestinationTaskLauncher ) : Task { override suspend fun execute() { - streamLoader.open() + streamLoader.start() taskLauncher.startSpillToDiskTasks(streamLoader) } } @@ -28,7 +28,7 @@ class OpenStreamTask( @Singleton @Secondary class OpenStreamTaskFactory( - private val destination: Destination, + private val destination: DestinationWrite, ) { fun make(taskLauncher: DestinationTaskLauncher, stream: DestinationStream): OpenStreamTask { return OpenStreamTask(destination.getStreamLoader(stream), taskLauncher) diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/SetupTask.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/SetupTask.kt index 5b6f4e6dd6e5c..881c311208e1c 100644 --- a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/SetupTask.kt +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/SetupTask.kt @@ -4,18 +4,18 @@ package io.airbyte.cdk.task -import io.airbyte.cdk.write.Destination +import io.airbyte.cdk.write.DestinationWrite import io.micronaut.context.annotation.Secondary import jakarta.inject.Singleton /** - * Wraps @[Destination.setup] and starts the open stream tasks. + * Wraps @[DestinationWrite.setup] and starts the open stream tasks. * * TODO: This should call something like "TaskLauncher.setupComplete" and let it decide what to do * next. */ class SetupTask( - private val destination: Destination, + private val destination: DestinationWrite, private val taskLauncher: DestinationTaskLauncher ) : Task { override suspend fun execute() { @@ -27,7 +27,7 @@ class SetupTask( @Singleton @Secondary class SetupTaskFactory( - private val destination: Destination, + private val destination: DestinationWrite, ) { fun make(taskLauncher: DestinationTaskLauncher): SetupTask { return SetupTask(destination, taskLauncher) diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/TeardownTask.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/TeardownTask.kt index 5d76c2b260f98..d715cc5527f88 100644 --- a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/TeardownTask.kt +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/task/TeardownTask.kt @@ -5,19 +5,19 @@ package io.airbyte.cdk.task import io.airbyte.cdk.state.StreamsManager -import io.airbyte.cdk.write.Destination +import io.airbyte.cdk.write.DestinationWrite import io.github.oshai.kotlinlogging.KotlinLogging import io.micronaut.context.annotation.Secondary import jakarta.inject.Singleton import java.util.concurrent.atomic.AtomicBoolean /** - * Wraps @[Destination.teardown] and stops the task launcher. + * Wraps @[DestinationWrite.teardown] and stops the task launcher. * * TODO: Report teardown-complete and let the task launcher decide what to do next. */ class TeardownTask( - private val destination: Destination, + private val destination: DestinationWrite, private val streamsManager: StreamsManager, private val taskLauncher: DestinationTaskLauncher ) : Task { @@ -44,7 +44,7 @@ class TeardownTask( @Singleton @Secondary class TeardownTaskFactory( - private val destination: Destination, + private val destination: DestinationWrite, private val streamsManager: StreamsManager, ) { fun make(taskLauncher: DestinationTaskLauncher): TeardownTask { diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/Destination.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/DestinationWrite.kt similarity index 54% rename from airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/Destination.kt rename to airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/DestinationWrite.kt index db610ec8716ab..a0bab2df82bcc 100644 --- a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/Destination.kt +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/DestinationWrite.kt @@ -9,26 +9,30 @@ import io.micronaut.context.annotation.Secondary import jakarta.inject.Singleton /** - * Implementor interface. Extended this only if you need to perform initialization and teardown - * *across all streams*, or if your per-stream operations need shared global state. - * - * If initialization can be done on a per-stream basis, implement @[StreamLoaderFactory] instead. + * Implementor interface. Every Destination must extend this and at least provide an implementation + * of [getStreamLoader]. */ -interface Destination { +interface DestinationWrite { // Called once before anything else suspend fun setup() {} // Return a StreamLoader for the given stream fun getStreamLoader(stream: DestinationStream): StreamLoader - // Called once at the end of the job + // Called once at the end of the job, unconditionally. suspend fun teardown(succeeded: Boolean = true) {} } @Singleton @Secondary -class DefaultDestination(private val streamLoaderFactory: StreamLoaderFactory) : Destination { +class DefaultDestinationWrite : DestinationWrite { + init { + throw NotImplementedError( + "DestinationWrite not implemented. Please create a custom @Singleton implementation." + ) + } + override fun getStreamLoader(stream: DestinationStream): StreamLoader { - return streamLoaderFactory.make(stream) + throw NotImplementedError() } } diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/InputConsumer.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/InputConsumer.kt index 9adb2bc4ffc23..898d9889692ff 100644 --- a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/InputConsumer.kt +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/InputConsumer.kt @@ -9,7 +9,6 @@ import io.airbyte.cdk.message.DestinationMessage import io.airbyte.cdk.message.MessageQueueWriter import io.github.oshai.kotlinlogging.KLogger import io.github.oshai.kotlinlogging.KotlinLogging -import io.micronaut.context.annotation.Factory import jakarta.inject.Singleton import java.io.InputStream import java.nio.charset.StandardCharsets @@ -63,12 +62,3 @@ class DefaultInputConsumer( ) : DeserializingInputStreamConsumer { override val log = KotlinLogging.logger {} } - -/** Override to provide a custom input stream. */ -@Factory -class InputStreamFactory { - @Singleton - fun make(): InputStream { - return System.`in` - } -} diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/StreamLoader.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/StreamLoader.kt index d038eeea985e0..6e35c0cea99f1 100644 --- a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/StreamLoader.kt +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/StreamLoader.kt @@ -8,61 +8,35 @@ import io.airbyte.cdk.command.DestinationStream import io.airbyte.cdk.message.Batch import io.airbyte.cdk.message.DestinationRecord import io.airbyte.cdk.message.SimpleBatch -import io.github.oshai.kotlinlogging.KotlinLogging -import io.micronaut.context.annotation.Secondary -import jakarta.inject.Singleton /** * Implementor interface. The framework calls open and close once per stream at the beginning and * end of processing. The framework calls processRecords once per batch of records as batches of the * configured size become available. (Specified in @ - * [io.airbyte.cdk.command.WriteConfiguration.recordBatchSizeBytes] + * [io.airbyte.cdk.command.WriteConfiguration.recordBatchSizeBytes]) * - * processBatch is called once per incomplete batch returned by either processRecords or - * processBatch itself. See @[io.airbyte.cdk.message.Batch] for more details. + * [start] is called once before any records are processed. + * + * [processRecords] is called whenever a batch of records is available for processing, and only + * after [start] has returned successfully. The return value is a client-defined implementation of @ + * [Batch] that the framework may pass to [processBatch] and/or [finalize]. (See @[Batch] for more + * details.) + * + * [processBatch] is called once per incomplete batch returned by either [processRecords] or + * [processBatch] itself. + * + * [finalize] is called once after all records and batches have been processed successfully. + * + * [close] is called once after all records have been processed, regardless of success or failure. + * If there are failed batches, they are passed in as an argument. */ interface StreamLoader { val stream: DestinationStream - suspend fun open() {} + suspend fun start() {} suspend fun processRecords(records: Iterator, totalSizeBytes: Long): Batch - suspend fun processBatch(batch: Batch): Batch = SimpleBatch(state = Batch.State.COMPLETE) - suspend fun close() {} -} - -/** - * Default stream loader (Not yet implemented) will process the records into a locally staged file - * of a format specified in the configuration. - */ -class DefaultStreamLoader( - override val stream: DestinationStream, -) : StreamLoader { - val log = KotlinLogging.logger {} - - override suspend fun processRecords( - records: Iterator, - totalSizeBytes: Long - ): Batch { - TODO( - "Default implementation adds airbyte metadata, maybe flattens, no-op maps, and converts to destination format" - ) - } -} - -/** - * If you do not need to perform initialization and teardown across all streams, or if your - * per-stream operations do not need shared global state, implement this interface instead of @ - * [Destination]. The framework will call it exactly once per stream to create instances that will - * be used for the life cycle of the stream. - */ -interface StreamLoaderFactory { - fun make(stream: DestinationStream): StreamLoader -} + suspend fun processBatch(batch: Batch): Batch = SimpleBatch(Batch.State.COMPLETE) + suspend fun finalize() {} -@Singleton -@Secondary -class DefaultStreamLoaderFactory() : StreamLoaderFactory { - override fun make(stream: DestinationStream): StreamLoader { - TODO("See above") - } + suspend fun close(failedBatches: List = emptyList()) {} } diff --git a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/WriteOperation.kt b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/WriteOperation.kt index 69fa3dfacc43b..13f7a0035777b 100644 --- a/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/WriteOperation.kt +++ b/airbyte-cdk/bulk/core/load/src/main/kotlin/io/airbyte/cdk/write/WriteOperation.kt @@ -8,7 +8,10 @@ import io.airbyte.cdk.Operation import io.airbyte.cdk.message.DestinationMessage import io.airbyte.cdk.task.TaskLauncher import io.airbyte.cdk.task.TaskRunner +import io.micronaut.context.annotation.Factory import io.micronaut.context.annotation.Requires +import io.micronaut.context.annotation.Secondary +import java.io.InputStream import javax.inject.Singleton import kotlinx.coroutines.launch import kotlinx.coroutines.runBlocking @@ -34,3 +37,14 @@ class WriteOperation( } } } + +/** Override to provide a custom input stream. */ +@Factory +class InputStreamFactory { + @Singleton + @Secondary + @Requires(property = Operation.PROPERTY, value = "write") + fun make(): InputStream { + return System.`in` + } +} diff --git a/airbyte-cdk/java/airbyte-cdk/README.md b/airbyte-cdk/java/airbyte-cdk/README.md index 0b5c423cca465..7e2423a22d08a 100644 --- a/airbyte-cdk/java/airbyte-cdk/README.md +++ b/airbyte-cdk/java/airbyte-cdk/README.md @@ -173,7 +173,8 @@ corresponds to that version. ### Java CDK | Version | Date | Pull Request | Subject | -| :--------- | :--------- | :----------------------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------- | +|:-----------|:-----------| :----------------------------------------------------------- |:---------------------------------------------------------------------------------------------------------------------------------------------------------------| +| 0.44.22 | 2024-09-10 | [\#45368](https://github.com/airbytehq/airbyte/pull/45368) | Remove excessive debezium logging | | 0.44.21 | 2024-09-04 | [\#45143](https://github.com/airbytehq/airbyte/pull/45143) | S3-destination: don't overwrite existing files, skip those file indexes instead | | 0.44.20 | 2024-08-30 | [\#44933](https://github.com/airbytehq/airbyte/pull/44933) | Avro/Parquet destinations: handle `{}` schemas inside objects/arrays | | 0.44.19 | 2024-08-20 | [\#44476](https://github.com/airbytehq/airbyte/pull/44476) | Increase Jackson message length limit to 100mb | diff --git a/airbyte-cdk/java/airbyte-cdk/core/src/main/resources/version.properties b/airbyte-cdk/java/airbyte-cdk/core/src/main/resources/version.properties index 5590734237c54..59f915c094124 100644 --- a/airbyte-cdk/java/airbyte-cdk/core/src/main/resources/version.properties +++ b/airbyte-cdk/java/airbyte-cdk/core/src/main/resources/version.properties @@ -1 +1 @@ -version=0.44.21 +version=0.44.22 diff --git a/airbyte-cdk/java/airbyte-cdk/db-sources/src/main/kotlin/io/airbyte/cdk/integrations/debezium/internals/DebeziumRecordIterator.kt b/airbyte-cdk/java/airbyte-cdk/db-sources/src/main/kotlin/io/airbyte/cdk/integrations/debezium/internals/DebeziumRecordIterator.kt index e035a84745321..817d6fa8ef6e6 100644 --- a/airbyte-cdk/java/airbyte-cdk/db-sources/src/main/kotlin/io/airbyte/cdk/integrations/debezium/internals/DebeziumRecordIterator.kt +++ b/airbyte-cdk/java/airbyte-cdk/db-sources/src/main/kotlin/io/airbyte/cdk/integrations/debezium/internals/DebeziumRecordIterator.kt @@ -174,7 +174,6 @@ class DebeziumRecordIterator( // #41647: discard event type with op code 'm' if (!isEventTypeHandled(changeEventWithMetadata)) { - LOGGER.info { "WAL event type not handled: $next" } continue } @@ -332,7 +331,7 @@ class DebeziumRecordIterator( companion object { val pollLogMaxTimeInterval: Duration = Duration.ofSeconds(5) const val POLL_LOG_MAX_CALLS_INTERVAL = 1_000 - + private val unhandledFoundTypeList: MutableList = mutableListOf() /** * We are not interested in message events. According to debezium * [documentation](https://debezium.io/documentation/reference/stable/connectors/postgresql.html#postgresql-create-events) @@ -341,7 +340,13 @@ class DebeziumRecordIterator( */ fun isEventTypeHandled(event: ChangeEventWithMetadata): Boolean { event.eventValueAsJson?.get("op")?.asText()?.let { - return it in listOf("c", "u", "d", "t") + val handled = it in listOf("c", "u", "d", "t") + if (!handled && !unhandledFoundTypeList.contains(it)) { + unhandledFoundTypeList.add(it) + LOGGER.info { "WAL event type not handled: $it" } + LOGGER.debug { "event: $event" } + } + return handled } ?: return false } diff --git a/airbyte-cdk/python/CHANGELOG.md b/airbyte-cdk/python/CHANGELOG.md index 129ebc999eb3c..436973978f3f2 100644 --- a/airbyte-cdk/python/CHANGELOG.md +++ b/airbyte-cdk/python/CHANGELOG.md @@ -1,5 +1,20 @@ # Changelog +## 5.5.2 +Fix pandas missing dependency + +## 5.5.1 +Bug fix: Return a connection status failure on an expected check failure + +## 5.5.0 +Declarative async job components + +## 5.4.0 +add migration of global stream_state to per_partition format + +## 5.3.0 +Connector builder: add flag to disable cache + ## 5.2.1 Fix error in incremental sync docs diff --git a/airbyte-cdk/python/airbyte_cdk/connector_builder/connector_builder_handler.py b/airbyte-cdk/python/airbyte_cdk/connector_builder/connector_builder_handler.py index cdee4f7c3574c..b3cfd9a0503b6 100644 --- a/airbyte-cdk/python/airbyte_cdk/connector_builder/connector_builder_handler.py +++ b/airbyte-cdk/python/airbyte_cdk/connector_builder/connector_builder_handler.py @@ -50,6 +50,7 @@ def create_source(config: Mapping[str, Any], limits: TestReadLimits) -> Manifest limit_pages_fetched_per_slice=limits.max_pages_per_slice, limit_slices_fetched=limits.max_slices, disable_retries=True, + disable_cache=True, ), ) diff --git a/airbyte-cdk/python/airbyte_cdk/logger.py b/airbyte-cdk/python/airbyte_cdk/logger.py index da3f869f2f323..59d4d7dd68d32 100644 --- a/airbyte-cdk/python/airbyte_cdk/logger.py +++ b/airbyte-cdk/python/airbyte_cdk/logger.py @@ -5,7 +5,7 @@ import json import logging import logging.config -from typing import Any, Mapping, Optional, Tuple +from typing import Any, Callable, Mapping, Optional, Tuple from airbyte_cdk.models import AirbyteLogMessage, AirbyteMessage, AirbyteMessageSerializer, Level, Type from airbyte_cdk.utils.airbyte_secrets_utils import filter_secrets @@ -38,6 +38,14 @@ def init_logger(name: Optional[str] = None) -> logging.Logger: return logger +def lazy_log(logger: logging.Logger, level: int, lazy_log_provider: Callable[[], str]) -> None: + """ + This method ensure that the processing of the log message is only done if the logger is enabled for the log level. + """ + if logger.isEnabledFor(level): + logger.log(level, lazy_log_provider()) + + class AirbyteLogFormatter(logging.Formatter): """Output log records using AirbyteMessage""" diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/__init__.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/__init__.py new file mode 100644 index 0000000000000..e69de29bb2d1d diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/job.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/job.py new file mode 100644 index 0000000000000..09a527b0bcb0f --- /dev/null +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/job.py @@ -0,0 +1,50 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. + + +from datetime import timedelta +from typing import Optional + +from airbyte_cdk import StreamSlice +from airbyte_cdk.sources.declarative.async_job.timer import Timer + +from .status import AsyncJobStatus + + +class AsyncJob: + """ + Description of an API job. + + Note that the timer will only stop once `update_status` is called so the job might be completed on the API side but until we query for + it and call `ApiJob.update_status`, `ApiJob.status` will not reflect the actual API side status. + """ + + def __init__(self, api_job_id: str, job_parameters: StreamSlice, timeout: Optional[timedelta] = None) -> None: + self._api_job_id = api_job_id + self._job_parameters = job_parameters + self._status = AsyncJobStatus.RUNNING + + timeout = timeout if timeout else timedelta(minutes=60) + self._timer = Timer(timeout) + self._timer.start() + + def api_job_id(self) -> str: + return self._api_job_id + + def status(self) -> AsyncJobStatus: + if self._timer.has_timed_out(): + return AsyncJobStatus.TIMED_OUT + return self._status + + def job_parameters(self) -> StreamSlice: + return self._job_parameters + + def update_status(self, status: AsyncJobStatus) -> None: + if self._status != AsyncJobStatus.RUNNING and status == AsyncJobStatus.RUNNING: + self._timer.start() + elif status.is_terminal(): + self._timer.stop() + + self._status = status + + def __repr__(self) -> str: + return f"AsyncJob(data={self.api_job_id()}, job_parameters={self.job_parameters()}, status={self.status()})" diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/job_orchestrator.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/job_orchestrator.py new file mode 100644 index 0000000000000..ec2bafdde2f16 --- /dev/null +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/job_orchestrator.py @@ -0,0 +1,241 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. + +import logging +import time +from typing import Any, Generator, Iterable, List, Mapping, Optional, Set + +from airbyte_cdk import StreamSlice +from airbyte_cdk.logger import lazy_log +from airbyte_cdk.models import FailureType +from airbyte_cdk.sources.declarative.async_job.job import AsyncJob +from airbyte_cdk.sources.declarative.async_job.repository import AsyncJobRepository +from airbyte_cdk.sources.declarative.async_job.status import AsyncJobStatus +from airbyte_cdk.utils.traced_exception import AirbyteTracedException + +LOGGER = logging.getLogger("airbyte") + + +class AsyncPartition: + """ + This bucket of api_jobs is a bit useless for this iteration but should become interesting when we will be able to split jobs + """ + + _MAX_NUMBER_OF_ATTEMPTS = 3 + + def __init__(self, jobs: List[AsyncJob], stream_slice: StreamSlice) -> None: + self._attempts_per_job = {job: 0 for job in jobs} + self._stream_slice = stream_slice + + def has_reached_max_attempt(self) -> bool: + return any(map(lambda attempt_count: attempt_count >= self._MAX_NUMBER_OF_ATTEMPTS, self._attempts_per_job.values())) + + def replace_job(self, job_to_replace: AsyncJob, new_jobs: List[AsyncJob]) -> None: + current_attempt_count = self._attempts_per_job.pop(job_to_replace, None) + if current_attempt_count is None: + raise ValueError("Could not find job to replace") + elif current_attempt_count >= self._MAX_NUMBER_OF_ATTEMPTS: + raise ValueError(f"Max attempt reached for job in partition {self._stream_slice}") + + new_attempt_count = current_attempt_count + 1 + for job in new_jobs: + self._attempts_per_job[job] = new_attempt_count + + def should_split(self, job: AsyncJob) -> bool: + """ + Not used right now but once we support job split, we should split based on the number of attempts + """ + return False + + @property + def jobs(self) -> Iterable[AsyncJob]: + return self._attempts_per_job.keys() + + @property + def stream_slice(self) -> StreamSlice: + return self._stream_slice + + @property + def status(self) -> AsyncJobStatus: + """ + Given different job statuses, the priority is: FAILED, TIMED_OUT, RUNNING. Else, it means everything is completed. + """ + statuses = set(map(lambda job: job.status(), self.jobs)) + if statuses == {AsyncJobStatus.COMPLETED}: + return AsyncJobStatus.COMPLETED + elif AsyncJobStatus.FAILED in statuses: + return AsyncJobStatus.FAILED + elif AsyncJobStatus.TIMED_OUT in statuses: + return AsyncJobStatus.TIMED_OUT + else: + return AsyncJobStatus.RUNNING + + def __repr__(self) -> str: + return f"AsyncPartition(stream_slice={self._stream_slice}, attempt_per_job={self._attempts_per_job})" + + +class AsyncJobOrchestrator: + _WAIT_TIME_BETWEEN_STATUS_UPDATE_IN_SECONDS = 5 + + def __init__( + self, + job_repository: AsyncJobRepository, + slices: Iterable[StreamSlice], + number_of_retries: Optional[int] = None, + ) -> None: + self._job_repository: AsyncJobRepository = job_repository + self._slice_iterator = iter(slices) + self._running_partitions: List[AsyncPartition] = [] + + def _replace_failed_jobs(self, partition: AsyncPartition) -> None: + failed_status_jobs = (AsyncJobStatus.FAILED, AsyncJobStatus.TIMED_OUT) + jobs_to_replace = [job for job in partition.jobs if job.status() in failed_status_jobs] + for job in jobs_to_replace: + new_job = self._job_repository.start(job.job_parameters()) + partition.replace_job(job, [new_job]) + + def _start_jobs(self) -> None: + """ + Retry failed jobs and start jobs for each slice in the slice iterator. + This method iterates over the running jobs and slice iterator and starts a job for each slice. + The started jobs are added to the running partitions. + Returns: + None + + TODO Eventually, we need to cap the number of concurrent jobs. + However, the first iteration is for sendgrid which only has one job. + """ + for partition in self._running_partitions: + self._replace_failed_jobs(partition) + + for _slice in self._slice_iterator: + job = self._job_repository.start(_slice) + self._running_partitions.append(AsyncPartition([job], _slice)) + + def _get_running_jobs(self) -> Set[AsyncJob]: + """ + Returns a set of running AsyncJob objects. + + Returns: + Set[AsyncJob]: A set of AsyncJob objects that are currently running. + """ + return {job for partition in self._running_partitions for job in partition.jobs if job.status() == AsyncJobStatus.RUNNING} + + def _update_jobs_status(self) -> None: + """ + Update the status of all running jobs in the repository. + """ + running_jobs = self._get_running_jobs() + if running_jobs: + # update the status only if there are RUNNING jobs + self._job_repository.update_jobs_status(running_jobs) + + def _wait_on_status_update(self) -> None: + """ + Waits for a specified amount of time between status updates. + + + This method is used to introduce a delay between status updates in order to avoid excessive polling. + The duration of the delay is determined by the value of `_WAIT_TIME_BETWEEN_STATUS_UPDATE_IN_SECONDS`. + + Returns: + None + """ + lazy_log( + LOGGER, + logging.DEBUG, + lambda: f"Polling status in progress. There are currently {len(self._running_partitions)} running partitions.", + ) + + # wait only when there are running partitions + if self._running_partitions: + lazy_log( + LOGGER, + logging.DEBUG, + lambda: f"Waiting for {self._WAIT_TIME_BETWEEN_STATUS_UPDATE_IN_SECONDS} seconds before next poll...", + ) + time.sleep(self._WAIT_TIME_BETWEEN_STATUS_UPDATE_IN_SECONDS) + + def _process_completed_partition(self, partition: AsyncPartition) -> None: + """ + Process a completed partition. + Args: + partition (AsyncPartition): The completed partition to process. + """ + job_ids = list(map(lambda job: job.api_job_id(), {job for job in partition.jobs})) + LOGGER.info(f"The following jobs for stream slice {partition.stream_slice} have been completed: {job_ids}.") + + def _process_running_partitions_and_yield_completed_ones(self) -> Generator[AsyncPartition, Any, None]: + """ + Process the running partitions. + + Yields: + AsyncPartition: The processed partition. + + Raises: + Any: Any exception raised during processing. + """ + current_running_partitions: List[AsyncPartition] = [] + for partition in self._running_partitions: + match partition.status: + case AsyncJobStatus.COMPLETED: + self._process_completed_partition(partition) + yield partition + case AsyncJobStatus.RUNNING: + current_running_partitions.append(partition) + case _ if partition.has_reached_max_attempt(): + self._process_partitions_with_errors(partition) + case _: + # job will be restarted in `_start_job` + current_running_partitions.insert(0, partition) + # update the referenced list with running partitions + self._running_partitions = current_running_partitions + + def _process_partitions_with_errors(self, partition: AsyncPartition) -> None: + """ + Process a partition with status errors (FAILED and TIMEOUT). + + Args: + partition (AsyncPartition): The partition to process. + Returns: + AirbyteTracedException: An exception indicating that at least one job could not be completed. + Raises: + AirbyteTracedException: If at least one job could not be completed. + """ + status_by_job_id = {job.api_job_id(): job.status() for job in partition.jobs} + raise AirbyteTracedException( + message=f"At least one job could not be completed. Job statuses were: {status_by_job_id}", + failure_type=FailureType.system_error, + ) + + def create_and_get_completed_partitions(self) -> Iterable[AsyncPartition]: + """ + Creates and retrieves completed partitions. + This method continuously starts jobs, updates job status, processes running partitions, + logs polling partitions, and waits for status updates. It yields completed partitions + as they become available. + + Returns: + An iterable of completed partitions, represented as AsyncPartition objects. + Each partition is wrapped in an Optional, allowing for None values. + """ + while True: + self._start_jobs() + if not self._running_partitions: + break + + self._update_jobs_status() + yield from self._process_running_partitions_and_yield_completed_ones() + self._wait_on_status_update() + + def fetch_records(self, partition: AsyncPartition) -> Iterable[Mapping[str, Any]]: + """ + Fetches records from the given partition's jobs. + + Args: + partition (AsyncPartition): The partition containing the jobs. + + Yields: + Iterable[Mapping[str, Any]]: The fetched records from the jobs. + """ + for job in partition.jobs: + yield from self._job_repository.fetch_records(job) diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/repository.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/repository.py new file mode 100644 index 0000000000000..2880fea163337 --- /dev/null +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/repository.py @@ -0,0 +1,21 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. + +from abc import abstractmethod +from typing import Any, Iterable, Mapping, Set + +from airbyte_cdk import StreamSlice +from airbyte_cdk.sources.declarative.async_job.job import AsyncJob + + +class AsyncJobRepository: + @abstractmethod + def start(self, stream_slice: StreamSlice) -> AsyncJob: + pass + + @abstractmethod + def update_jobs_status(self, jobs: Set[AsyncJob]) -> None: + pass + + @abstractmethod + def fetch_records(self, job: AsyncJob) -> Iterable[Mapping[str, Any]]: + pass diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/status.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/status.py new file mode 100644 index 0000000000000..586e79889ca1b --- /dev/null +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/status.py @@ -0,0 +1,24 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. + + +from enum import Enum + +_TERMINAL = True + + +class AsyncJobStatus(Enum): + RUNNING = ("RUNNING", not _TERMINAL) + COMPLETED = ("COMPLETED", _TERMINAL) + FAILED = ("FAILED", _TERMINAL) + TIMED_OUT = ("TIMED_OUT", _TERMINAL) + + def __init__(self, value: str, is_terminal: bool) -> None: + self._value = value + self._is_terminal = is_terminal + + def is_terminal(self) -> bool: + """ + A status is terminal when a job status can't be updated anymore. For example if a job is completed, it will stay completed but a + running job might because completed, failed or timed out. + """ + return self._is_terminal diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/timer.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/timer.py new file mode 100644 index 0000000000000..c4e5a9a1d85a3 --- /dev/null +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/async_job/timer.py @@ -0,0 +1,39 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. +from datetime import datetime, timedelta, timezone +from typing import Optional + + +class Timer: + def __init__(self, timeout: timedelta) -> None: + self._start_datetime: Optional[datetime] = None + self._end_datetime: Optional[datetime] = None + self._timeout = timeout + + def start(self) -> None: + self._start_datetime = self._now() + self._end_datetime = None + + def stop(self) -> None: + if self._end_datetime is None: + self._end_datetime = self._now() + + def is_started(self) -> bool: + return self._start_datetime is not None + + @property + def elapsed_time(self) -> Optional[timedelta]: + if not self._start_datetime: + return None + + end_time = self._end_datetime or self._now() + elapsed_period = end_time - self._start_datetime + return elapsed_period + + def has_timed_out(self) -> bool: + if not self.is_started(): + return False + return self.elapsed_time > self._timeout # type: ignore # given the job timer is started, we assume there is an elapsed_period + + @staticmethod + def _now() -> datetime: + return datetime.now(tz=timezone.utc) diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/declarative_component_schema.yaml b/airbyte-cdk/python/airbyte_cdk/sources/declarative/declarative_component_schema.yaml index f05c342fa68cb..9c0ea7876a930 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/declarative_component_schema.yaml +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/declarative_component_schema.yaml @@ -1156,6 +1156,7 @@ definitions: title: Retriever description: Component used to coordinate how records are extracted across stream slices and request pages. anyOf: + - "$ref": "#/definitions/AsyncRetriever" - "$ref": "#/definitions/CustomRetriever" - "$ref": "#/definitions/SimpleRetriever" incremental_sync: @@ -1194,6 +1195,7 @@ definitions: - "$ref": "#/definitions/AddFields" - "$ref": "#/definitions/CustomTransformation" - "$ref": "#/definitions/RemoveFields" + - "$ref": "#/definitions/KeysToLower" state_migrations: title: State Migrations description: Array of state migrations to be applied on the input state @@ -1690,6 +1692,19 @@ definitions: type: type: string enum: [JsonlDecoder] + KeysToLower: + title: Keys to Lower Case + description: A transformation that renames all keys to lower case. + type: object + required: + - type + properties: + type: + type: string + enum: [KeysToLower] + $parameters: + type: object + additionalProperties: true IterableDecoder: title: Iterable Decoder description: Use this if the response consists of strings separated by new lines (`\n`). The Decoder will wrap each row into a JSON object with the `record` key. @@ -2346,6 +2361,104 @@ definitions: $parameters: type: object additionalProperties: true + AsyncJobStatusMap: + description: Matches the api job status to Async Job Status. + type: object + required: + - running + - completed + - failed + - timeout + properties: + type: + type: string + enum: [AsyncJobStatusMap] + running: + type: array + items: + type: string + completed: + type: array + items: + type: string + failed: + type: array + items: + type: string + timeout: + type: array + items: + type: string + AsyncRetriever: + description: Retrieves records by Asynchronously sending requests to fetch records. The retriever acts as an orchestrator between the requester, the record selector, the paginator, and the partition router. + type: object + required: + - type + - record_selector + - status_mapping + - creation_requester + - polling_requester + - download_requester + properties: + type: + type: string + enum: [AsyncRetriever] + record_selector: + description: Component that describes how to extract records from a HTTP response. + "$ref": "#/definitions/RecordSelector" + status_mapping: + description: Async Job Status to Airbyte CDK Async Job Status mapping. + anyOf: + - "$ref": "#/definitions/AsyncJobStatusMap" + status_extractor: + description: Responsible for fetching the actual status of the async job. + anyOf: + - "$ref": "#/definitions/CustomRecordExtractor" + - "$ref": "#/definitions/DpathExtractor" + urls_extractor: + description: Responsible for fetching the final result `urls` provided by the completed / finished / ready async job. + anyOf: + - "$ref": "#/definitions/CustomRecordExtractor" + - "$ref": "#/definitions/DpathExtractor" + creation_requester: + description: Requester component that describes how to prepare HTTP requests to send to the source API to create the async server-side job. + anyOf: + - "$ref": "#/definitions/CustomRequester" + - "$ref": "#/definitions/HttpRequester" + polling_requester: + description: Requester component that describes how to prepare HTTP requests to send to the source API to fetch the status of the running async job. + anyOf: + - "$ref": "#/definitions/CustomRequester" + - "$ref": "#/definitions/HttpRequester" + download_requester: + description: Requester component that describes how to prepare HTTP requests to send to the source API to download the data provided by the completed async job. + anyOf: + - "$ref": "#/definitions/CustomRequester" + - "$ref": "#/definitions/HttpRequester" + partition_router: + title: Partition Router + description: PartitionRouter component that describes how to partition the stream, enabling incremental syncs and checkpointing. + default: [] + anyOf: + - "$ref": "#/definitions/CustomPartitionRouter" + - "$ref": "#/definitions/ListPartitionRouter" + - "$ref": "#/definitions/SubstreamPartitionRouter" + - type: array + items: + anyOf: + - "$ref": "#/definitions/CustomPartitionRouter" + - "$ref": "#/definitions/ListPartitionRouter" + - "$ref": "#/definitions/SubstreamPartitionRouter" + decoder: + title: Decoder + description: Component decoding the response so records can be extracted. + anyOf: + - "$ref": "#/definitions/JsonDecoder" + - "$ref": "#/definitions/JsonlDecoder" + - "$ref": "#/definitions/IterableDecoder" + $parameters: + type: object + additionalProperties: true Spec: title: Spec description: A source specification made up of connector metadata and how it can be configured. diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/__init__.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/__init__.py index 5c361598d351d..76304b467f435 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/__init__.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/__init__.py @@ -6,5 +6,6 @@ from airbyte_cdk.sources.declarative.extractors.http_selector import HttpSelector from airbyte_cdk.sources.declarative.extractors.record_filter import RecordFilter from airbyte_cdk.sources.declarative.extractors.record_selector import RecordSelector +from airbyte_cdk.sources.declarative.extractors.response_to_file_extractor import ResponseToFileExtractor -__all__ = ["HttpSelector", "DpathExtractor", "RecordFilter", "RecordSelector"] +__all__ = ["HttpSelector", "DpathExtractor", "RecordFilter", "RecordSelector", "ResponseToFileExtractor"] diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/http_selector.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/http_selector.py index e70ac150564cc..905477a6c6d9c 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/http_selector.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/http_selector.py @@ -3,14 +3,12 @@ # from abc import abstractmethod -from dataclasses import dataclass from typing import Any, Iterable, Mapping, Optional import requests from airbyte_cdk.sources.types import Record, StreamSlice, StreamState -@dataclass class HttpSelector: """ Responsible for translating an HTTP response into a list of records by extracting records from the response and optionally filtering diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/record_selector.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/record_selector.py index 6f9cc40478383..eed33d8582287 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/record_selector.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/record_selector.py @@ -61,6 +61,24 @@ def select_records( :return: List of Records selected from the response """ all_data: Iterable[Mapping[str, Any]] = self.extractor.extract_records(response) + yield from self.filter_and_transform(all_data, stream_state, records_schema, stream_slice, next_page_token) + + def filter_and_transform( + self, + all_data: Iterable[Mapping[str, Any]], + stream_state: StreamState, + records_schema: Mapping[str, Any], + stream_slice: Optional[StreamSlice] = None, + next_page_token: Optional[Mapping[str, Any]] = None, + ) -> Iterable[Record]: + """ + There is an issue with the selector as of 2024-08-30: it does technology-agnostic processing like filtering, transformation and + normalization with an API that is technology-specific (as requests.Response is only for HTTP communication using the requests + library). + + Until we decide to move this logic away from the selector, we made this method public so that users like AsyncJobRetriever could + share the logic of doing transformations on a set of records. + """ filtered_data = self._filter(all_data, stream_state, stream_slice, next_page_token) transformed_data = self._transform(filtered_data, stream_state, stream_slice) normalized_data = self._normalize_by_schema(transformed_data, schema=records_schema) @@ -101,6 +119,5 @@ def _transform( ) -> Iterable[Mapping[str, Any]]: for record in records: for transformation in self.transformations: - # record has type Mapping[str, Any], but Record expected - transformation.transform(record, config=self.config, stream_state=stream_state, stream_slice=stream_slice) # type: ignore + transformation.transform(record, config=self.config, stream_state=stream_state, stream_slice=stream_slice) # type: ignore # record has type Mapping[str, Any], but Dict[str, Any] expected yield record diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/response_to_file_extractor.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/response_to_file_extractor.py new file mode 100644 index 0000000000000..a177ee65240f3 --- /dev/null +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/extractors/response_to_file_extractor.py @@ -0,0 +1,162 @@ +# +# Copyright (c) 2023 Airbyte, Inc., all rights reserved. +# +import logging +import os +import uuid +import zlib +from contextlib import closing +from typing import Any, Dict, Iterable, Mapping, Optional, Tuple + +import pandas as pd +import requests +from airbyte_cdk.sources.declarative.extractors.record_extractor import RecordExtractor +from numpy import nan + +EMPTY_STR: str = "" +DEFAULT_ENCODING: str = "utf-8" +DOWNLOAD_CHUNK_SIZE: int = 1024 * 1024 * 10 + + +class ResponseToFileExtractor(RecordExtractor): + """ + This class is used when having very big HTTP responses (usually streamed) which would require too much memory so we use disk space as + a tradeoff. + + Eventually, we want to support multiple file type by re-using the file based CDK parsers if possible. However, the lift is too high for + a first iteration so we will only support CSV parsing using pandas as salesforce and sendgrid were doing. + """ + + def __init__(self) -> None: + self.logger = logging.getLogger("airbyte") + + def _get_response_encoding(self, headers: Dict[str, Any]) -> str: + """ + Get the encoding of the response based on the provided headers. This method is heavily inspired by the requests library + implementation. + + Args: + headers (Dict[str, Any]): The headers of the response. + Returns: + str: The encoding of the response. + """ + + content_type = headers.get("content-type") + + if not content_type: + return DEFAULT_ENCODING + + content_type, params = requests.utils.parse_header_links(content_type) + + if "charset" in params: + return params["charset"].strip("'\"") # type: ignore # we assume headers are returned as str + + return DEFAULT_ENCODING + + def _filter_null_bytes(self, b: bytes) -> bytes: + """ + Filter out null bytes from a bytes object. + + Args: + b (bytes): The input bytes object. + Returns: + bytes: The filtered bytes object with null bytes removed. + + Referenced Issue: + https://github.com/airbytehq/airbyte/issues/8300 + """ + + res = b.replace(b"\x00", b"") + if len(res) < len(b): + self.logger.warning("Filter 'null' bytes from string, size reduced %d -> %d chars", len(b), len(res)) + return res + + def _save_to_file(self, response: requests.Response) -> Tuple[str, str]: + """ + Saves the binary data from the given response to a temporary file and returns the filepath and response encoding. + + Args: + response (Optional[requests.Response]): The response object containing the binary data. Defaults to None. + + Returns: + Tuple[str, str]: A tuple containing the filepath of the temporary file and the response encoding. + + Raises: + ValueError: If the temporary file does not exist after saving the binary data. + """ + # set filepath for binary data from response + decompressor = zlib.decompressobj(zlib.MAX_WBITS | 32) + needs_decompression = True # we will assume at first that the response is compressed and change the flag if not + + tmp_file = str(uuid.uuid4()) + with closing(response) as response, open(tmp_file, "wb") as data_file: + response_encoding = self._get_response_encoding(dict(response.headers or {})) + for chunk in response.iter_content(chunk_size=DOWNLOAD_CHUNK_SIZE): + try: + if needs_decompression: + data_file.write(decompressor.decompress(chunk)) + needs_decompression = True + else: + data_file.write(self._filter_null_bytes(chunk)) + except zlib.error: + data_file.write(self._filter_null_bytes(chunk)) + needs_decompression = False + + # check the file exists + if os.path.isfile(tmp_file): + return tmp_file, response_encoding + else: + raise ValueError(f"The IO/Error occured while verifying binary data. Tmp file {tmp_file} doesn't exist.") + + def _read_with_chunks(self, path: str, file_encoding: str, chunk_size: int = 100) -> Iterable[Mapping[str, Any]]: + """ + Reads data from a file in chunks and yields each row as a dictionary. + + Args: + path (str): The path to the file to be read. + file_encoding (str): The encoding of the file. + chunk_size (int, optional): The size of each chunk to be read. Defaults to 100. + + Yields: + Mapping[str, Any]: A dictionary representing each row of data. + + Raises: + ValueError: If an IO/Error occurs while reading the temporary data. + """ + + try: + with open(path, "r", encoding=file_encoding) as data: + chunks = pd.read_csv(data, chunksize=chunk_size, iterator=True, dialect="unix", dtype=object) + for chunk in chunks: + chunk = chunk.replace({nan: None}).to_dict(orient="records") + for row in chunk: + yield row + except pd.errors.EmptyDataError as e: + self.logger.info(f"Empty data received. {e}") + yield from [] + except IOError as ioe: + raise ValueError(f"The IO/Error occured while reading tmp data. Called: {path}", ioe) + finally: + # remove binary tmp file, after data is read + os.remove(path) + + def extract_records(self, response: Optional[requests.Response] = None) -> Iterable[Mapping[str, Any]]: + """ + Extracts records from the given response by: + 1) Saving the result to a tmp file + 2) Reading from saved file by chunks to avoid OOM + + Args: + response (Optional[requests.Response]): The response object containing the data. Defaults to None. + + Yields: + Iterable[Mapping[str, Any]]: An iterable of mappings representing the extracted records. + + Returns: + None + """ + if response: + file_path, encoding = self._save_to_file(response) + yield from self._read_with_chunks(file_path, encoding) + else: + yield from [] diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/incremental/per_partition_cursor.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/incremental/per_partition_cursor.py index 4babf99e4a0dd..e54264fa86c7e 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/incremental/per_partition_cursor.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/incremental/per_partition_cursor.py @@ -6,12 +6,10 @@ from collections import OrderedDict from typing import Any, Callable, Iterable, Mapping, Optional, Union -from airbyte_cdk.models import FailureType from airbyte_cdk.sources.declarative.incremental.declarative_cursor import DeclarativeCursor from airbyte_cdk.sources.declarative.partition_routers.partition_router import PartitionRouter from airbyte_cdk.sources.streams.checkpoint.per_partition_key_serializer import PerPartitionKeySerializer from airbyte_cdk.sources.types import Record, StreamSlice, StreamState -from airbyte_cdk.utils import AirbyteTracedException class CursorFactory: @@ -48,6 +46,7 @@ class PerPartitionCursor(DeclarativeCursor): _NO_CURSOR_STATE: Mapping[str, Any] = {} _KEY = 0 _VALUE = 1 + _state_to_migrate_from: Mapping[str, Any] = {} def __init__(self, cursor_factory: CursorFactory, partition_router: PartitionRouter): self._cursor_factory = cursor_factory @@ -65,7 +64,8 @@ def stream_slices(self) -> Iterable[StreamSlice]: cursor = self._cursor_per_partition.get(self._to_partition_key(partition.partition)) if not cursor: - cursor = self._create_cursor(self._NO_CURSOR_STATE) + partition_state = self._state_to_migrate_from if self._state_to_migrate_from else self._NO_CURSOR_STATE + cursor = self._create_cursor(partition_state) self._cursor_per_partition[self._to_partition_key(partition.partition)] = cursor for cursor_slice in cursor.stream_slices(): @@ -113,15 +113,13 @@ def set_initial_state(self, stream_state: StreamState) -> None: return if "states" not in stream_state: - raise AirbyteTracedException( - internal_message=f"Could not sync parse the following state: {stream_state}", - message="The state for is format invalid. Validate that the migration steps included a reset and that it was performed " - "properly. Otherwise, please contact Airbyte support.", - failure_type=FailureType.config_error, - ) + # We assume that `stream_state` is in a global format that can be applied to all partitions. + # Example: {"global_state_format_key": "global_state_format_value"} + self._state_to_migrate_from = stream_state - for state in stream_state["states"]: - self._cursor_per_partition[self._to_partition_key(state["partition"])] = self._create_cursor(state["cursor"]) + else: + for state in stream_state["states"]: + self._cursor_per_partition[self._to_partition_key(state["partition"])] = self._create_cursor(state["cursor"]) # Set parent state for partition routers based on parent streams self._partition_router.set_initial_state(stream_state) diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/models/declarative_component_schema.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/models/declarative_component_schema.py index 2af4b5a0ac26b..fb42fb59a7c24 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/models/declarative_component_schema.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/models/declarative_component_schema.py @@ -613,6 +613,11 @@ class JsonlDecoder(BaseModel): type: Literal['JsonlDecoder'] +class KeysToLower(BaseModel): + type: Literal['KeysToLower'] + parameters: Optional[Dict[str, Any]] = Field(None, alias='$parameters') + + class IterableDecoder(BaseModel): type: Literal['IterableDecoder'] @@ -881,6 +886,14 @@ class LegacySessionTokenAuthenticator(BaseModel): parameters: Optional[Dict[str, Any]] = Field(None, alias='$parameters') +class AsyncJobStatusMap(BaseModel): + type: Optional[Literal['AsyncJobStatusMap']] = None + running: List[str] + completed: List[str] + failed: List[str] + timeout: List[str] + + class ValueType(Enum): string = 'string' number = 'number' @@ -1360,7 +1373,7 @@ class Config: extra = Extra.allow type: Literal['DeclarativeStream'] - retriever: Union[CustomRetriever, SimpleRetriever] = Field( + retriever: Union[AsyncRetriever, CustomRetriever, SimpleRetriever] = Field( ..., description='Component used to coordinate how records are extracted across stream slices and request pages.', title='Retriever', @@ -1386,7 +1399,7 @@ class Config: title='Schema Loader', ) transformations: Optional[ - List[Union[AddFields, CustomTransformation, RemoveFields]] + List[Union[AddFields, CustomTransformation, RemoveFields, KeysToLower]] ] = Field( None, description='A list of transformations to be applied to each output record.', @@ -1612,6 +1625,58 @@ class SimpleRetriever(BaseModel): parameters: Optional[Dict[str, Any]] = Field(None, alias='$parameters') +class AsyncRetriever(BaseModel): + type: Literal['AsyncRetriever'] + record_selector: RecordSelector = Field( + ..., + description='Component that describes how to extract records from a HTTP response.', + ) + status_mapping: AsyncJobStatusMap = Field( + ..., description='Async Job Status to Airbyte CDK Async Job Status mapping.' + ) + status_extractor: Optional[Union[CustomRecordExtractor, DpathExtractor]] = Field( + None, description='Responsible for fetching the actual status of the async job.' + ) + urls_extractor: Optional[Union[CustomRecordExtractor, DpathExtractor]] = Field( + None, + description='Responsible for fetching the final result `urls` provided by the completed / finished / ready async job.', + ) + creation_requester: Union[CustomRequester, HttpRequester] = Field( + ..., + description='Requester component that describes how to prepare HTTP requests to send to the source API to create the async server-side job.', + ) + polling_requester: Union[CustomRequester, HttpRequester] = Field( + ..., + description='Requester component that describes how to prepare HTTP requests to send to the source API to fetch the status of the running async job.', + ) + download_requester: Union[CustomRequester, HttpRequester] = Field( + ..., + description='Requester component that describes how to prepare HTTP requests to send to the source API to download the data provided by the completed async job.', + ) + partition_router: Optional[ + Union[ + CustomPartitionRouter, + ListPartitionRouter, + SubstreamPartitionRouter, + List[ + Union[ + CustomPartitionRouter, ListPartitionRouter, SubstreamPartitionRouter + ] + ], + ] + ] = Field( + [], + description='PartitionRouter component that describes how to partition the stream, enabling incremental syncs and checkpointing.', + title='Partition Router', + ) + decoder: Optional[Union[JsonDecoder, JsonlDecoder, IterableDecoder]] = Field( + None, + description='Component decoding the response so records can be extracted.', + title='Decoder', + ) + parameters: Optional[Dict[str, Any]] = Field(None, alias='$parameters') + + class SubstreamPartitionRouter(BaseModel): type: Literal['SubstreamPartitionRouter'] parent_stream_configs: List[ParentStreamConfig] = Field( @@ -1628,3 +1693,4 @@ class SubstreamPartitionRouter(BaseModel): DeclarativeStream.update_forward_refs() SessionTokenAuthenticator.update_forward_refs() SimpleRetriever.update_forward_refs() +AsyncRetriever.update_forward_refs() diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/parsers/model_to_component_factory.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/parsers/model_to_component_factory.py index c0e66d1ff43d7..45ef5388c65d6 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/parsers/model_to_component_factory.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/parsers/model_to_component_factory.py @@ -11,6 +11,9 @@ from typing import Any, Callable, Dict, List, Mapping, Optional, Type, Union, get_args, get_origin, get_type_hints from airbyte_cdk.models import FailureType, Level +from airbyte_cdk.sources.declarative.async_job.job_orchestrator import AsyncJobOrchestrator +from airbyte_cdk.sources.declarative.async_job.repository import AsyncJobRepository +from airbyte_cdk.sources.declarative.async_job.status import AsyncJobStatus from airbyte_cdk.sources.declarative.auth import DeclarativeOauth2Authenticator, JwtAuthenticator from airbyte_cdk.sources.declarative.auth.declarative_authenticator import DeclarativeAuthenticator, NoAuth from airbyte_cdk.sources.declarative.auth.jwt import JwtAlgorithm @@ -46,6 +49,8 @@ from airbyte_cdk.sources.declarative.models.declarative_component_schema import AddedFieldDefinition as AddedFieldDefinitionModel from airbyte_cdk.sources.declarative.models.declarative_component_schema import AddFields as AddFieldsModel from airbyte_cdk.sources.declarative.models.declarative_component_schema import ApiKeyAuthenticator as ApiKeyAuthenticatorModel +from airbyte_cdk.sources.declarative.models.declarative_component_schema import AsyncJobStatusMap as AsyncJobStatusMapModel +from airbyte_cdk.sources.declarative.models.declarative_component_schema import AsyncRetriever as AsyncRetrieverModel from airbyte_cdk.sources.declarative.models.declarative_component_schema import BasicHttpAuthenticator as BasicHttpAuthenticatorModel from airbyte_cdk.sources.declarative.models.declarative_component_schema import BearerAuthenticator as BearerAuthenticatorModel from airbyte_cdk.sources.declarative.models.declarative_component_schema import CheckStream as CheckStreamModel @@ -82,6 +87,7 @@ from airbyte_cdk.sources.declarative.models.declarative_component_schema import JwtAuthenticator as JwtAuthenticatorModel from airbyte_cdk.sources.declarative.models.declarative_component_schema import JwtHeaders as JwtHeadersModel from airbyte_cdk.sources.declarative.models.declarative_component_schema import JwtPayload as JwtPayloadModel +from airbyte_cdk.sources.declarative.models.declarative_component_schema import KeysToLower as KeysToLowerModel from airbyte_cdk.sources.declarative.models.declarative_component_schema import ( LegacySessionTokenAuthenticator as LegacySessionTokenAuthenticatorModel, ) @@ -124,6 +130,7 @@ WaitTimeFromHeaderBackoffStrategy, WaitUntilTimeFromHeaderBackoffStrategy, ) +from airbyte_cdk.sources.declarative.requesters.http_job_repository import AsyncHttpJobRepository from airbyte_cdk.sources.declarative.requesters.paginators import DefaultPaginator, NoPagination, PaginatorTestReadDecorator from airbyte_cdk.sources.declarative.requesters.paginators.strategies import ( CursorPaginationStrategy, @@ -136,12 +143,13 @@ from airbyte_cdk.sources.declarative.requesters.request_options import InterpolatedRequestOptionsProvider from airbyte_cdk.sources.declarative.requesters.request_path import RequestPath from airbyte_cdk.sources.declarative.requesters.requester import HttpMethod -from airbyte_cdk.sources.declarative.retrievers import SimpleRetriever, SimpleRetrieverTestReadDecorator +from airbyte_cdk.sources.declarative.retrievers import AsyncRetriever, SimpleRetriever, SimpleRetrieverTestReadDecorator from airbyte_cdk.sources.declarative.schema import DefaultSchemaLoader, InlineSchemaLoader, JsonFileSchemaLoader from airbyte_cdk.sources.declarative.spec import Spec from airbyte_cdk.sources.declarative.stream_slicers import StreamSlicer from airbyte_cdk.sources.declarative.transformations import AddFields, RecordTransformation, RemoveFields from airbyte_cdk.sources.declarative.transformations.add_fields import AddedFieldDefinition +from airbyte_cdk.sources.declarative.transformations.keys_to_lower_transformation import KeysToLowerTransformation from airbyte_cdk.sources.message import InMemoryMessageRepository, LogAppenderMessageRepositoryDecorator, MessageRepository from airbyte_cdk.sources.streams.http.error_handlers.response_models import ResponseAction from airbyte_cdk.sources.types import Config @@ -159,6 +167,7 @@ def __init__( limit_slices_fetched: Optional[int] = None, emit_connector_builder_messages: bool = False, disable_retries: bool = False, + disable_cache: bool = False, message_repository: Optional[MessageRepository] = None, ): self._init_mappings() @@ -166,6 +175,7 @@ def __init__( self._limit_slices_fetched = limit_slices_fetched self._emit_connector_builder_messages = emit_connector_builder_messages self._disable_retries = disable_retries + self._disable_cache = disable_cache self._message_repository = message_repository or InMemoryMessageRepository( # type: ignore self._evaluate_log_level(emit_connector_builder_messages) ) @@ -206,6 +216,7 @@ def _init_mappings(self) -> None: InlineSchemaLoaderModel: self.create_inline_schema_loader, JsonDecoderModel: self.create_json_decoder, JsonlDecoderModel: self.create_jsonl_decoder, + KeysToLowerModel: self.create_keys_to_lower_transformation, IterableDecoderModel: self.create_iterable_decoder, JsonFileSchemaLoaderModel: self.create_json_file_schema_loader, JwtAuthenticatorModel: self.create_jwt_authenticator, @@ -230,6 +241,7 @@ def _init_mappings(self) -> None: SubstreamPartitionRouterModel: self.create_substream_partition_router, WaitTimeFromHeaderModel: self.create_wait_time_from_header, WaitUntilTimeFromHeaderModel: self.create_wait_until_time_from_header, + AsyncRetrieverModel: self.create_async_retriever, } # Needed for the case where we need to perform a second parse on the fields of a custom component @@ -289,6 +301,9 @@ def create_add_fields(self, model: AddFieldsModel, config: Config, **kwargs: Any ] return AddFields(fields=added_field_definitions, parameters=model.parameters or {}) + def create_keys_to_lower_transformation(self, model: KeysToLowerModel, config: Config, **kwargs: Any) -> KeysToLowerTransformation: + return KeysToLowerTransformation() + @staticmethod def _json_schema_type_name_to_type(value_type: Optional[ValueType]) -> Optional[Type[Any]]: if not value_type: @@ -825,6 +840,8 @@ def create_http_requester(self, model: HttpRequesterModel, decoder: Decoder, con assert model.use_cache is not None # for mypy assert model.http_method is not None # for mypy + use_cache = model.use_cache and not self._disable_cache + return HttpRequester( name=name, url_base=model.url_base, @@ -837,7 +854,7 @@ def create_http_requester(self, model: HttpRequesterModel, decoder: Decoder, con disable_retries=self._disable_retries, parameters=model.parameters or {}, message_repository=self._message_repository, - use_cache=model.use_cache, + use_cache=use_cache, decoder=decoder, stream_response=decoder.is_stream_response() if decoder else False, ) @@ -1170,6 +1187,86 @@ def create_simple_retriever( parameters=model.parameters or {}, ) + def _create_async_job_status_mapping( + self, model: AsyncJobStatusMapModel, config: Config, **kwargs: Any + ) -> Mapping[str, AsyncJobStatus]: + api_status_to_cdk_status = {} + for cdk_status, api_statuses in model.dict().items(): + if cdk_status == "type": + # This is an element of the dict because of the typing of the CDK but it is not a CDK status + continue + + for status in api_statuses: + if status in api_status_to_cdk_status: + raise ValueError( + f"API status {status} is already set for CDK status {cdk_status}. Please ensure API statuses are only provided once" + ) + api_status_to_cdk_status[status] = self._get_async_job_status(cdk_status) + return api_status_to_cdk_status + + def _get_async_job_status(self, status: str) -> AsyncJobStatus: + match status: + case "running": + return AsyncJobStatus.RUNNING + case "completed": + return AsyncJobStatus.COMPLETED + case "failed": + return AsyncJobStatus.FAILED + case "timeout": + return AsyncJobStatus.TIMED_OUT + case _: + raise ValueError(f"Unsupported CDK status {status}") + + def create_async_retriever( + self, + model: AsyncRetrieverModel, + config: Config, + *, + name: str, + primary_key: Optional[Union[str, List[str], List[List[str]]]], # this seems to be needed to match create_simple_retriever + stream_slicer: Optional[StreamSlicer], + client_side_incremental_sync: Optional[Dict[str, Any]] = None, + transformations: List[RecordTransformation], + **kwargs: Any, + ) -> AsyncRetriever: + + decoder = self._create_component_from_model(model=model.decoder, config=config) if model.decoder else JsonDecoder(parameters={}) + record_selector = self._create_component_from_model( + model=model.record_selector, + config=config, + decoder=decoder, + transformations=transformations, + client_side_incremental_sync=client_side_incremental_sync, + ) + stream_slicer = stream_slicer or SinglePartitionRouter(parameters={}) + creation_requester = self._create_component_from_model( + model=model.creation_requester, decoder=decoder, config=config, name=f"job creation - {name}" + ) + polling_requester = self._create_component_from_model( + model=model.polling_requester, decoder=decoder, config=config, name=f"job polling - {name}" + ) + download_requester = self._create_component_from_model( + model=model.download_requester, decoder=decoder, config=config, name=f"job download - {name}" + ) + status_extractor = self._create_component_from_model(model=model.status_extractor, decoder=decoder, config=config, name=name) + urls_extractor = self._create_component_from_model(model=model.urls_extractor, decoder=decoder, config=config, name=name) + job_repository: AsyncJobRepository = AsyncHttpJobRepository( + creation_requester=creation_requester, + polling_requester=polling_requester, + download_requester=download_requester, + status_extractor=status_extractor, + status_mapping=self._create_async_job_status_mapping(model.status_mapping, config), + urls_extractor=urls_extractor, + ) + + return AsyncRetriever( + job_orchestrator_factory=lambda stream_slices: AsyncJobOrchestrator(job_repository, stream_slices), + record_selector=record_selector, + stream_slicer=stream_slicer, + config=config, + parameters=model.parameters or {}, + ) + @staticmethod def create_spec(model: SpecModel, config: Config, **kwargs: Any) -> Spec: return Spec( @@ -1199,6 +1296,7 @@ def _create_message_repository_substream_wrapper(self, model: ParentStreamConfig limit_slices_fetched=self._limit_slices_fetched, emit_connector_builder_messages=self._emit_connector_builder_messages, disable_retries=self._disable_retries, + disable_cache=self._disable_cache, message_repository=LogAppenderMessageRepositoryDecorator( {"airbyte_cdk": {"stream": {"is_substream": True}}, "http": {"is_auxiliary": True}}, self._message_repository, diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/requesters/http_job_repository.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/requesters/http_job_repository.py new file mode 100644 index 0000000000000..ada35e9d55715 --- /dev/null +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/requesters/http_job_repository.py @@ -0,0 +1,177 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. +import logging +import uuid +from dataclasses import dataclass, field +from typing import Any, Dict, Iterable, Mapping, Optional + +import requests +from airbyte_cdk.logger import lazy_log +from airbyte_cdk.models import FailureType +from airbyte_cdk.sources.declarative.async_job.job import AsyncJob +from airbyte_cdk.sources.declarative.async_job.repository import AsyncJobRepository +from airbyte_cdk.sources.declarative.async_job.status import AsyncJobStatus +from airbyte_cdk.sources.declarative.extractors.dpath_extractor import DpathExtractor, RecordExtractor +from airbyte_cdk.sources.declarative.extractors.response_to_file_extractor import ResponseToFileExtractor +from airbyte_cdk.sources.declarative.requesters.requester import Requester +from airbyte_cdk.sources.types import StreamSlice +from airbyte_cdk.utils import AirbyteTracedException +from requests import Response + +LOGGER = logging.getLogger("airbyte") + + +@dataclass +class AsyncHttpJobRepository(AsyncJobRepository): + creation_requester: Requester + polling_requester: Requester + download_requester: Requester + status_extractor: DpathExtractor + status_mapping: Mapping[str, AsyncJobStatus] + urls_extractor: DpathExtractor + + record_extractor: RecordExtractor = field(init=False, repr=False, default_factory=lambda: ResponseToFileExtractor()) + + def __post_init__(self) -> None: + self._create_job_response_by_id: Dict[str, Response] = {} + self._polling_job_response_by_id: Dict[str, Response] = {} + + def _get_validated_polling_response(self, stream_slice: StreamSlice) -> requests.Response: + """ + Validates and retrieves the pooling response for a given stream slice. + + Args: + stream_slice (StreamSlice): The stream slice to send the pooling request for. + + Returns: + requests.Response: The validated pooling response. + + Raises: + AirbyteTracedException: If the polling request returns an empty response. + """ + + polling_response: Optional[requests.Response] = self.polling_requester.send_request(stream_slice=stream_slice) + if polling_response is None: + raise AirbyteTracedException( + internal_message="Polling Requester received an empty Response.", + failure_type=FailureType.system_error, + ) + return polling_response + + def _get_validated_job_status(self, response: requests.Response) -> AsyncJobStatus: + """ + Validates the job status extracted from the API response. + + Args: + response (requests.Response): The API response. + + Returns: + AsyncJobStatus: The validated job status. + + Raises: + ValueError: If the API status is unknown. + """ + + api_status = next(iter(self.status_extractor.extract_records(response)), None) + job_status = self.status_mapping.get(str(api_status), None) + if job_status is None: + raise ValueError( + f"API status `{api_status}` is unknown. Contact the connector developer to make sure this status is supported." + ) + + return job_status + + def _start_job_and_validate_response(self, stream_slice: StreamSlice) -> requests.Response: + """ + Starts a job and validates the response. + + Args: + stream_slice (StreamSlice): The stream slice to be used for the job. + + Returns: + requests.Response: The response from the job creation requester. + + Raises: + AirbyteTracedException: If no response is received from the creation requester. + """ + + response: Optional[requests.Response] = self.creation_requester.send_request(stream_slice=stream_slice) + if not response: + raise AirbyteTracedException( + internal_message="Always expect a response or an exception from creation_requester", + failure_type=FailureType.system_error, + ) + + return response + + def start(self, stream_slice: StreamSlice) -> AsyncJob: + """ + Starts a job for the given stream slice. + + Args: + stream_slice (StreamSlice): The stream slice to start the job for. + + Returns: + AsyncJob: The asynchronous job object representing the started job. + """ + + response: requests.Response = self._start_job_and_validate_response(stream_slice) + job_id: str = str(uuid.uuid4()) + self._create_job_response_by_id[job_id] = response + + return AsyncJob(api_job_id=job_id, job_parameters=stream_slice) + + def update_jobs_status(self, jobs: Iterable[AsyncJob]) -> None: + """ + Updates the status of multiple jobs. + + Because we don't have interpolation on random fields, we have this hack which consist on using the stream_slice to allow for + interpolation. We are looking at enabling interpolation on more field which would require a change to those three layers: + HttpRequester, RequestOptionProvider, RequestInputProvider. + + Args: + jobs (Iterable[AsyncJob]): An iterable of AsyncJob objects representing the jobs to update. + + Returns: + None + """ + for job in jobs: + stream_slice = StreamSlice( + partition={"create_job_response": self._create_job_response_by_id[job.api_job_id()]}, + cursor_slice={}, + ) + polling_response: requests.Response = self._get_validated_polling_response(stream_slice) + job_status: AsyncJobStatus = self._get_validated_job_status(polling_response) + + if job_status != job.status(): + lazy_log(LOGGER, logging.DEBUG, lambda: f"Status of job {job.api_job_id()} changed from {job.status()} to {job_status}") + + job.update_status(job_status) + if job_status == AsyncJobStatus.COMPLETED: + self._polling_job_response_by_id[job.api_job_id()] = polling_response + + def fetch_records(self, job: AsyncJob) -> Iterable[Mapping[str, Any]]: + """ + Fetches records from the given job. + + Args: + job (AsyncJob): The job to fetch records from. + + Yields: + Iterable[Mapping[str, Any]]: A generator that yields records as dictionaries. + + """ + + for url in self.urls_extractor.extract_records(self._polling_job_response_by_id[job.api_job_id()]): + stream_slice: StreamSlice = StreamSlice(partition={"url": url}, cursor_slice={}) + # FIXME salesforce will require pagination here + response = self.download_requester.send_request(stream_slice=stream_slice) + if response: + yield from self.record_extractor.extract_records(response) + + yield from [] + + self._clean_up_job(job.api_job_id()) + + def _clean_up_job(self, job_id: str) -> None: + del self._create_job_response_by_id[job_id] + del self._polling_job_response_by_id[job_id] diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/__init__.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/__init__.py index fcbe40d95414e..9ec5017fb38c3 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/__init__.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/__init__.py @@ -4,5 +4,6 @@ from airbyte_cdk.sources.declarative.retrievers.retriever import Retriever from airbyte_cdk.sources.declarative.retrievers.simple_retriever import SimpleRetriever, SimpleRetrieverTestReadDecorator +from airbyte_cdk.sources.declarative.retrievers.async_retriever import AsyncRetriever -__all__ = ["Retriever", "SimpleRetriever", "SimpleRetrieverTestReadDecorator"] +__all__ = ["Retriever", "SimpleRetriever", "SimpleRetrieverTestReadDecorator", "AsyncRetriever"] diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/async_retriever.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/async_retriever.py new file mode 100644 index 0000000000000..4bb9421e44dc0 --- /dev/null +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/async_retriever.py @@ -0,0 +1,112 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. + + +from dataclasses import InitVar, dataclass, field +from typing import Any, Callable, Iterable, Mapping, Optional + +from airbyte_cdk.models import FailureType +from airbyte_cdk.sources.declarative.async_job.job_orchestrator import AsyncJobOrchestrator, AsyncPartition +from airbyte_cdk.sources.declarative.extractors.record_selector import RecordSelector +from airbyte_cdk.sources.declarative.partition_routers import SinglePartitionRouter +from airbyte_cdk.sources.declarative.retrievers import Retriever +from airbyte_cdk.sources.declarative.stream_slicers import StreamSlicer +from airbyte_cdk.sources.streams.core import StreamData +from airbyte_cdk.sources.types import Config, StreamSlice, StreamState +from airbyte_cdk.utils.traced_exception import AirbyteTracedException + + +@dataclass +class AsyncRetriever(Retriever): + config: Config + parameters: InitVar[Mapping[str, Any]] + job_orchestrator_factory: Callable[[Iterable[StreamSlice]], AsyncJobOrchestrator] + record_selector: RecordSelector + stream_slicer: StreamSlicer = field(default_factory=lambda: SinglePartitionRouter(parameters={})) + + def __post_init__(self, parameters: Mapping[str, Any]) -> None: + self._job_orchestrator_factory = self.job_orchestrator_factory + self.__job_orchestrator: Optional[AsyncJobOrchestrator] = None + self._parameters = parameters + + @property + def state(self) -> StreamState: + """ + As a first iteration for sendgrid, there is no state to be managed + """ + return {} + + @state.setter + def state(self, value: StreamState) -> None: + """ + As a first iteration for sendgrid, there is no state to be managed + """ + pass + + @property + def _job_orchestrator(self) -> AsyncJobOrchestrator: + if not self.__job_orchestrator: + raise AirbyteTracedException( + message="Invalid state within AsyncJobRetriever. Please contact Airbyte Support", + internal_message="AsyncPartitionRepository is expected to be accessed only after `stream_slices`", + failure_type=FailureType.system_error, + ) + + return self.__job_orchestrator + + def _get_stream_state(self) -> StreamState: + """ + Gets the current state of the stream. + + Returns: + StreamState: Mapping[str, Any] + """ + + return self.state + + def _validate_and_get_stream_slice_partition(self, stream_slice: Optional[StreamSlice] = None) -> AsyncPartition: + """ + Validates the stream_slice argument and returns the partition from it. + + Args: + stream_slice (Optional[StreamSlice]): The stream slice to validate and extract the partition from. + + Returns: + AsyncPartition: The partition extracted from the stream_slice. + + Raises: + AirbyteTracedException: If the stream_slice is not an instance of StreamSlice or if the partition is not present in the stream_slice. + + """ + if not isinstance(stream_slice, StreamSlice) or "partition" not in stream_slice.partition: + raise AirbyteTracedException( + message="Invalid arguments to AsyncJobRetriever.read_records: stream_slice is no optional. Please contact Airbyte Support", + failure_type=FailureType.system_error, + ) + return stream_slice["partition"] # type: ignore # stream_slice["partition"] has been added as an AsyncPartition as part of stream_slices + + def stream_slices(self) -> Iterable[Optional[StreamSlice]]: + slices = self.stream_slicer.stream_slices() + self.__job_orchestrator = self._job_orchestrator_factory(slices) + + for completed_partition in self._job_orchestrator.create_and_get_completed_partitions(): + yield StreamSlice( + partition=dict(completed_partition.stream_slice.partition) | {"partition": completed_partition}, + cursor_slice=completed_partition.stream_slice.cursor_slice, + ) + + def read_records( + self, + records_schema: Mapping[str, Any], + stream_slice: Optional[StreamSlice] = None, + ) -> Iterable[StreamData]: + + stream_state: StreamState = self._get_stream_state() + partition: AsyncPartition = self._validate_and_get_stream_slice_partition(stream_slice) + records: Iterable[Mapping[str, Any]] = self._job_orchestrator.fetch_records(partition) + + yield from self.record_selector.filter_and_transform( + all_data=records, + stream_state=stream_state, + records_schema=records_schema, + stream_slice=stream_slice, + ) diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/retriever.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/retriever.py index ddab622226947..155de5782aa00 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/retriever.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/retrievers/retriever.py @@ -3,7 +3,6 @@ # from abc import abstractmethod -from dataclasses import dataclass from typing import Any, Iterable, Mapping, Optional from airbyte_cdk.sources.declarative.incremental.per_partition_cursor import StreamSlice @@ -11,7 +10,6 @@ from airbyte_cdk.sources.types import StreamState -@dataclass class Retriever: """ Responsible for fetching a stream's records from an HTTP API source. diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/add_fields.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/add_fields.py index 67290d2a5d953..2a69b78218fd0 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/add_fields.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/add_fields.py @@ -3,12 +3,12 @@ # from dataclasses import InitVar, dataclass, field -from typing import Any, List, Mapping, Optional, Type, Union +from typing import Any, Dict, List, Mapping, Optional, Type, Union import dpath from airbyte_cdk.sources.declarative.interpolation.interpolated_string import InterpolatedString from airbyte_cdk.sources.declarative.transformations import RecordTransformation -from airbyte_cdk.sources.types import Config, FieldPointer, Record, StreamSlice, StreamState +from airbyte_cdk.sources.types import Config, FieldPointer, StreamSlice, StreamState @dataclass(frozen=True) @@ -111,11 +111,11 @@ def __post_init__(self, parameters: Mapping[str, Any]) -> None: def transform( self, - record: Record, + record: Dict[str, Any], config: Optional[Config] = None, stream_state: Optional[StreamState] = None, stream_slice: Optional[StreamSlice] = None, - ) -> Record: + ) -> None: if config is None: config = {} kwargs = {"record": record, "stream_state": stream_state, "stream_slice": stream_slice} @@ -124,7 +124,5 @@ def transform( value = parsed_field.value.eval(config, valid_types=valid_types, **kwargs) dpath.new(record, parsed_field.path, value) - return record - def __eq__(self, other: Any) -> bool: return bool(self.__dict__ == other.__dict__) diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/keys_to_lower_transformation.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/keys_to_lower_transformation.py new file mode 100644 index 0000000000000..53db3d49abd40 --- /dev/null +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/keys_to_lower_transformation.py @@ -0,0 +1,22 @@ +# +# Copyright (c) 2023 Airbyte, Inc., all rights reserved. +# + +from dataclasses import dataclass +from typing import Any, Dict, Optional + +from airbyte_cdk.sources.declarative.transformations import RecordTransformation +from airbyte_cdk.sources.types import Config, StreamSlice, StreamState + + +@dataclass +class KeysToLowerTransformation(RecordTransformation): + def transform( + self, + record: Dict[str, Any], + config: Optional[Config] = None, + stream_state: Optional[StreamState] = None, + stream_slice: Optional[StreamSlice] = None, + ) -> None: + for key in set(record.keys()): + record[key.lower()] = record.pop(key) diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/remove_fields.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/remove_fields.py index 1d4edfc393673..658d5dd2ccdb0 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/remove_fields.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/remove_fields.py @@ -3,7 +3,7 @@ # from dataclasses import InitVar, dataclass -from typing import Any, List, Mapping, Optional +from typing import Any, Dict, List, Mapping, Optional import dpath import dpath.exceptions @@ -48,11 +48,11 @@ def __post_init__(self, parameters: Mapping[str, Any]) -> None: def transform( self, - record: Mapping[str, Any], + record: Dict[str, Any], config: Optional[Config] = None, stream_state: Optional[StreamState] = None, stream_slice: Optional[StreamSlice] = None, - ) -> Mapping[str, Any]: + ) -> None: """ :param record: The record to be transformed :return: the input record with the requested fields removed @@ -68,5 +68,3 @@ def transform( except dpath.exceptions.PathNotFound: # if the (potentially nested) property does not exist, silently skip pass - - return record diff --git a/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/transformation.py b/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/transformation.py index bd66f5fae1199..f5b22642964b2 100644 --- a/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/transformation.py +++ b/airbyte-cdk/python/airbyte_cdk/sources/declarative/transformations/transformation.py @@ -4,9 +4,9 @@ from abc import abstractmethod from dataclasses import dataclass -from typing import Any, Mapping, Optional +from typing import Any, Dict, Optional -from airbyte_cdk.sources.types import Config, Record, StreamSlice, StreamState +from airbyte_cdk.sources.types import Config, StreamSlice, StreamState @dataclass @@ -18,13 +18,13 @@ class RecordTransformation: @abstractmethod def transform( self, - record: Record, + record: Dict[str, Any], config: Optional[Config] = None, stream_state: Optional[StreamState] = None, stream_slice: Optional[StreamSlice] = None, - ) -> Mapping[str, Any]: + ) -> None: """ - Transform a record by adding, deleting, or mutating fields. + Transform a record by adding, deleting, or mutating fields directly from the record reference passed in argument. :param record: The input record to be transformed :param config: The user-provided configuration as specified by the source's spec diff --git a/airbyte-cdk/python/poetry.lock b/airbyte-cdk/python/poetry.lock index 4564f78918122..e3ad8f3d94e43 100644 --- a/airbyte-cdk/python/poetry.lock +++ b/airbyte-cdk/python/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 1.8.3 and should not be changed by hand. +# This file is automatically @generated by Poetry 1.8.2 and should not be changed by hand. [[package]] name = "aiohappyeyeballs" @@ -1961,8 +1961,8 @@ files = [ httpx = ">=0.23.0,<1" orjson = ">=3.9.14,<4.0.0" pydantic = [ - {version = ">=1,<3", markers = "python_full_version < \"3.12.4\""}, {version = ">=2.7.4,<3.0.0", markers = "python_full_version >= \"3.12.4\""}, + {version = ">=1,<3", markers = "python_full_version < \"3.12.4\""}, ] requests = ">=2,<3" @@ -2668,7 +2668,7 @@ twitter = ["twython"] name = "numpy" version = "1.26.4" description = "Fundamental package for array computing in Python" -optional = true +optional = false python-versions = ">=3.9" files = [ {file = "numpy-1.26.4-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:9ff0f4f29c51e2803569d7a51c2304de5554655a60c5d776e35b4a41413830d0"}, @@ -2835,7 +2835,7 @@ files = [ name = "pandas" version = "2.2.0" description = "Powerful data structures for data analysis, time series, and statistics" -optional = true +optional = false python-versions = ">=3.9" files = [ {file = "pandas-2.2.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:8108ee1712bb4fa2c16981fba7e68b3f6ea330277f5ca34fa8d557e986a11670"}, @@ -2871,9 +2871,9 @@ files = [ [package.dependencies] numpy = [ + {version = ">=1.26.0,<2", markers = "python_version >= \"3.12\""}, {version = ">=1.22.4,<2", markers = "python_version < \"3.11\""}, {version = ">=1.23.2,<2", markers = "python_version == \"3.11\""}, - {version = ">=1.26.0,<2", markers = "python_version >= \"3.12\""}, ] python-dateutil = ">=2.8.2" pytz = ">=2020.1" @@ -3306,8 +3306,8 @@ files = [ annotated-types = ">=0.4.0" pydantic-core = "2.20.1" typing-extensions = [ - {version = ">=4.6.1", markers = "python_version < \"3.13\""}, {version = ">=4.12.2", markers = "python_version >= \"3.13\""}, + {version = ">=4.6.1", markers = "python_version < \"3.13\""}, ] [package.extras] @@ -4959,7 +4959,7 @@ typing-extensions = ">=3.7.4" name = "tzdata" version = "2024.1" description = "Provider of IANA time zone data" -optional = true +optional = false python-versions = ">=2" files = [ {file = "tzdata-2024.1-py2.py3-none-any.whl", hash = "sha256:9068bc196136463f5245e51efda838afa15aaeca9903f49050dfa2679db4d252"}, @@ -5397,11 +5397,11 @@ test = ["big-O", "importlib-resources", "jaraco.functools", "jaraco.itertools", type = ["pytest-mypy"] [extras] -file-based = ["avro", "fastavro", "markdown", "pandas", "pdf2image", "pdfminer.six", "pyarrow", "pytesseract", "python-calamine", "unstructured", "unstructured.pytesseract"] +file-based = ["avro", "fastavro", "markdown", "pdf2image", "pdfminer.six", "pyarrow", "pytesseract", "python-calamine", "unstructured", "unstructured.pytesseract"] sphinx-docs = ["Sphinx", "sphinx-rtd-theme"] vector-db-based = ["cohere", "langchain", "openai", "tiktoken"] [metadata] lock-version = "2.0" python-versions = "^3.10" -content-hash = "1759d8574c392cf39fccff997263873168087159c5f741314ceff6db4e5a32af" +content-hash = "6e5a25dc4116b4e6e574f5170b23ab6eedf07255a139a6aaa9416e147aee716e" diff --git a/airbyte-cdk/python/pyproject.toml b/airbyte-cdk/python/pyproject.toml index b2898e71d5ee6..d781f79374356 100644 --- a/airbyte-cdk/python/pyproject.toml +++ b/airbyte-cdk/python/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api" [tool.poetry] name = "airbyte-cdk" -version = "5.2.1" +version = "5.5.2" description = "A framework for writing Airbyte Connectors." authors = ["Airbyte "] license = "MIT" @@ -35,6 +35,7 @@ isodate = "~0.6.1" Jinja2 = "~3.1.2" jsonref = "~0.2" jsonschema = "~3.2.0" +pandas = "2.2.0" pendulum = "<3.0.0" pydantic = "^2.7" pyrate-limiter = "~3.1.0" @@ -51,7 +52,6 @@ langchain = { version = "0.1.16", optional = true } langchain_core = { version = "0.1.42", optional = true } markdown = { version = "*", optional = true } openai = { version = "0.27.9", extras = ["embeddings"], optional = true } -pandas = { version = "2.2.0", optional = true } pdf2image = { version = "1.16.3", optional = true } "pdfminer.six" = { version = "20221105", optional = true } pyarrow = { version = "~15.0.0", optional = true } @@ -84,7 +84,7 @@ requests-mock = "*" codeflash = "*" [tool.poetry.extras] -file-based = ["avro", "fastavro", "pyarrow", "unstructured", "pdf2image", "pdfminer.six", "unstructured.pytesseract", "pytesseract", "markdown", "python-calamine", "pandas"] +file-based = ["avro", "fastavro", "pyarrow", "unstructured", "pdf2image", "pdfminer.six", "unstructured.pytesseract", "pytesseract", "markdown", "python-calamine"] sphinx-docs = ["Sphinx", "sphinx-rtd-theme"] vector-db-based = ["langchain", "openai", "cohere", "tiktoken"] diff --git a/airbyte-cdk/python/unit_tests/connector_builder/test_connector_builder_handler.py b/airbyte-cdk/python/unit_tests/connector_builder/test_connector_builder_handler.py index ca6b8e47ea689..2c5f90ff84d26 100644 --- a/airbyte-cdk/python/unit_tests/connector_builder/test_connector_builder_handler.py +++ b/airbyte-cdk/python/unit_tests/connector_builder/test_connector_builder_handler.py @@ -709,6 +709,7 @@ def test_create_source(): assert isinstance(source, ManifestDeclarativeSource) assert source._constructor._limit_pages_fetched_per_slice == limits.max_pages_per_slice assert source._constructor._limit_slices_fetched == limits.max_slices + assert source._constructor._disable_cache def request_log_message(request: dict) -> AirbyteMessage: diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/async_job/__init__.py b/airbyte-cdk/python/unit_tests/sources/declarative/async_job/__init__.py new file mode 100644 index 0000000000000..e69de29bb2d1d diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/async_job/test_integration.py b/airbyte-cdk/python/unit_tests/sources/declarative/async_job/test_integration.py new file mode 100644 index 0000000000000..fa608bbd16fd3 --- /dev/null +++ b/airbyte-cdk/python/unit_tests/sources/declarative/async_job/test_integration.py @@ -0,0 +1,111 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. + + +import logging +from typing import Any, Iterable, List, Mapping, Optional, Set, Tuple +from unittest import TestCase, mock + +from airbyte_cdk import AbstractSource, DeclarativeStream, SinglePartitionRouter, Stream, StreamSlice +from airbyte_cdk.models import ConnectorSpecification +from airbyte_cdk.sources.declarative.async_job.job import AsyncJob +from airbyte_cdk.sources.declarative.async_job.job_orchestrator import AsyncJobOrchestrator +from airbyte_cdk.sources.declarative.async_job.repository import AsyncJobRepository +from airbyte_cdk.sources.declarative.async_job.status import AsyncJobStatus +from airbyte_cdk.sources.declarative.extractors.record_extractor import RecordExtractor +from airbyte_cdk.sources.declarative.extractors.record_selector import RecordSelector +from airbyte_cdk.sources.declarative.retrievers.async_retriever import AsyncRetriever +from airbyte_cdk.sources.declarative.schema import InlineSchemaLoader +from airbyte_cdk.sources.declarative.stream_slicers import StreamSlicer +from airbyte_cdk.sources.utils.transform import TransformConfig, TypeTransformer +from airbyte_cdk.test.catalog_builder import CatalogBuilder, ConfiguredAirbyteStreamBuilder +from airbyte_cdk.test.entrypoint_wrapper import read + +_A_STREAM_NAME = "a_stream_name" +_EXTRACTOR_NOT_USED: RecordExtractor = None # type: ignore # the extractor should not be used. If it is the case, there is an issue that needs fixing + + +class MockAsyncJobRepository(AsyncJobRepository): + + def start(self, stream_slice: StreamSlice) -> AsyncJob: + return AsyncJob("a_job_id", StreamSlice(partition={}, cursor_slice={})) + + def update_jobs_status(self, jobs: Set[AsyncJob]) -> None: + for job in jobs: + job.update_status(AsyncJobStatus.COMPLETED) + + def fetch_records(self, job: AsyncJob) -> Iterable[Mapping[str, Any]]: + yield from [{"record_field": 10}] + + +class MockSource(AbstractSource): + + def __init__(self, stream_slicer: Optional[StreamSlicer] = None) -> None: + self._stream_slicer = SinglePartitionRouter({}) if stream_slicer is None else stream_slicer + + def check_connection(self, logger: logging.Logger, config: Mapping[str, Any]) -> Tuple[bool, Optional[Any]]: + return True, None + + def spec(self, logger: logging.Logger) -> ConnectorSpecification: + return ConnectorSpecification(connectionSpecification={}) + + def streams(self, config: Mapping[str, Any]) -> List[Stream]: + noop_record_selector = RecordSelector( + extractor=_EXTRACTOR_NOT_USED, + config={}, + parameters={}, + schema_normalization=TypeTransformer(TransformConfig.NoTransform), + record_filter=None, + transformations=[] + ) + return [ + DeclarativeStream( + retriever=AsyncRetriever( + config={}, + parameters={}, + record_selector=noop_record_selector, + stream_slicer=self._stream_slicer, + job_orchestrator_factory=lambda stream_slices: AsyncJobOrchestrator( + MockAsyncJobRepository(), stream_slices, + ), + ), + config={}, + parameters={}, + name=_A_STREAM_NAME, + primary_key=["id"], + schema_loader=InlineSchemaLoader({}, {}), + # the interface mentions that this is Optional, + # but I get `'NoneType' object has no attribute 'eval'` by passing None + stream_cursor_field="", + ) + ] + + +class JobDeclarativeStreamTest(TestCase): + _CONFIG: Mapping[str, Any] = {} + + def setUp(self) -> None: + self._stream_slicer = mock.Mock(wraps=SinglePartitionRouter({})) + self._source = MockSource(self._stream_slicer) + self._source.streams({}) + + def test_when_read_then_return_records_from_repository(self) -> None: + output = read( + self._source, + self._CONFIG, + CatalogBuilder().with_stream(ConfiguredAirbyteStreamBuilder().with_name(_A_STREAM_NAME)).build() + ) + + assert len(output.records) == 1 + + def test_when_read_then_call_stream_slices_only_once(self) -> None: + """ + As generating stream slices is very expensive, we want to ensure that during a read, it is only called once. + """ + output = read( + self._source, + self._CONFIG, + CatalogBuilder().with_stream(ConfiguredAirbyteStreamBuilder().with_name(_A_STREAM_NAME)).build() + ) + + assert not output.errors + assert self._stream_slicer.stream_slices.call_count == 1 diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/async_job/test_job.py b/airbyte-cdk/python/unit_tests/sources/declarative/async_job/test_job.py new file mode 100644 index 0000000000000..6399433e4413e --- /dev/null +++ b/airbyte-cdk/python/unit_tests/sources/declarative/async_job/test_job.py @@ -0,0 +1,32 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. + +import time +from datetime import timedelta +from unittest import TestCase + +from airbyte_cdk.sources.declarative.async_job.job import AsyncJob +from airbyte_cdk.sources.declarative.async_job.status import AsyncJobStatus +from airbyte_cdk.sources.declarative.types import StreamSlice + +_AN_API_JOB_ID = "an api job id" +_ANY_STREAM_SLICE = StreamSlice(partition={}, cursor_slice={}) +_A_VERY_BIG_TIMEOUT = timedelta(days=999999999) +_IMMEDIATELY_TIMED_OUT = timedelta(microseconds=1) + + +class AsyncJobTest(TestCase): + def test_given_timer_is_not_out_when_status_then_return_actual_status(self) -> None: + job = AsyncJob(_AN_API_JOB_ID, _ANY_STREAM_SLICE, _A_VERY_BIG_TIMEOUT) + assert job.status() == AsyncJobStatus.RUNNING + + def test_given_timer_is_out_when_status_then_return_timed_out(self) -> None: + job = AsyncJob(_AN_API_JOB_ID, _ANY_STREAM_SLICE, _IMMEDIATELY_TIMED_OUT) + time.sleep(0.001) + assert job.status() == AsyncJobStatus.TIMED_OUT + + def test_given_status_is_terminal_when_update_status_then_stop_timer(self) -> None: + """ + This test will become important once we will print stats associated with jobs. As for now, we stop the timer but do not return any + metrics regarding the timer so it is not useful. + """ + pass diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/async_job/test_job_orchestrator.py b/airbyte-cdk/python/unit_tests/sources/declarative/async_job/test_job_orchestrator.py new file mode 100644 index 0000000000000..5e2c3a51a5ab6 --- /dev/null +++ b/airbyte-cdk/python/unit_tests/sources/declarative/async_job/test_job_orchestrator.py @@ -0,0 +1,144 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. + +import logging +from typing import Callable, List, Mapping, Set +from unittest import TestCase, mock +from unittest.mock import MagicMock, Mock, call + +import pytest +from airbyte_cdk import AirbyteTracedException, StreamSlice +from airbyte_cdk.sources.declarative.async_job.job import AsyncJob, AsyncJobStatus +from airbyte_cdk.sources.declarative.async_job.job_orchestrator import AsyncJobOrchestrator, AsyncPartition +from airbyte_cdk.sources.declarative.async_job.repository import AsyncJobRepository + +_ANY_STREAM_SLICE = Mock() +_A_STREAM_SLICE = Mock() +_ANOTHER_STREAM_SLICE = Mock() +_ANY_RECORD = {"a record field": "a record value"} + + +def _create_job(status: AsyncJobStatus = AsyncJobStatus.FAILED) -> AsyncJob: + job = Mock(spec=AsyncJob) + job.status.return_value = status + return job + + +class AsyncPartitionTest(TestCase): + def test_given_one_failed_job_when_status_then_return_failed(self) -> None: + partition = AsyncPartition([_create_job(status) for status in AsyncJobStatus], _ANY_STREAM_SLICE) + assert partition.status == AsyncJobStatus.FAILED + + def test_given_all_status_except_failed_when_status_then_return_timed_out(self) -> None: + statuses = [status for status in AsyncJobStatus if status != AsyncJobStatus.FAILED] + partition = AsyncPartition([_create_job(status) for status in statuses], _ANY_STREAM_SLICE) + assert partition.status == AsyncJobStatus.TIMED_OUT + + def test_given_running_and_completed_jobs_when_status_then_return_running(self) -> None: + partition = AsyncPartition([_create_job(AsyncJobStatus.RUNNING), _create_job(AsyncJobStatus.COMPLETED)], _ANY_STREAM_SLICE) + assert partition.status == AsyncJobStatus.RUNNING + + def test_given_only_completed_jobs_when_status_then_return_running(self) -> None: + partition = AsyncPartition([_create_job(AsyncJobStatus.COMPLETED) for _ in range(10)], _ANY_STREAM_SLICE) + assert partition.status == AsyncJobStatus.COMPLETED + + +def _status_update_per_jobs(status_update_per_jobs: Mapping[AsyncJob, List[AsyncJobStatus]]) -> Callable[[set[AsyncJob]], None]: + status_index_by_job = {job: 0 for job in status_update_per_jobs.keys()} + + def _update_status(jobs: Set[AsyncJob]) -> None: + for job in jobs: + status_index = status_index_by_job[job] + job.update_status(status_update_per_jobs[job][status_index]) + status_index_by_job[job] += 1 + + return _update_status + + +sleep_mock_target = "airbyte_cdk.sources.declarative.async_job.job_orchestrator.time.sleep" + + +class AsyncJobOrchestratorTest(TestCase): + def setUp(self) -> None: + self._job_repository = Mock(spec=AsyncJobRepository) + self._logger = Mock(spec=logging.Logger) + + self._job_for_a_slice = mock.Mock(wraps=AsyncJob("an api job id", _A_STREAM_SLICE)) + self._job_for_another_slice = mock.Mock(wraps=AsyncJob("another api job id", _ANOTHER_STREAM_SLICE)) + + @mock.patch(sleep_mock_target) + def test_when_create_and_get_completed_partitions_then_create_job_and_update_status_until_completed(self, mock_sleep: MagicMock) -> None: + self._job_repository.start.return_value = self._job_for_a_slice + status_updates = [AsyncJobStatus.RUNNING, AsyncJobStatus.RUNNING, AsyncJobStatus.COMPLETED] + self._job_repository.update_jobs_status.side_effect = _status_update_per_jobs( + { + self._job_for_a_slice: status_updates + } + ) + orchestrator = self._orchestrator([_A_STREAM_SLICE]) + + partitions = list(orchestrator.create_and_get_completed_partitions()) + + assert len(partitions) == 1 + assert partitions[0].status == AsyncJobStatus.COMPLETED + assert self._job_for_a_slice.update_status.mock_calls == [call(status) for status in status_updates] + + @mock.patch(sleep_mock_target) + def test_given_one_job_still_running_when_create_and_get_completed_partitions_then_only_update_running_job_status(self, mock_sleep: MagicMock) -> None: + self._job_repository.start.side_effect = [self._job_for_a_slice, self._job_for_another_slice] + self._job_repository.update_jobs_status.side_effect = _status_update_per_jobs( + { + self._job_for_a_slice: [AsyncJobStatus.COMPLETED], + self._job_for_another_slice: [AsyncJobStatus.RUNNING, AsyncJobStatus.COMPLETED], + } + ) + orchestrator = self._orchestrator([_A_STREAM_SLICE, _ANOTHER_STREAM_SLICE]) + + list(orchestrator.create_and_get_completed_partitions()) + + assert self._job_repository.update_jobs_status.mock_calls == [ + call({self._job_for_a_slice, self._job_for_another_slice}), + call({self._job_for_another_slice}), + ] + + @mock.patch(sleep_mock_target) + def test_given_timeout_when_create_and_get_completed_partitions_then_raise_exception(self, mock_sleep: MagicMock) -> None: + self._job_repository.start.return_value = self._job_for_a_slice + self._job_repository.update_jobs_status.side_effect = _status_update_per_jobs( + { + self._job_for_a_slice: [AsyncJobStatus.TIMED_OUT] + } + ) + orchestrator = self._orchestrator([_A_STREAM_SLICE]) + + with pytest.raises(AirbyteTracedException): + list(orchestrator.create_and_get_completed_partitions()) + assert self._job_repository.start.call_args_list == [call(_A_STREAM_SLICE)] * 4 + + @mock.patch(sleep_mock_target) + def test_given_failure_when_create_and_get_completed_partitions_then_raise_exception(self, mock_sleep: MagicMock) -> None: + self._job_repository.start.return_value = self._job_for_a_slice + self._job_repository.update_jobs_status.side_effect = _status_update_per_jobs( + { + self._job_for_a_slice: [AsyncJobStatus.FAILED] + } + ) + orchestrator = self._orchestrator([_A_STREAM_SLICE]) + + with pytest.raises(AirbyteTracedException): + list(orchestrator.create_and_get_completed_partitions()) + assert self._job_repository.start.call_args_list == [call(_A_STREAM_SLICE)] * 4 + + def test_when_fetch_records_then_yield_records_from_each_job(self) -> None: + self._job_repository.fetch_records.return_value = [_ANY_RECORD] + orchestrator = self._orchestrator([_A_STREAM_SLICE]) + first_job = _create_job() + second_job = _create_job() + partition = AsyncPartition([first_job, second_job], _A_STREAM_SLICE) + + records = list(orchestrator.fetch_records(partition)) + + assert len(records) == 2 + assert self._job_repository.fetch_records.mock_calls == [call(first_job), call(second_job)] + + def _orchestrator(self, slices: List[StreamSlice]) -> AsyncJobOrchestrator: + return AsyncJobOrchestrator(self._job_repository, slices) diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/extractors/compressed_response b/airbyte-cdk/python/unit_tests/sources/declarative/extractors/compressed_response new file mode 100644 index 0000000000000..da79e347f0532 Binary files /dev/null and b/airbyte-cdk/python/unit_tests/sources/declarative/extractors/compressed_response differ diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/extractors/decompressed_response.csv b/airbyte-cdk/python/unit_tests/sources/declarative/extractors/decompressed_response.csv new file mode 100644 index 0000000000000..ebef74b8ec70e --- /dev/null +++ b/airbyte-cdk/python/unit_tests/sources/declarative/extractors/decompressed_response.csv @@ -0,0 +1,25 @@ +"EMAIL","FIRST_NAME","LAST_NAME","ADDRESS_LINE_1","ADDRESS_LINE_2","CITY","STATE_PROVINCE_REGION","POSTAL_CODE","COUNTRY","ALTERNATE_EMAILS","PHONE_NUMBER","WHATSAPP","LINE","FACEBOOK","UNIQUE_NAME","CREATED_AT","UPDATED_AT","CONTACT_ID" +"fake_email_10@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:22Z","2021-02-01T12:35:51Z","eae8c5c8-f97e-40a8-8945-72acca457f5a" +"fake_email_1@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:08Z","2021-02-01T12:35:38Z","198f959f-f441-4d15-a280-9e8f65a90ba5" +"fake_email_12@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:24Z","2021-02-01T12:35:53Z","6975b74c-bb1e-4d54-a251-b934c4193ed4" +"fake_email_8@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:19Z","2021-02-01T12:35:49Z","36ef1a2d-3cc4-4515-9c00-1615c5f860d0" +"fake_email_18@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:30Z","2021-02-01T12:36:00Z","19163421-bb29-495d-950f-edede6218081" +"fake_email_3@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:14Z","2021-02-01T12:35:43Z","d1211b88-e116-4a0b-a823-0361bf059a06" +"fake_email_9@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:21Z","2021-02-01T12:35:50Z","ef4225b0-dff9-4756-af87-c4228d836d53" +"fake_email_4@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:15Z","2021-02-01T12:35:44Z","9adef36c-fe51-421a-9653-6bd010962e98" +"fake_email_2@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:13Z","2021-02-01T12:35:42Z","210d8004-d12a-4f01-815a-f90cfa9e4360" +"fake_email_6@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:17Z","2021-02-01T12:35:46Z","76330f89-5645-4432-b3bb-9e33a9195273" +"fake_email_14@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:26Z","2021-02-01T12:35:55Z","77200269-0b69-462c-bed1-9e6f912d4b83" +"fake_email_13@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:25Z","2021-02-01T12:35:54Z","c91c993b-1dfa-4686-bcf0-31e4aeb2a1a9" +"joepogbm@ggma.co",,,,,,,,,,,,,,,"2021-02-03T19:26:52Z","2021-02-03T19:27:21Z","a2a1f3f4-0170-4fbd-9152-ffe8cbcdb93d" +"fake_email_17@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:29Z","2021-02-01T12:35:59Z","e45af829-de4e-44d6-9c89-bb0c7ce47925" +"fake_email_15@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:27Z","2021-02-01T12:35:56Z","50b36a31-daf8-45c4-bc48-13e150f6746e" +"fake_email_7@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:18Z","2021-02-01T12:35:47Z","353113b9-b41e-480a-bf98-72213350194c" +"y.kurochkin@zazmic.com",,,,,,,,,,,,,,,"2021-02-03T19:34:41Z","2021-02-03T19:35:47Z","0b62947e-de93-419e-8c96-83572bf15ed1" +"fake_email_19@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:31Z","2021-02-01T12:36:01Z","9932d677-1128-47e4-9d97-667c6155bfee" +"joepogbum@ggma.co",,,,,,,,,,,,,,,"2021-02-03T19:22:41Z","2021-02-03T19:23:10Z","ba3c48d5-b63b-48e6-8687-c5034ed0a8dd" +"fake_email_0@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:34:49Z","2021-02-01T12:35:19Z","44ec451f-d401-40d2-831d-3e3ce8a94f66" +"avida.d3@gmail.com","dima","dima",,,,,,,,,,,,,"2021-09-08T09:02:22Z","2021-09-08T09:04:58Z","2f7b13f2-60d2-462a-bfb0-d30bb8eabed8" +"fake_email_16@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:28Z","2021-02-01T12:35:57Z","c6cfd936-e327-48da-aa76-824076461d80" +"fake_email_11@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:23Z","2021-02-01T12:35:52Z","4101feb2-2b07-4aef-8eb5-62878b612fcd" +"fake_email_5@lmail.c","Fake contact","Lastname",,,,,"22341",,,,,,,,"2021-02-01T12:35:16Z","2021-02-01T12:35:45Z","32deb20d-9f8f-44b4-aed2-dc15d5bf45ba" diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/extractors/test_response_to_file_extractor.py b/airbyte-cdk/python/unit_tests/sources/declarative/extractors/test_response_to_file_extractor.py new file mode 100644 index 0000000000000..33ed74d395fdf --- /dev/null +++ b/airbyte-cdk/python/unit_tests/sources/declarative/extractors/test_response_to_file_extractor.py @@ -0,0 +1,54 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. +from io import BytesIO +from pathlib import Path +from unittest import TestCase + +import requests +import requests_mock +from airbyte_cdk.sources.declarative.extractors import ResponseToFileExtractor + + +class ResponseToFileExtractorTest(TestCase): + def setUp(self) -> None: + self._extractor = ResponseToFileExtractor() + self._http_mocker = requests_mock.Mocker() + self._http_mocker.__enter__() + + def tearDown(self) -> None: + self._http_mocker.__exit__(None, None, None) + + def test_compressed_response(self) -> None: + response = self._mock_streamed_response_from_file(self._compressed_response_path()) + extracted_records = list(self._extractor.extract_records(response)) + assert len(extracted_records) == 24 + + def test_text_response(self) -> None: + response = self._mock_streamed_response_from_file(self._decompressed_response_path()) + extracted_records = list(self._extractor.extract_records(response)) + assert len(extracted_records) == 24 + + def test_text_response_with_null_bytes(self) -> None: + csv_with_null_bytes = '"FIRST_\x00NAME","LAST_NAME"\n"a first n\x00ame","a last na\x00me"\n' + response = self._mock_streamed_response(BytesIO(csv_with_null_bytes.encode("utf-8"))) + + extracted_records = list(self._extractor.extract_records(response)) + + assert extracted_records == [{"FIRST_NAME": "a first name", "LAST_NAME": "a last name"}] + + def _test_folder_path(self) -> Path: + return Path(__file__).parent.resolve() + + def _compressed_response_path(self) -> Path: + return self._test_folder_path() / "compressed_response" + + def _decompressed_response_path(self) -> Path: + return self._test_folder_path() / "decompressed_response.csv" + + def _mock_streamed_response_from_file(self, path: Path) -> requests.Response: + with path.open("rb") as f: + return self._mock_streamed_response(f) # type: ignore # Could not find the right typing for file io + + def _mock_streamed_response(self, io: BytesIO) -> requests.Response: + any_url = "https://anyurl.com" + self._http_mocker.register_uri("GET", any_url, [{"body": io, "status_code": 200}]) + return requests.get(any_url) diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/incremental/test_per_partition_cursor.py b/airbyte-cdk/python/unit_tests/sources/declarative/incremental/test_per_partition_cursor.py index b2c8d5faf46d6..823405cb5152a 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/incremental/test_per_partition_cursor.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/incremental/test_per_partition_cursor.py @@ -6,12 +6,10 @@ from unittest.mock import Mock import pytest -from airbyte_cdk.models import FailureType from airbyte_cdk.sources.declarative.incremental.declarative_cursor import DeclarativeCursor from airbyte_cdk.sources.declarative.incremental.per_partition_cursor import PerPartitionCursor, PerPartitionKeySerializer, StreamSlice from airbyte_cdk.sources.declarative.partition_routers.partition_router import PartitionRouter from airbyte_cdk.sources.types import Record -from airbyte_cdk.utils import AirbyteTracedException PARTITION = { "partition_key string": "partition value", @@ -519,10 +517,37 @@ def test_get_stream_state_includes_parent_state(mocked_cursor_factory, mocked_pa assert stream_state == expected_state -def test_given_invalid_state_when_set_initial_state_then_raise_config_error(mocked_cursor_factory, mocked_partition_router) -> None: - cursor = PerPartitionCursor(mocked_cursor_factory, mocked_partition_router) - - with pytest.raises(AirbyteTracedException) as exception: - cursor.set_initial_state({"invalid_state": 1}) +def test_per_partition_state_when_set_initial_global_state(mocked_cursor_factory, mocked_partition_router) -> None: + first_partition = {"first_partition_key": "first_partition_value"} + second_partition = {"second_partition_key": "second_partition_value"} + global_state = {"global_state_format_key": "global_state_format_value"} - assert exception.value.failure_type == FailureType.config_error + mocked_partition_router.stream_slices.return_value = [ + StreamSlice(partition=first_partition, cursor_slice={}), + StreamSlice(partition=second_partition, cursor_slice={}), + ] + mocked_cursor_factory.create.side_effect = [ + MockedCursorBuilder().with_stream_state(global_state).build(), + MockedCursorBuilder().with_stream_state(global_state).build(), + ] + cursor = PerPartitionCursor(mocked_cursor_factory, mocked_partition_router) + global_state = {"global_state_format_key": "global_state_format_value"} + cursor.set_initial_state(global_state) + assert cursor._state_to_migrate_from == global_state + list(cursor.stream_slices()) + assert cursor._cursor_per_partition['{"first_partition_key":"first_partition_value"}'].set_initial_state.call_count == 1 + assert cursor._cursor_per_partition['{"first_partition_key":"first_partition_value"}'].set_initial_state.call_args[0] == ( + {"global_state_format_key": "global_state_format_value"}, + ) + assert cursor._cursor_per_partition['{"second_partition_key":"second_partition_value"}'].set_initial_state.call_count == 1 + assert cursor._cursor_per_partition['{"second_partition_key":"second_partition_value"}'].set_initial_state.call_args[0] == ( + {"global_state_format_key": "global_state_format_value"}, + ) + expected_state = [ + {"cursor": {"global_state_format_key": "global_state_format_value"}, "partition": {"first_partition_key": "first_partition_value"}}, + { + "cursor": {"global_state_format_key": "global_state_format_value"}, + "partition": {"second_partition_key": "second_partition_value"}, + }, + ] + assert cursor.get_stream_state()["states"] == expected_state diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/requesters/test_http_job_repository.py b/airbyte-cdk/python/unit_tests/sources/declarative/requesters/test_http_job_repository.py new file mode 100644 index 0000000000000..17966e963eac7 --- /dev/null +++ b/airbyte-cdk/python/unit_tests/sources/declarative/requesters/test_http_job_repository.py @@ -0,0 +1,180 @@ +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. + + +import json +from unittest import TestCase +from unittest.mock import Mock + +import pytest +from airbyte_cdk.sources.declarative.async_job.status import AsyncJobStatus +from airbyte_cdk.sources.declarative.decoders.json_decoder import JsonDecoder +from airbyte_cdk.sources.declarative.extractors import DpathExtractor +from airbyte_cdk.sources.declarative.requesters.error_handlers import DefaultErrorHandler +from airbyte_cdk.sources.declarative.requesters.http_job_repository import AsyncHttpJobRepository +from airbyte_cdk.sources.declarative.requesters.http_requester import HttpRequester +from airbyte_cdk.sources.declarative.requesters.requester import HttpMethod +from airbyte_cdk.sources.types import StreamSlice +from airbyte_cdk.test.mock_http import HttpMocker, HttpRequest, HttpResponse + +_ANY_CONFIG = {} +_ANY_SLICE = StreamSlice(partition={}, cursor_slice={}) +_URL_BASE = "https://api.sendgrid.com/v3/" +_EXPORT_PATH = "marketing/contacts/exports" +_EXPORT_URL = f"{_URL_BASE}{_EXPORT_PATH}" +_A_JOB_ID = "a-job-id" +_ANOTHER_JOB_ID = "another-job-id" +_JOB_FIRST_URL = "https://job.result.api.com/1" +_JOB_SECOND_URL = "https://job.result.api.com/2" +_A_CSV_WITH_ONE_RECORD = """id,value +a_record_id,a_value +""" + + +class HttpJobRepositoryTest(TestCase): + def setUp(self) -> None: + message_repository = Mock() + error_handler = DefaultErrorHandler(config=_ANY_CONFIG, parameters={}) + + self._create_job_requester = HttpRequester( + name="stream : create_job", + url_base=_URL_BASE, + path=_EXPORT_PATH, + error_handler=error_handler, + http_method=HttpMethod.POST, + config=_ANY_CONFIG, + disable_retries=False, + parameters={}, + message_repository=message_repository, + use_cache=False, + stream_response=False, + ) + + self._polling_job_requester = HttpRequester( + name="stream : polling", + url_base=_URL_BASE, + path=_EXPORT_PATH + "/{{stream_slice['create_job_response'].json()['id']}}", + error_handler=error_handler, + http_method=HttpMethod.GET, + config=_ANY_CONFIG, + disable_retries=False, + parameters={}, + message_repository=message_repository, + use_cache=False, + stream_response=False, + ) + + self._download_job_requester = HttpRequester( + name="stream : fetch_result", + url_base="", + path="{{stream_slice['url']}}", + error_handler=error_handler, + http_method=HttpMethod.GET, + config=_ANY_CONFIG, + disable_retries=False, + parameters={}, + message_repository=message_repository, + use_cache=False, + stream_response=True, + ) + + self._repository = AsyncHttpJobRepository( + creation_requester=self._create_job_requester, + polling_requester=self._polling_job_requester, + download_requester=self._download_job_requester, + status_extractor=DpathExtractor(decoder=JsonDecoder(parameters={}), field_path=["status"], config={}, parameters={} or {}), + status_mapping={ + "ready": AsyncJobStatus.COMPLETED, + "failure": AsyncJobStatus.FAILED, + "pending": AsyncJobStatus.RUNNING, + }, + urls_extractor=DpathExtractor(decoder=JsonDecoder(parameters={}), field_path=["urls"], config={}, parameters={} or {}), + ) + + self._http_mocker = HttpMocker() + self._http_mocker.__enter__() + + def tearDown(self) -> None: + self._http_mocker.__exit__(None, None, None) + + def test_given_different_statuses_when_update_jobs_status_then_update_status_properly(self) -> None: + self._mock_create_response(_A_JOB_ID) + self._http_mocker.get( + HttpRequest(url=f"{_EXPORT_URL}/{_A_JOB_ID}"), + [ + HttpResponse(body=json.dumps({"id": _A_JOB_ID, "status": "pending"})), + HttpResponse(body=json.dumps({"id": _A_JOB_ID, "status": "failure"})), + HttpResponse(body=json.dumps({"id": _A_JOB_ID, "status": "ready"})), + ] + ) + job = self._repository.start(_ANY_SLICE) + + self._repository.update_jobs_status([job]) + assert job.status() == AsyncJobStatus.RUNNING + self._repository.update_jobs_status([job]) + assert job.status() == AsyncJobStatus.FAILED + self._repository.update_jobs_status([job]) + assert job.status() == AsyncJobStatus.COMPLETED + + def test_given_unknown_status_when_update_jobs_status_then_raise_error(self) -> None: + self._mock_create_response(_A_JOB_ID) + self._http_mocker.get( + HttpRequest(url=f"{_EXPORT_URL}/{_A_JOB_ID}"), + HttpResponse(body=json.dumps({"id": _A_JOB_ID, "status": "invalid_status"})), + ) + job = self._repository.start(_ANY_SLICE) + + with pytest.raises(ValueError): + self._repository.update_jobs_status([job]) + + def test_given_multiple_jobs_when_update_jobs_status_then_all_the_jobs_are_updated(self) -> None: + self._mock_create_response(_A_JOB_ID) + self._http_mocker.get( + HttpRequest(url=f"{_EXPORT_URL}/{_A_JOB_ID}"), + HttpResponse(body=json.dumps({"id": _A_JOB_ID, "status": "ready"})), + ) + self._mock_create_response(_ANOTHER_JOB_ID) + self._http_mocker.get( + HttpRequest(url=f"{_EXPORT_URL}/{_ANOTHER_JOB_ID}"), + HttpResponse(body=json.dumps({"id": _A_JOB_ID, "status": "ready"})), + ) + a_job = self._repository.start(_ANY_SLICE) + another_job = self._repository.start(_ANY_SLICE) + + self._repository.update_jobs_status([a_job, another_job]) + + assert a_job.status() == AsyncJobStatus.COMPLETED + assert another_job.status() == AsyncJobStatus.COMPLETED + + def test_given_multiple_urls_when_fetch_records_then_fetch_from_multiple_urls(self) -> None: + self._mock_create_response(_A_JOB_ID) + self._http_mocker.get( + HttpRequest(url=f"{_EXPORT_URL}/{_A_JOB_ID}"), + HttpResponse(body=json.dumps({ + "id": _A_JOB_ID, + "status": "ready", + "urls": [ + _JOB_FIRST_URL, + _JOB_SECOND_URL, + ] + })) + ) + self._http_mocker.get( + HttpRequest(url=_JOB_FIRST_URL), + HttpResponse(body=_A_CSV_WITH_ONE_RECORD), + ) + self._http_mocker.get( + HttpRequest(url=_JOB_SECOND_URL), + HttpResponse(body=_A_CSV_WITH_ONE_RECORD), + ) + + job = self._repository.start(_ANY_SLICE) + self._repository.update_jobs_status([job]) + records = list(self._repository.fetch_records(job)) + + assert len(records) == 2 + + def _mock_create_response(self, job_id: str) -> None: + self._http_mocker.post( + HttpRequest(url=_EXPORT_URL), + HttpResponse(body=json.dumps({"id": job_id})), + ) diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_add_fields.py b/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_add_fields.py index 83d5f19e85855..9b46cf49b99b5 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_add_fields.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_add_fields.py @@ -132,4 +132,5 @@ def test_add_fields( expected: Mapping[str, Any], ): inputs = [AddedFieldDefinition(path=v[0], value=v[1], value_type=field_type, parameters={}) for v in field] - assert AddFields(fields=inputs, parameters={"alas": "i live"}).transform(input_record, **kwargs) == expected + AddFields(fields=inputs, parameters={"alas": "i live"}).transform(input_record, **kwargs) + assert input_record == expected diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_keys_to_lower_transformation.py b/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_keys_to_lower_transformation.py new file mode 100644 index 0000000000000..7464b9f04fd2f --- /dev/null +++ b/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_keys_to_lower_transformation.py @@ -0,0 +1,13 @@ +# +# Copyright (c) 2024 Airbyte, Inc., all rights reserved. +# + +from airbyte_cdk.sources.declarative.transformations.keys_to_lower_transformation import KeysToLowerTransformation + +_ANY_VALUE = -1 + + +def test_transform() -> None: + record = {"wIth_CapITal": _ANY_VALUE, "anOThEr_witH_Caps": _ANY_VALUE} + KeysToLowerTransformation().transform(record) + assert {"with_capital": _ANY_VALUE, "another_with_caps": _ANY_VALUE} diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_remove_fields.py b/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_remove_fields.py index 0b9d6da5b56d9..89b17e8d0f751 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_remove_fields.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/transformations/test_remove_fields.py @@ -85,4 +85,5 @@ ) def test_remove_fields(input_record: Mapping[str, Any], field_pointers: List[FieldPointer], condition: str, expected: Mapping[str, Any]): transformation = RemoveFields(field_pointers=field_pointers, condition=condition, parameters={}) - assert transformation.transform(input_record) == expected + transformation.transform(input_record) + assert input_record == expected diff --git a/airbyte-ci/connectors/connectors_qa/README.md b/airbyte-ci/connectors/connectors_qa/README.md index c81cb682f944f..a942d0bba7579 100644 --- a/airbyte-ci/connectors/connectors_qa/README.md +++ b/airbyte-ci/connectors/connectors_qa/README.md @@ -108,6 +108,10 @@ poe lint ## Changelog +### 1.8.0 + +Added minimum sl threshold value to documentation checks to skip them for connectors for which sl is 0. + ### 1.7.0 Added `CheckDocumentationLinks`, `CheckDocumentationHeadersOrder`, `CheckPrerequisitesSectionDescribesRequiredFieldsFromSpec`, diff --git a/airbyte-ci/connectors/connectors_qa/pyproject.toml b/airbyte-ci/connectors/connectors_qa/pyproject.toml index 8a3d93eae83a4..ef234cef252c5 100644 --- a/airbyte-ci/connectors/connectors_qa/pyproject.toml +++ b/airbyte-ci/connectors/connectors_qa/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "connectors-qa" -version = "1.7.0" +version = "1.8.0" description = "A package to run QA checks on Airbyte connectors, generate reports and documentation." authors = ["Airbyte "] readme = "README.md" diff --git a/airbyte-ci/connectors/connectors_qa/src/connectors_qa/checks/documentation/documentation.py b/airbyte-ci/connectors/connectors_qa/src/connectors_qa/checks/documentation/documentation.py index aa59d35aa1d75..700b7162ed27e 100644 --- a/airbyte-ci/connectors/connectors_qa/src/connectors_qa/checks/documentation/documentation.py +++ b/airbyte-ci/connectors/connectors_qa/src/connectors_qa/checks/documentation/documentation.py @@ -24,6 +24,7 @@ class DocumentationCheck(Check): category = CheckCategory.DOCUMENTATION + applies_to_connector_ab_internal_sl = 100 class CheckMigrationGuide(DocumentationCheck): diff --git a/airbyte-ci/connectors/live-tests/README.md b/airbyte-ci/connectors/live-tests/README.md index 4eed5ee0a8b50..87a9951a145b3 100644 --- a/airbyte-ci/connectors/live-tests/README.md +++ b/airbyte-ci/connectors/live-tests/README.md @@ -279,6 +279,11 @@ The traffic recorded on the control connector is passed to the target connector ## Changelog +### 0.18.8 + +Improve error message when failing to retrieve connection. +Ask to double-check that a sync ran with the control version on the selected connection. + ### 0.18.7 Improve error message when failing to retrieve connection. diff --git a/airbyte-ci/connectors/live-tests/pyproject.toml b/airbyte-ci/connectors/live-tests/pyproject.toml index 3e164b3bdb40a..411025b8042f2 100644 --- a/airbyte-ci/connectors/live-tests/pyproject.toml +++ b/airbyte-ci/connectors/live-tests/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api" [tool.poetry] name = "live-tests" -version = "0.18.7" +version = "0.18.8" description = "Contains utilities for testing connectors against live data." authors = ["Airbyte "] license = "MIT" diff --git a/airbyte-ci/connectors/live-tests/src/live_tests/commons/connection_objects_retrieval.py b/airbyte-ci/connectors/live-tests/src/live_tests/commons/connection_objects_retrieval.py index 592a3825cd6b7..adcb1c6868cb1 100644 --- a/airbyte-ci/connectors/live-tests/src/live_tests/commons/connection_objects_retrieval.py +++ b/airbyte-ci/connectors/live-tests/src/live_tests/commons/connection_objects_retrieval.py @@ -240,7 +240,7 @@ def _get_connection_objects_from_retrieved_objects( ) elif retrieved_source_docker_image.split(":")[1] != source_docker_image_tag: raise InvalidConnectionError( - f"The provided docker image tag ({source_docker_image_tag}) does not match the image tag for connection ID {connection_id}. Please double check that this connection is using the correct image tag. Connection URL: {connection_url}" + f"The provided docker image tag ({source_docker_image_tag}) does not match the image tag for connection ID {connection_id}. Please double check that this connection is using the correct image tag and the latest job ran using this version. Connection URL: {connection_url}" ) return ConnectionObjects( diff --git a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/AirbyteInternal.py b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/AirbyteInternal.py index c702665213166..8c59150adcdc1 100644 --- a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/AirbyteInternal.py +++ b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/AirbyteInternal.py @@ -13,5 +13,5 @@ class AirbyteInternal(BaseModel): class Config: extra = Extra.allow - sl: Optional[Literal[100, 200, 300]] = None - ql: Optional[Literal[100, 200, 300, 400, 500, 600]] = None + sl: Optional[Literal[0, 100, 200, 300]] = None + ql: Optional[Literal[0, 100, 200, 300, 400, 500, 600]] = None diff --git a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorMetadataDefinitionV0.py b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorMetadataDefinitionV0.py index 2e0af418fe6c2..87970748adda0 100644 --- a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorMetadataDefinitionV0.py +++ b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorMetadataDefinitionV0.py @@ -123,8 +123,8 @@ class AirbyteInternal(BaseModel): class Config: extra = Extra.allow - sl: Optional[Literal[100, 200, 300]] = None - ql: Optional[Literal[100, 200, 300, 400, 500, 600]] = None + sl: Optional[Literal[0, 100, 200, 300]] = None + ql: Optional[Literal[0, 100, 200, 300, 400, 500, 600]] = None class PyPi(BaseModel): diff --git a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryDestinationDefinition.py b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryDestinationDefinition.py index 009a7f225018d..b34f28794f500 100644 --- a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryDestinationDefinition.py +++ b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryDestinationDefinition.py @@ -100,8 +100,8 @@ class AirbyteInternal(BaseModel): class Config: extra = Extra.allow - sl: Optional[Literal[100, 200, 300]] = None - ql: Optional[Literal[100, 200, 300, 400, 500, 600]] = None + sl: Optional[Literal[0, 100, 200, 300]] = None + ql: Optional[Literal[0, 100, 200, 300, 400, 500, 600]] = None class GitInfo(BaseModel): diff --git a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryReleases.py b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryReleases.py index 21696bf0158cd..7db158099e89f 100644 --- a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryReleases.py +++ b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryReleases.py @@ -86,8 +86,8 @@ class AirbyteInternal(BaseModel): class Config: extra = Extra.allow - sl: Optional[Literal[100, 200, 300]] = None - ql: Optional[Literal[100, 200, 300, 400, 500, 600]] = None + sl: Optional[Literal[0, 100, 200, 300]] = None + ql: Optional[Literal[0, 100, 200, 300, 400, 500, 600]] = None class GitInfo(BaseModel): diff --git a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistrySourceDefinition.py b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistrySourceDefinition.py index 4b0124284fd60..016ede2915aa4 100644 --- a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistrySourceDefinition.py +++ b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistrySourceDefinition.py @@ -100,8 +100,8 @@ class AirbyteInternal(BaseModel): class Config: extra = Extra.allow - sl: Optional[Literal[100, 200, 300]] = None - ql: Optional[Literal[100, 200, 300, 400, 500, 600]] = None + sl: Optional[Literal[0, 100, 200, 300]] = None + ql: Optional[Literal[0, 100, 200, 300, 400, 500, 600]] = None class GitInfo(BaseModel): diff --git a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryV0.py b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryV0.py index 715bbc0dfe626..30c234cedf76a 100644 --- a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryV0.py +++ b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/generated/ConnectorRegistryV0.py @@ -100,8 +100,8 @@ class AirbyteInternal(BaseModel): class Config: extra = Extra.allow - sl: Optional[Literal[100, 200, 300]] = None - ql: Optional[Literal[100, 200, 300, 400, 500, 600]] = None + sl: Optional[Literal[0, 100, 200, 300]] = None + ql: Optional[Literal[0, 100, 200, 300, 400, 500, 600]] = None class GitInfo(BaseModel): diff --git a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/src/AirbyteInternal.yaml b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/src/AirbyteInternal.yaml index 9376d99a76fdb..b74f56f638fe3 100644 --- a/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/src/AirbyteInternal.yaml +++ b/airbyte-ci/connectors/metadata_service/lib/metadata_service/models/src/AirbyteInternal.yaml @@ -9,12 +9,14 @@ properties: sl: type: integer enum: + - 0 - 100 - 200 - 300 ql: type: integer enum: + - 0 - 100 - 200 - 300 diff --git a/airbyte-ci/connectors/metadata_service/lib/pyproject.toml b/airbyte-ci/connectors/metadata_service/lib/pyproject.toml index 839b6dfd9c880..9e9e5127f88bc 100644 --- a/airbyte-ci/connectors/metadata_service/lib/pyproject.toml +++ b/airbyte-ci/connectors/metadata_service/lib/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "metadata-service" -version = "0.14.1" +version = "0.15.0" description = "" authors = ["Ben Church "] readme = "README.md" diff --git a/airbyte-ci/connectors/metadata_service/lib/tests/test_validators/test_metadata_validators.py b/airbyte-ci/connectors/metadata_service/lib/tests/test_validators/test_metadata_validators.py index a0d823b2fde1c..132beeaf008d9 100644 --- a/airbyte-ci/connectors/metadata_service/lib/tests/test_validators/test_metadata_validators.py +++ b/airbyte-ci/connectors/metadata_service/lib/tests/test_validators/test_metadata_validators.py @@ -71,10 +71,8 @@ def test_validation_fail_on_docker_image_tag_decrement(metadata_definition, decr metadata_definition.data.dockerImageTag = decremented_version success, error_message = metadata_validator.validate_docker_image_tag_is_not_decremented(metadata_definition, None) assert not success - assert ( - error_message - == f"The dockerImageTag value ({decremented_version}) can't be decremented: it should be equal to or above {current_version}." - ) + expected_prefix = f"The dockerImageTag value ({decremented_version}) can't be decremented: it should be equal to or above" + assert error_message.startswith(expected_prefix), error_message def test_validation_pass_on_docker_image_tag_increment(metadata_definition, incremented_version): diff --git a/airbyte-ci/connectors/metadata_service/orchestrator/pyproject.toml b/airbyte-ci/connectors/metadata_service/orchestrator/pyproject.toml index 85a097ca6aa23..d1fd3464f99c1 100644 --- a/airbyte-ci/connectors/metadata_service/orchestrator/pyproject.toml +++ b/airbyte-ci/connectors/metadata_service/orchestrator/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "orchestrator" -version = "0.5.4" +version = "0.5.5" description = "" authors = ["Ben Church "] readme = "README.md" diff --git a/airbyte-ci/connectors/pipelines/README.md b/airbyte-ci/connectors/pipelines/README.md index effc227180c9b..98114ab545de5 100644 --- a/airbyte-ci/connectors/pipelines/README.md +++ b/airbyte-ci/connectors/pipelines/README.md @@ -843,6 +843,7 @@ airbyte-ci connectors --language=low-code migrate-to-manifest-only | Version | PR | Description | | ------- | ---------------------------------------------------------- |------------------------------------------------------------------------------------------------------------------------------| +| 4.35.2 | [#45360](https://github.com/airbytehq/airbyte/pull/45360) | Updated dependencies. | | 4.35.1 | [#45160](https://github.com/airbytehq/airbyte/pull/45160) | Remove deps.toml dependency for java connectors. | | 4.35.0 | [#44879](https://github.com/airbytehq/airbyte/pull/44879) | Mount `components.py` when building manifest-only connector image | | 4.34.2 | [#44786](https://github.com/airbytehq/airbyte/pull/44786) | Pre-emptively skip archived connectors when searching for modified files | diff --git a/airbyte-ci/connectors/pipelines/pyproject.toml b/airbyte-ci/connectors/pipelines/pyproject.toml index 5ad7203d1b355..b6551d8b74238 100644 --- a/airbyte-ci/connectors/pipelines/pyproject.toml +++ b/airbyte-ci/connectors/pipelines/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api" [tool.poetry] name = "pipelines" -version = "4.35.1" +version = "4.35.2" description = "Packaged maintained by the connector operations team to perform CI for connectors' pipelines" authors = ["Airbyte "] diff --git a/airbyte-integrations/connectors/destination-databricks/metadata.yaml b/airbyte-integrations/connectors/destination-databricks/metadata.yaml index 7b506d7bce569..1f0f3a93ac78e 100644 --- a/airbyte-integrations/connectors/destination-databricks/metadata.yaml +++ b/airbyte-integrations/connectors/destination-databricks/metadata.yaml @@ -2,7 +2,7 @@ data: connectorSubtype: database connectorType: destination definitionId: 072d5540-f236-4294-ba7c-ade8fd918496 - dockerImageTag: 3.2.3 + dockerImageTag: 3.2.4 dockerRepository: airbyte/destination-databricks githubIssueLabel: destination-databricks icon: databricks.svg diff --git a/airbyte-integrations/connectors/destination-databricks/src/main/kotlin/io/airbyte/integrations/destination/databricks/DatabricksDestination.kt b/airbyte-integrations/connectors/destination-databricks/src/main/kotlin/io/airbyte/integrations/destination/databricks/DatabricksDestination.kt index 882579ca3f419..9e5ba3f2b9129 100644 --- a/airbyte-integrations/connectors/destination-databricks/src/main/kotlin/io/airbyte/integrations/destination/databricks/DatabricksDestination.kt +++ b/airbyte-integrations/connectors/destination-databricks/src/main/kotlin/io/airbyte/integrations/destination/databricks/DatabricksDestination.kt @@ -11,26 +11,33 @@ import io.airbyte.cdk.integrations.base.AirbyteMessageConsumer import io.airbyte.cdk.integrations.base.Destination import io.airbyte.cdk.integrations.base.IntegrationRunner import io.airbyte.cdk.integrations.base.SerializedAirbyteMessageConsumer +import io.airbyte.cdk.integrations.destination.StreamSyncSummary import io.airbyte.cdk.integrations.destination.async.AsyncStreamConsumer import io.airbyte.cdk.integrations.destination.async.buffers.BufferManager import io.airbyte.cdk.integrations.destination.async.deser.AirbyteMessageDeserializer +import io.airbyte.cdk.integrations.destination.async.model.PartialAirbyteMessage +import io.airbyte.cdk.integrations.destination.async.model.PartialAirbyteRecordMessage import io.airbyte.cdk.integrations.destination.s3.FileUploadFormat import io.airbyte.integrations.base.destination.operation.DefaultFlush import io.airbyte.integrations.base.destination.operation.DefaultSyncOperation import io.airbyte.integrations.base.destination.typing_deduping.CatalogParser +import io.airbyte.integrations.base.destination.typing_deduping.DestinationInitialStatus import io.airbyte.integrations.base.destination.typing_deduping.ImportType +import io.airbyte.integrations.base.destination.typing_deduping.InitialRawTableStatus import io.airbyte.integrations.base.destination.typing_deduping.Sql import io.airbyte.integrations.base.destination.typing_deduping.StreamConfig -import io.airbyte.integrations.base.destination.typing_deduping.StreamId +import io.airbyte.integrations.base.destination.typing_deduping.migrators.MinimumDestinationState import io.airbyte.integrations.destination.databricks.jdbc.DatabricksDestinationHandler import io.airbyte.integrations.destination.databricks.jdbc.DatabricksNamingTransformer import io.airbyte.integrations.destination.databricks.jdbc.DatabricksSqlGenerator import io.airbyte.integrations.destination.databricks.model.DatabricksConnectorConfig import io.airbyte.integrations.destination.databricks.operation.DatabricksStorageOperation +import io.airbyte.integrations.destination.databricks.operation.DatabricksStreamOperation import io.airbyte.integrations.destination.databricks.operation.DatabricksStreamOperationFactory -import io.airbyte.integrations.destination.databricks.staging.DatabricksFileBufferFactory import io.airbyte.protocol.models.v0.AirbyteConnectionStatus import io.airbyte.protocol.models.v0.AirbyteMessage +import io.airbyte.protocol.models.v0.AirbyteRecordMessageMeta +import io.airbyte.protocol.models.v0.AirbyteStreamStatusTraceMessage import io.airbyte.protocol.models.v0.ConfiguredAirbyteCatalog import io.github.oshai.kotlinlogging.KotlinLogging import java.util.* @@ -50,124 +57,146 @@ class DatabricksDestination : BaseConnector(), Destination { } override fun check(config: JsonNode): AirbyteConnectionStatus? { - // TODO: Add proper checks for - // Check schema permissions, or if raw_override and default already exists - // Check catalog permissions to USE catalog - // Check CREATE volume, COPY INTO, File upload permissions - // Check Table creation, Table drop permissions - val connectorConfig = DatabricksConnectorConfig.deserialize(config) - val sqlGenerator = - DatabricksSqlGenerator(DatabricksNamingTransformer(), connectorConfig.database) - val datasource = DatabricksConnectorClientsFactory.createDataSource(connectorConfig) - val jdbcDatabase = DefaultJdbcDatabase(datasource) - val destinationHandler = - DatabricksDestinationHandler(sqlGenerator, connectorConfig.database, jdbcDatabase) - val workspaceClient = - DatabricksConnectorClientsFactory.createWorkspaceClient( - connectorConfig.hostname, - connectorConfig.authentication - ) - val storageOperations = - DatabricksStorageOperation( - sqlGenerator, - destinationHandler, - workspaceClient, - connectorConfig.database, - connectorConfig.purgeStagingData - ) - val dummyNamespace = connectorConfig.rawSchemaOverride - val dummyName = "airbyte_check_test_table" - val streamId = - StreamId( - dummyNamespace, - dummyName, - dummyNamespace, - dummyName, - dummyNamespace, - dummyName - ) - val streamConfig = - StreamConfig( - id = streamId, - postImportAction = ImportType.APPEND, - primaryKey = listOf(), - cursor = Optional.empty(), - columns = linkedMapOf(), - generationId = 1, - minimumGenerationId = 1, - syncId = 0 - ) - - // quick utility method to drop the airbyte_check_test_table table - // returns a connection status if there was an error, or null on success - fun dropCheckTable(): AirbyteConnectionStatus? { - val dropCheckTableStatement = - "DROP TABLE IF EXISTS `${connectorConfig.database}`.`${streamId.rawNamespace}`.`${streamId.rawName}`;" - try { - destinationHandler.execute( - Sql.of( - dropCheckTableStatement, - ), + try { + val connectorConfig = DatabricksConnectorConfig.deserialize(config) + val datasource = DatabricksConnectorClientsFactory.createDataSource(connectorConfig) + val sqlGenerator = + DatabricksSqlGenerator(DatabricksNamingTransformer(), connectorConfig.database) + val jdbcDatabase = DefaultJdbcDatabase(datasource) + val destinationHandler = + DatabricksDestinationHandler(sqlGenerator, connectorConfig.database, jdbcDatabase) + val workspaceClient = + DatabricksConnectorClientsFactory.createWorkspaceClient( + connectorConfig.hostname, + connectorConfig.authentication ) - } catch (e: Exception) { - log.error(e) { "Failed to execute query $dropCheckTableStatement" } - return AirbyteConnectionStatus() - .withStatus(AirbyteConnectionStatus.Status.FAILED) - .withMessage("Failed to execute $dropCheckTableStatement: ${e.message}") - } - return null - } + val storageOperation = + DatabricksStorageOperation( + sqlGenerator, + destinationHandler, + workspaceClient, + connectorConfig.database, + connectorConfig.purgeStagingData + ) + val rawTableNamespace = connectorConfig.rawSchemaOverride + val finalTableName = "airbyte_check_test_table" - // Before we start, clean up any preexisting check table from a previous attempt. - dropCheckTable()?.let { - return it - } + // Both raw & final Namespaces are same for dummy sync since we don't do any final table + // operations + // in check + val streamId = + sqlGenerator.buildStreamId(rawTableNamespace, finalTableName, rawTableNamespace) + val streamConfig = + StreamConfig( + id = streamId, + postImportAction = ImportType.APPEND, + primaryKey = listOf(), + cursor = Optional.empty(), + columns = linkedMapOf(), + generationId = 1, + minimumGenerationId = 1, + syncId = 0 + ) - try { - storageOperations.prepareStage(streamId, suffix = "") - } catch (e: Exception) { - log.error(e) { "Failed to prepare stage as part of CHECK" } - return AirbyteConnectionStatus() - .withStatus(AirbyteConnectionStatus.Status.FAILED) - .withMessage("Failed to prepare stage") - } + // quick utility method to drop the airbyte_check_test_table table + // returns a connection status if there was an error, or null on success + fun dropCheckTable(): AirbyteConnectionStatus? { + val dropCheckTableStatement = + "DROP TABLE IF EXISTS `${connectorConfig.database}`.`${streamId.rawNamespace}`.`${streamId.rawName}`;" + try { + destinationHandler.execute( + Sql.of( + dropCheckTableStatement, + ), + ) + } catch (e: Exception) { + log.error(e) { "Failed to execute query $dropCheckTableStatement" } + return AirbyteConnectionStatus() + .withStatus(AirbyteConnectionStatus.Status.FAILED) + .withMessage("Failed to execute $dropCheckTableStatement: ${e.message}") + } + return null + } - try { - val writeBuffer = DatabricksFileBufferFactory.createBuffer(FileUploadFormat.CSV) - writeBuffer.use { - it.accept( - "{\"airbyte_check\":\"passed\"}", - "{}", - generationId = 0, - System.currentTimeMillis() + // None of the fields in destination initial status matter + // for a dummy sync with type-dedupe disabled. We only look at these + // when we perform final table related setup operations. + // We just need the streamId to perform the calls in streamOperation. + val initialStatus = + DestinationInitialStatus( + streamConfig = streamConfig, + isFinalTablePresent = false, + initialRawTableStatus = + InitialRawTableStatus( + rawTableExists = false, + hasUnprocessedRecords = true, + maxProcessedTimestamp = Optional.empty() + ), + initialTempRawTableStatus = + InitialRawTableStatus( + rawTableExists = false, + hasUnprocessedRecords = true, + maxProcessedTimestamp = Optional.empty() + ), + isSchemaMismatch = true, + isFinalTableEmpty = true, + destinationState = MinimumDestinationState.Impl(needsSoftReset = false), + finalTableGenerationId = null, + finalTempTableGenerationId = null, ) - it.flush() - storageOperations.writeToStage(streamConfig, suffix = "", writeBuffer) + + // We simulate a mini-sync to see the raw table code path is exercised. and disable T+D + // This code is similar to Snowflake's Check + destinationHandler.createNamespaces(setOf(rawTableNamespace)) + // Before we start, clean up any preexisting check table from a previous attempt. + // Even though we clean up at the end. This exists because some version of the old + // connector + // didn't clean up properly and to let them pass the check we do it both before and + // after. + dropCheckTable()?.let { + return it } - } catch (e: Exception) { - log.error(e) { "Failed to write to stage as part of CHECK" } - return AirbyteConnectionStatus() - .withStatus(AirbyteConnectionStatus.Status.FAILED) - .withMessage("Failed to write to stage") - } + val streamOperation = + DatabricksStreamOperation( + storageOperation, + initialStatus, + FileUploadFormat.CSV, + disableTypeDedupe = true + ) - try { - storageOperations.cleanupStage(streamId) + val data = + """ + {"airbyte_check": "passed"} + """.trimIndent() + val message = + PartialAirbyteMessage() + .withSerialized(data) + .withRecord( + PartialAirbyteRecordMessage() + .withEmittedAt(System.currentTimeMillis()) + .withMeta( + AirbyteRecordMessageMeta(), + ), + ) + + streamOperation.writeRecords(streamConfig, listOf(message).stream()) + streamOperation.finalizeTable( + streamConfig, + StreamSyncSummary(1, AirbyteStreamStatusTraceMessage.AirbyteStreamStatus.COMPLETE) + ) + // Clean up after ourselves. + // Not _strictly_ necessary since we do this at the start of `check`, + // but it's slightly nicer. + dropCheckTable()?.let { + return it + } + return AirbyteConnectionStatus().withStatus(AirbyteConnectionStatus.Status.SUCCEEDED) } catch (e: Exception) { - log.error(e) { "Failed to cleanup stage" } + log.error(e) { "Failed to execute check" } return AirbyteConnectionStatus() .withStatus(AirbyteConnectionStatus.Status.FAILED) - .withMessage("Failed to cleanup stage") + .withMessage("${e.message}") } - - // Clean up after ourselves. - // Not _strictly_ necessary since we do this at the start of `check`, - // but it's slightly nicer. - dropCheckTable()?.let { - return it - } - - return AirbyteConnectionStatus().withStatus(AirbyteConnectionStatus.Status.SUCCEEDED) } override fun getSerializedMessageConsumer( @@ -176,7 +205,6 @@ class DatabricksDestination : BaseConnector(), Destination { outputRecordCollector: Consumer ): SerializedAirbyteMessageConsumer { - // TODO: Deserialization should be taken care by connector runner framework later val connectorConfig = DatabricksConnectorConfig.deserialize(config) val sqlGenerator = diff --git a/airbyte-integrations/connectors/source-declarative-manifest/metadata.yaml b/airbyte-integrations/connectors/source-declarative-manifest/metadata.yaml index 80d0dad57c495..7b574377ef590 100644 --- a/airbyte-integrations/connectors/source-declarative-manifest/metadata.yaml +++ b/airbyte-integrations/connectors/source-declarative-manifest/metadata.yaml @@ -8,7 +8,7 @@ data: connectorType: source definitionId: 64a2f99c-542f-4af8-9a6f-355f1217b436 # This version should not be updated manually - it is updated by the CDK release workflow. - dockerImageTag: 5.2.1 + dockerImageTag: 5.5.2 dockerRepository: airbyte/source-declarative-manifest # This page is hidden from the docs for now, since the connector is not in any Airbyte registries. documentationUrl: https://docs.airbyte.com/integrations/sources/low-code diff --git a/airbyte-integrations/connectors/source-declarative-manifest/poetry.lock b/airbyte-integrations/connectors/source-declarative-manifest/poetry.lock index 94b436b90189f..646e9fc36b188 100644 --- a/airbyte-integrations/connectors/source-declarative-manifest/poetry.lock +++ b/airbyte-integrations/connectors/source-declarative-manifest/poetry.lock @@ -2,13 +2,13 @@ [[package]] name = "airbyte-cdk" -version = "5.2.1" +version = "5.5.2" description = "A framework for writing Airbyte Connectors." optional = false python-versions = "<4.0,>=3.10" files = [ - {file = "airbyte_cdk-5.2.1-py3-none-any.whl", hash = "sha256:b6d19a36e35c5002c248e0c09beb8d5d23ef045ad0bfa8fecbad8ad227641890"}, - {file = "airbyte_cdk-5.2.1.tar.gz", hash = "sha256:940c1b1f94d476584ba49d2d126ec77da14104b7ca1e4d7e25e0836f15cd25cc"}, + {file = "airbyte_cdk-5.5.2-py3-none-any.whl", hash = "sha256:cbca686ce52b1b26a49801308927662ef477400ca0142832f06f0add3073bf0e"}, + {file = "airbyte_cdk-5.5.2.tar.gz", hash = "sha256:7e105be721a141979852229fbeb1a2aaf12bd2adf6b51806867f07ca4c3d365b"}, ] [package.dependencies] @@ -26,6 +26,7 @@ jsonschema = ">=3.2.0,<3.3.0" langchain_core = "0.1.42" nltk = "3.8.1" orjson = ">=3.10.7,<4.0.0" +pandas = "2.2.0" pendulum = "<3.0.0" pydantic = ">=2.7,<3.0" pyjwt = ">=2.8.0,<3.0.0" @@ -39,7 +40,7 @@ serpyco-rs = ">=1.10.2,<2.0.0" wcmatch = "8.4" [package.extras] -file-based = ["avro (>=1.11.2,<1.12.0)", "fastavro (>=1.8.0,<1.9.0)", "markdown", "pandas (==2.2.0)", "pdf2image (==1.16.3)", "pdfminer.six (==20221105)", "pyarrow (>=15.0.0,<15.1.0)", "pytesseract (==0.3.10)", "python-calamine (==0.2.3)", "unstructured.pytesseract (>=0.3.12)", "unstructured[docx,pptx] (==0.10.27)"] +file-based = ["avro (>=1.11.2,<1.12.0)", "fastavro (>=1.8.0,<1.9.0)", "markdown", "pdf2image (==1.16.3)", "pdfminer.six (==20221105)", "pyarrow (>=15.0.0,<15.1.0)", "pytesseract (==0.3.10)", "python-calamine (==0.2.3)", "unstructured.pytesseract (>=0.3.12)", "unstructured[docx,pptx] (==0.10.27)"] sphinx-docs = ["Sphinx (>=4.2,<4.3)", "sphinx-rtd-theme (>=1.0,<1.1)"] vector-db-based = ["cohere (==4.21)", "langchain (==0.1.16)", "openai[embeddings] (==0.27.9)", "tiktoken (==0.4.0)"] @@ -711,6 +712,51 @@ plot = ["matplotlib"] tgrep = ["pyparsing"] twitter = ["twython"] +[[package]] +name = "numpy" +version = "1.26.4" +description = "Fundamental package for array computing in Python" +optional = false +python-versions = ">=3.9" +files = [ + {file = "numpy-1.26.4-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:9ff0f4f29c51e2803569d7a51c2304de5554655a60c5d776e35b4a41413830d0"}, + {file = "numpy-1.26.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:2e4ee3380d6de9c9ec04745830fd9e2eccb3e6cf790d39d7b98ffd19b0dd754a"}, + {file = "numpy-1.26.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d209d8969599b27ad20994c8e41936ee0964e6da07478d6c35016bc386b66ad4"}, + {file = "numpy-1.26.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ffa75af20b44f8dba823498024771d5ac50620e6915abac414251bd971b4529f"}, + {file = "numpy-1.26.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:62b8e4b1e28009ef2846b4c7852046736bab361f7aeadeb6a5b89ebec3c7055a"}, + {file = "numpy-1.26.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:a4abb4f9001ad2858e7ac189089c42178fcce737e4169dc61321660f1a96c7d2"}, + {file = "numpy-1.26.4-cp310-cp310-win32.whl", hash = "sha256:bfe25acf8b437eb2a8b2d49d443800a5f18508cd811fea3181723922a8a82b07"}, + {file = "numpy-1.26.4-cp310-cp310-win_amd64.whl", hash = "sha256:b97fe8060236edf3662adfc2c633f56a08ae30560c56310562cb4f95500022d5"}, + {file = "numpy-1.26.4-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:4c66707fabe114439db9068ee468c26bbdf909cac0fb58686a42a24de1760c71"}, + {file = "numpy-1.26.4-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:edd8b5fe47dab091176d21bb6de568acdd906d1887a4584a15a9a96a1dca06ef"}, + {file = "numpy-1.26.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7ab55401287bfec946ced39700c053796e7cc0e3acbef09993a9ad2adba6ca6e"}, + {file = "numpy-1.26.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:666dbfb6ec68962c033a450943ded891bed2d54e6755e35e5835d63f4f6931d5"}, + {file = "numpy-1.26.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:96ff0b2ad353d8f990b63294c8986f1ec3cb19d749234014f4e7eb0112ceba5a"}, + {file = "numpy-1.26.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:60dedbb91afcbfdc9bc0b1f3f402804070deed7392c23eb7a7f07fa857868e8a"}, + {file = "numpy-1.26.4-cp311-cp311-win32.whl", hash = "sha256:1af303d6b2210eb850fcf03064d364652b7120803a0b872f5211f5234b399f20"}, + {file = "numpy-1.26.4-cp311-cp311-win_amd64.whl", hash = "sha256:cd25bcecc4974d09257ffcd1f098ee778f7834c3ad767fe5db785be9a4aa9cb2"}, + {file = "numpy-1.26.4-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:b3ce300f3644fb06443ee2222c2201dd3a89ea6040541412b8fa189341847218"}, + {file = "numpy-1.26.4-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:03a8c78d01d9781b28a6989f6fa1bb2c4f2d51201cf99d3dd875df6fbd96b23b"}, + {file = "numpy-1.26.4-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9fad7dcb1aac3c7f0584a5a8133e3a43eeb2fe127f47e3632d43d677c66c102b"}, + {file = "numpy-1.26.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:675d61ffbfa78604709862923189bad94014bef562cc35cf61d3a07bba02a7ed"}, + {file = "numpy-1.26.4-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:ab47dbe5cc8210f55aa58e4805fe224dac469cde56b9f731a4c098b91917159a"}, + {file = "numpy-1.26.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:1dda2e7b4ec9dd512f84935c5f126c8bd8b9f2fc001e9f54af255e8c5f16b0e0"}, + {file = "numpy-1.26.4-cp312-cp312-win32.whl", hash = "sha256:50193e430acfc1346175fcbdaa28ffec49947a06918b7b92130744e81e640110"}, + {file = "numpy-1.26.4-cp312-cp312-win_amd64.whl", hash = "sha256:08beddf13648eb95f8d867350f6a018a4be2e5ad54c8d8caed89ebca558b2818"}, + {file = "numpy-1.26.4-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:7349ab0fa0c429c82442a27a9673fc802ffdb7c7775fad780226cb234965e53c"}, + {file = "numpy-1.26.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:52b8b60467cd7dd1e9ed082188b4e6bb35aa5cdd01777621a1658910745b90be"}, + {file = "numpy-1.26.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d5241e0a80d808d70546c697135da2c613f30e28251ff8307eb72ba696945764"}, + {file = "numpy-1.26.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f870204a840a60da0b12273ef34f7051e98c3b5961b61b0c2c1be6dfd64fbcd3"}, + {file = "numpy-1.26.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:679b0076f67ecc0138fd2ede3a8fd196dddc2ad3254069bcb9faf9a79b1cebcd"}, + {file = "numpy-1.26.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:47711010ad8555514b434df65f7d7b076bb8261df1ca9bb78f53d3b2db02e95c"}, + {file = "numpy-1.26.4-cp39-cp39-win32.whl", hash = "sha256:a354325ee03388678242a4d7ebcd08b5c727033fcff3b2f536aea978e15ee9e6"}, + {file = "numpy-1.26.4-cp39-cp39-win_amd64.whl", hash = "sha256:3373d5d70a5fe74a2c1bb6d2cfd9609ecf686d47a2d7b1d37a8f3b6bf6003aea"}, + {file = "numpy-1.26.4-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:afedb719a9dcfc7eaf2287b839d8198e06dcd4cb5d276a3df279231138e83d30"}, + {file = "numpy-1.26.4-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:95a7476c59002f2f6c590b9b7b998306fba6a5aa646b1e22ddfeaf8f78c3a29c"}, + {file = "numpy-1.26.4-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:7e50d0a0cc3189f9cb0aeb3a6a6af18c16f59f004b866cd2be1c14b36134a4a0"}, + {file = "numpy-1.26.4.tar.gz", hash = "sha256:2a02aba9ed12e4ac4eb3ea9421c420301a0c6460d9830d74a9df87efa4912010"}, +] + [[package]] name = "orjson" version = "3.10.7" @@ -788,6 +834,77 @@ files = [ {file = "packaging-23.2.tar.gz", hash = "sha256:048fb0e9405036518eaaf48a55953c750c11e1a1b68e0dd1a9d62ed0c092cfc5"}, ] +[[package]] +name = "pandas" +version = "2.2.0" +description = "Powerful data structures for data analysis, time series, and statistics" +optional = false +python-versions = ">=3.9" +files = [ + {file = "pandas-2.2.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:8108ee1712bb4fa2c16981fba7e68b3f6ea330277f5ca34fa8d557e986a11670"}, + {file = "pandas-2.2.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:736da9ad4033aeab51d067fc3bd69a0ba36f5a60f66a527b3d72e2030e63280a"}, + {file = "pandas-2.2.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:38e0b4fc3ddceb56ec8a287313bc22abe17ab0eb184069f08fc6a9352a769b18"}, + {file = "pandas-2.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:20404d2adefe92aed3b38da41d0847a143a09be982a31b85bc7dd565bdba0f4e"}, + {file = "pandas-2.2.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:7ea3ee3f125032bfcade3a4cf85131ed064b4f8dd23e5ce6fa16473e48ebcaf5"}, + {file = "pandas-2.2.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:f9670b3ac00a387620489dfc1bca66db47a787f4e55911f1293063a78b108df1"}, + {file = "pandas-2.2.0-cp310-cp310-win_amd64.whl", hash = "sha256:5a946f210383c7e6d16312d30b238fd508d80d927014f3b33fb5b15c2f895430"}, + {file = "pandas-2.2.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:a1b438fa26b208005c997e78672f1aa8138f67002e833312e6230f3e57fa87d5"}, + {file = "pandas-2.2.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:8ce2fbc8d9bf303ce54a476116165220a1fedf15985b09656b4b4275300e920b"}, + {file = "pandas-2.2.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2707514a7bec41a4ab81f2ccce8b382961a29fbe9492eab1305bb075b2b1ff4f"}, + {file = "pandas-2.2.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:85793cbdc2d5bc32620dc8ffa715423f0c680dacacf55056ba13454a5be5de88"}, + {file = "pandas-2.2.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:cfd6c2491dc821b10c716ad6776e7ab311f7df5d16038d0b7458bc0b67dc10f3"}, + {file = "pandas-2.2.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:a146b9dcacc3123aa2b399df1a284de5f46287a4ab4fbfc237eac98a92ebcb71"}, + {file = "pandas-2.2.0-cp311-cp311-win_amd64.whl", hash = "sha256:fbc1b53c0e1fdf16388c33c3cca160f798d38aea2978004dd3f4d3dec56454c9"}, + {file = "pandas-2.2.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:a41d06f308a024981dcaa6c41f2f2be46a6b186b902c94c2674e8cb5c42985bc"}, + {file = "pandas-2.2.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:159205c99d7a5ce89ecfc37cb08ed179de7783737cea403b295b5eda8e9c56d1"}, + {file = "pandas-2.2.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:eb1e1f3861ea9132b32f2133788f3b14911b68102d562715d71bd0013bc45440"}, + {file = "pandas-2.2.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:761cb99b42a69005dec2b08854fb1d4888fdf7b05db23a8c5a099e4b886a2106"}, + {file = "pandas-2.2.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:a20628faaf444da122b2a64b1e5360cde100ee6283ae8effa0d8745153809a2e"}, + {file = "pandas-2.2.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:f5be5d03ea2073627e7111f61b9f1f0d9625dc3c4d8dda72cc827b0c58a1d042"}, + {file = "pandas-2.2.0-cp312-cp312-win_amd64.whl", hash = "sha256:a626795722d893ed6aacb64d2401d017ddc8a2341b49e0384ab9bf7112bdec30"}, + {file = "pandas-2.2.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:9f66419d4a41132eb7e9a73dcec9486cf5019f52d90dd35547af11bc58f8637d"}, + {file = "pandas-2.2.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:57abcaeda83fb80d447f28ab0cc7b32b13978f6f733875ebd1ed14f8fbc0f4ab"}, + {file = "pandas-2.2.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e60f1f7dba3c2d5ca159e18c46a34e7ca7247a73b5dd1a22b6d59707ed6b899a"}, + {file = "pandas-2.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:eb61dc8567b798b969bcc1fc964788f5a68214d333cade8319c7ab33e2b5d88a"}, + {file = "pandas-2.2.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:52826b5f4ed658fa2b729264d63f6732b8b29949c7fd234510d57c61dbeadfcd"}, + {file = "pandas-2.2.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:bde2bc699dbd80d7bc7f9cab1e23a95c4375de615860ca089f34e7c64f4a8de7"}, + {file = "pandas-2.2.0-cp39-cp39-win_amd64.whl", hash = "sha256:3de918a754bbf2da2381e8a3dcc45eede8cd7775b047b923f9006d5f876802ae"}, + {file = "pandas-2.2.0.tar.gz", hash = "sha256:30b83f7c3eb217fb4d1b494a57a2fda5444f17834f5df2de6b2ffff68dc3c8e2"}, +] + +[package.dependencies] +numpy = [ + {version = ">=1.22.4,<2", markers = "python_version < \"3.11\""}, + {version = ">=1.23.2,<2", markers = "python_version == \"3.11\""}, +] +python-dateutil = ">=2.8.2" +pytz = ">=2020.1" +tzdata = ">=2022.7" + +[package.extras] +all = ["PyQt5 (>=5.15.9)", "SQLAlchemy (>=2.0.0)", "adbc-driver-postgresql (>=0.8.0)", "adbc-driver-sqlite (>=0.8.0)", "beautifulsoup4 (>=4.11.2)", "bottleneck (>=1.3.6)", "dataframe-api-compat (>=0.1.7)", "fastparquet (>=2022.12.0)", "fsspec (>=2022.11.0)", "gcsfs (>=2022.11.0)", "html5lib (>=1.1)", "hypothesis (>=6.46.1)", "jinja2 (>=3.1.2)", "lxml (>=4.9.2)", "matplotlib (>=3.6.3)", "numba (>=0.56.4)", "numexpr (>=2.8.4)", "odfpy (>=1.4.1)", "openpyxl (>=3.1.0)", "pandas-gbq (>=0.19.0)", "psycopg2 (>=2.9.6)", "pyarrow (>=10.0.1)", "pymysql (>=1.0.2)", "pyreadstat (>=1.2.0)", "pytest (>=7.3.2)", "pytest-xdist (>=2.2.0)", "python-calamine (>=0.1.7)", "pyxlsb (>=1.0.10)", "qtpy (>=2.3.0)", "s3fs (>=2022.11.0)", "scipy (>=1.10.0)", "tables (>=3.8.0)", "tabulate (>=0.9.0)", "xarray (>=2022.12.0)", "xlrd (>=2.0.1)", "xlsxwriter (>=3.0.5)", "zstandard (>=0.19.0)"] +aws = ["s3fs (>=2022.11.0)"] +clipboard = ["PyQt5 (>=5.15.9)", "qtpy (>=2.3.0)"] +compression = ["zstandard (>=0.19.0)"] +computation = ["scipy (>=1.10.0)", "xarray (>=2022.12.0)"] +consortium-standard = ["dataframe-api-compat (>=0.1.7)"] +excel = ["odfpy (>=1.4.1)", "openpyxl (>=3.1.0)", "python-calamine (>=0.1.7)", "pyxlsb (>=1.0.10)", "xlrd (>=2.0.1)", "xlsxwriter (>=3.0.5)"] +feather = ["pyarrow (>=10.0.1)"] +fss = ["fsspec (>=2022.11.0)"] +gcp = ["gcsfs (>=2022.11.0)", "pandas-gbq (>=0.19.0)"] +hdf5 = ["tables (>=3.8.0)"] +html = ["beautifulsoup4 (>=4.11.2)", "html5lib (>=1.1)", "lxml (>=4.9.2)"] +mysql = ["SQLAlchemy (>=2.0.0)", "pymysql (>=1.0.2)"] +output-formatting = ["jinja2 (>=3.1.2)", "tabulate (>=0.9.0)"] +parquet = ["pyarrow (>=10.0.1)"] +performance = ["bottleneck (>=1.3.6)", "numba (>=0.56.4)", "numexpr (>=2.8.4)"] +plot = ["matplotlib (>=3.6.3)"] +postgresql = ["SQLAlchemy (>=2.0.0)", "adbc-driver-postgresql (>=0.8.0)", "psycopg2 (>=2.9.6)"] +spss = ["pyreadstat (>=1.2.0)"] +sql-other = ["SQLAlchemy (>=2.0.0)", "adbc-driver-postgresql (>=0.8.0)", "adbc-driver-sqlite (>=0.8.0)"] +test = ["hypothesis (>=6.46.1)", "pytest (>=7.3.2)", "pytest-xdist (>=2.2.0)"] +xml = ["lxml (>=4.9.2)"] + [[package]] name = "pendulum" version = "2.1.2" @@ -1478,6 +1595,17 @@ files = [ {file = "typing_extensions-4.12.2.tar.gz", hash = "sha256:1a7ead55c7e559dd4dee8856e3a88b41225abfe1ce8df57b7c13915fe121ffb8"}, ] +[[package]] +name = "tzdata" +version = "2024.1" +description = "Provider of IANA time zone data" +optional = false +python-versions = ">=2" +files = [ + {file = "tzdata-2024.1-py2.py3-none-any.whl", hash = "sha256:9068bc196136463f5245e51efda838afa15aaeca9903f49050dfa2679db4d252"}, + {file = "tzdata-2024.1.tar.gz", hash = "sha256:2674120f8d891909751c38abcdfd386ac0a5a1127954fbc332af6b5ceae07efd"}, +] + [[package]] name = "url-normalize" version = "1.4.3" @@ -1605,4 +1733,4 @@ files = [ [metadata] lock-version = "2.0" python-versions = "^3.10,<3.12" -content-hash = "ebea97fabc6fd3b9a36cd0b764ccd6dcaa59a5a6502f35700ef60ebe441c5b57" +content-hash = "daacd34ac4cee205c4a30edd62e149f22926163fefee6218ec4a95c218204b27" diff --git a/airbyte-integrations/connectors/source-declarative-manifest/pyproject.toml b/airbyte-integrations/connectors/source-declarative-manifest/pyproject.toml index 98de6f2a71258..f67870851923c 100644 --- a/airbyte-integrations/connectors/source-declarative-manifest/pyproject.toml +++ b/airbyte-integrations/connectors/source-declarative-manifest/pyproject.toml @@ -3,7 +3,7 @@ requires = ["poetry-core>=1.0.0"] build-backend = "poetry.core.masonry.api" [tool.poetry] -version = "5.2.1" +version = "5.5.2" name = "source-declarative-manifest" description = "Base source implementation for low-code sources." authors = ["Airbyte "] @@ -17,7 +17,7 @@ include = "source_declarative_manifest" [tool.poetry.dependencies] python = "^3.10,<3.12" -airbyte-cdk = "5.2.1" +airbyte-cdk = "5.5.2" [tool.poetry.scripts] source-declarative-manifest = "source_declarative_manifest.run:run" diff --git a/airbyte-integrations/connectors/source-getlago/manifest.yaml b/airbyte-integrations/connectors/source-getlago/manifest.yaml index 0a0d9e2a0d99e..62aea7466d009 100644 --- a/airbyte-integrations/connectors/source-getlago/manifest.yaml +++ b/airbyte-integrations/connectors/source-getlago/manifest.yaml @@ -318,6 +318,17 @@ definitions: $ref: "#/definitions/base_requester" path: /customers/{{stream_slice.customer_external_id}}/current_usage http_method: GET + error_handler: + type: CompositeErrorHandler + error_handlers: + - type: DefaultErrorHandler + response_filters: + - type: HttpResponseFilter + action: IGNORE + predicate: >- + {{response.status == 405 and response.code == + 'no_active_subscription' }} + http_codes: [] record_selector: type: RecordSelector extractor: diff --git a/airbyte-integrations/connectors/source-getlago/metadata.yaml b/airbyte-integrations/connectors/source-getlago/metadata.yaml index 351f684e297ca..1217cb9dcecc1 100644 --- a/airbyte-integrations/connectors/source-getlago/metadata.yaml +++ b/airbyte-integrations/connectors/source-getlago/metadata.yaml @@ -2,7 +2,7 @@ data: connectorSubtype: api connectorType: source definitionId: e1a3866b-d3b2-43b6-b6d7-8c1ee4d7f53f - dockerImageTag: 0.5.0 + dockerImageTag: 0.6.0 dockerRepository: airbyte/source-getlago githubIssueLabel: source-getlago icon: getlago.svg diff --git a/airbyte-integrations/connectors/source-mssql/build.gradle b/airbyte-integrations/connectors/source-mssql/build.gradle index cdd9713e8457d..2a0673148b2be 100644 --- a/airbyte-integrations/connectors/source-mssql/build.gradle +++ b/airbyte-integrations/connectors/source-mssql/build.gradle @@ -3,7 +3,7 @@ plugins { } airbyteJavaConnector { - cdkVersionRequired = '0.44.18' + cdkVersionRequired = '0.44.22' features = ['db-sources'] useLocalCdk = false } diff --git a/airbyte-integrations/connectors/source-mssql/metadata.yaml b/airbyte-integrations/connectors/source-mssql/metadata.yaml index f522f8910824c..05203ea7035ad 100644 --- a/airbyte-integrations/connectors/source-mssql/metadata.yaml +++ b/airbyte-integrations/connectors/source-mssql/metadata.yaml @@ -9,7 +9,7 @@ data: connectorSubtype: database connectorType: source definitionId: b5ea17b1-f170-46dc-bc31-cc744ca984c1 - dockerImageTag: 4.1.11 + dockerImageTag: 4.1.13 dockerRepository: airbyte/source-mssql documentationUrl: https://docs.airbyte.com/integrations/sources/mssql githubIssueLabel: source-mssql diff --git a/airbyte-integrations/connectors/source-mssql/src/main/java/io/airbyte/integrations/source/mssql/initialsync/MssqlInitialLoadGlobalStateManager.java b/airbyte-integrations/connectors/source-mssql/src/main/java/io/airbyte/integrations/source/mssql/initialsync/MssqlInitialLoadGlobalStateManager.java index da55b7b40c566..4fa63c266c6e1 100644 --- a/airbyte-integrations/connectors/source-mssql/src/main/java/io/airbyte/integrations/source/mssql/initialsync/MssqlInitialLoadGlobalStateManager.java +++ b/airbyte-integrations/connectors/source-mssql/src/main/java/io/airbyte/integrations/source/mssql/initialsync/MssqlInitialLoadGlobalStateManager.java @@ -30,6 +30,7 @@ public class MssqlInitialLoadGlobalStateManager extends MssqlInitialLoadStateMan // No special handling for resumable full refresh streams. We will report the cursor as it is. private Set resumableFullRefreshStreams; private Set nonResumableFullRefreshStreams; + private Set completedNonResumableFullRefreshStreams; public MssqlInitialLoadGlobalStateManager(final InitialLoadStreams initialLoadStreams, final Map pairToOrderedColInfo, @@ -61,6 +62,7 @@ private void initStreams(final InitialLoadStreams initialLoadStreams, this.streamsThatHaveCompletedSnapshot = new HashSet<>(); this.resumableFullRefreshStreams = new HashSet<>(); this.nonResumableFullRefreshStreams = new HashSet<>(); + this.completedNonResumableFullRefreshStreams = new HashSet<>(); catalog.getStreams().forEach(configuredAirbyteStream -> { var pairInStream = @@ -70,7 +72,8 @@ private void initStreams(final InitialLoadStreams initialLoadStreams, this.streamsThatHaveCompletedSnapshot.add(pairInStream); } if (configuredAirbyteStream.getSyncMode() == SyncMode.FULL_REFRESH) { - if (initialLoadStreams.streamsForInitialLoad().contains(configuredAirbyteStream)) { + if (configuredAirbyteStream.getStream().getSourceDefinedPrimaryKey() != null + && !configuredAirbyteStream.getStream().getSourceDefinedPrimaryKey().isEmpty()) { this.resumableFullRefreshStreams.add(pairInStream); } else { this.nonResumableFullRefreshStreams.add(pairInStream); @@ -94,6 +97,12 @@ public AirbyteStateMessage generateStateMessageAtCheckpoint(final ConfiguredAirb } }); + completedNonResumableFullRefreshStreams.forEach(stream -> { + streamStates.add(new AirbyteStreamState() + .withStreamDescriptor( + new StreamDescriptor().withName(stream.getName()).withNamespace(stream.getNamespace()))); + }); + if (airbyteStream.getSyncMode() == SyncMode.INCREMENTAL) { AirbyteStreamNameNamespacePair pair = new AirbyteStreamNameNamespacePair(airbyteStream.getStream().getName(), airbyteStream.getStream().getNamespace()); @@ -119,10 +128,13 @@ private AirbyteStreamState getAirbyteStreamState(final AirbyteStreamNameNamespac @Override public AirbyteStateMessage createFinalStateMessage(final ConfiguredAirbyteStream airbyteStream) { + + final io.airbyte.protocol.models.v0.AirbyteStreamNameNamespacePair pair = new io.airbyte.protocol.models.v0.AirbyteStreamNameNamespacePair( + airbyteStream.getStream().getName(), airbyteStream.getStream().getNamespace()); if (airbyteStream.getSyncMode() == SyncMode.INCREMENTAL) { - io.airbyte.protocol.models.v0.AirbyteStreamNameNamespacePair pair = new io.airbyte.protocol.models.v0.AirbyteStreamNameNamespacePair( - airbyteStream.getStream().getName(), airbyteStream.getStream().getNamespace()); streamsThatHaveCompletedSnapshot.add(pair); + } else if (nonResumableFullRefreshStreams.contains(pair)) { + completedNonResumableFullRefreshStreams.add(pair); } final List streamStates = new ArrayList<>(); streamsThatHaveCompletedSnapshot.forEach(stream -> { @@ -135,7 +147,7 @@ public AirbyteStateMessage createFinalStateMessage(final ConfiguredAirbyteStream streamStates.add(getAirbyteStreamState(stream, Jsons.jsonNode(ocStatus))); }); - nonResumableFullRefreshStreams.forEach(stream -> { + completedNonResumableFullRefreshStreams.forEach(stream -> { streamStates.add(new AirbyteStreamState() .withStreamDescriptor( new StreamDescriptor().withName(stream.getName()).withNamespace(stream.getNamespace()))); diff --git a/airbyte-integrations/connectors/source-mysql-v2/metadata.yaml b/airbyte-integrations/connectors/source-mysql-v2/metadata.yaml index 3e62995e4d98e..9fbd0662b4fc5 100644 --- a/airbyte-integrations/connectors/source-mysql-v2/metadata.yaml +++ b/airbyte-integrations/connectors/source-mysql-v2/metadata.yaml @@ -1,7 +1,7 @@ data: ab_internal: ql: 200 - sl: 100 + sl: 0 allowedHosts: hosts: - ${host} @@ -9,7 +9,7 @@ data: connectorSubtype: database connectorType: source definitionId: 561393ed-7e3a-4d0d-8b8b-90ded371754c - dockerImageTag: 0.0.1 + dockerImageTag: 0.0.3 dockerRepository: airbyte/source-mysql-v2 documentationUrl: https://docs.airbyte.com/integrations/sources/mysql githubIssueLabel: source-mysql-v2 @@ -22,7 +22,7 @@ data: oss: enabled: false releaseStage: alpha - supportLevel: archived + supportLevel: community tags: - language:java metadataSpecVersion: "1.0" diff --git a/airbyte-integrations/connectors/source-mysql-v2/src/main/kotlin/io/airbyte/integrations/source/mysql/MysqlSourceConfigurationJsonObject.kt b/airbyte-integrations/connectors/source-mysql-v2/src/main/kotlin/io/airbyte/integrations/source/mysql/MysqlSourceConfigurationJsonObject.kt index 493d0736dd581..f19f04fcb7130 100644 --- a/airbyte-integrations/connectors/source-mysql-v2/src/main/kotlin/io/airbyte/integrations/source/mysql/MysqlSourceConfigurationJsonObject.kt +++ b/airbyte-integrations/connectors/source-mysql-v2/src/main/kotlin/io/airbyte/integrations/source/mysql/MysqlSourceConfigurationJsonObject.kt @@ -277,7 +277,8 @@ class MicronautPropertiesFriendlyEncryption { @JsonTypeInfo(use = JsonTypeInfo.Id.NAME, property = "cursor_method") @JsonSubTypes( JsonSubTypes.Type(value = UserDefinedCursor::class, name = "user_defined"), - // TODO: add CDC support + JsonSubTypes.Type(value = CdcCursor::class, name = "cdc") + // TODO: port over additional Cdc options ) @JsonSchemaTitle("Update Method") @JsonSchemaDescription("Configures how data is extracted from the database.") diff --git a/airbyte-integrations/connectors/source-mysql-v2/src/test/kotlin/io/airbyte/integrations/source/mysql/MysqlSourceDatatypeIntegrationTest.kt b/airbyte-integrations/connectors/source-mysql-v2/src/test/kotlin/io/airbyte/integrations/source/mysql/MysqlSourceDatatypeIntegrationTest.kt index 30a9d520a548f..1cc28d67a4e8c 100644 --- a/airbyte-integrations/connectors/source-mysql-v2/src/test/kotlin/io/airbyte/integrations/source/mysql/MysqlSourceDatatypeIntegrationTest.kt +++ b/airbyte-integrations/connectors/source-mysql-v2/src/test/kotlin/io/airbyte/integrations/source/mysql/MysqlSourceDatatypeIntegrationTest.kt @@ -2,7 +2,7 @@ package io.airbyte.integrations.source.mysql import com.fasterxml.jackson.databind.JsonNode -import io.airbyte.cdk.TestClockFactory +import io.airbyte.cdk.ClockFactory import io.airbyte.cdk.command.CliRunner import io.airbyte.cdk.data.AirbyteType import io.airbyte.cdk.data.LeafAirbyteType @@ -30,7 +30,6 @@ import org.testcontainers.containers.MySQLContainer private val log = KotlinLogging.logger {} -/** Reference: https://docs.mysql.com/en/database/mysql/mysql-database/23/sqlrf/Data-Types.html */ class MysqlSourceDatatypeIntegrationTest { @TestFactory @Timeout(300) @@ -58,7 +57,7 @@ class MysqlSourceDatatypeIntegrationTest { object LazyValues { val actualStreams: Map by lazy { - val output: BufferingOutputConsumer = CliRunner.runSource("discover", config()) + val output: BufferingOutputConsumer = CliRunner.source("discover", config()).run() output.catalogs().firstOrNull()?.streams?.filterNotNull()?.associateBy { it.name } ?: mapOf() } @@ -77,13 +76,13 @@ class MysqlSourceDatatypeIntegrationTest { } val allReadMessages: List by lazy { - CliRunner.runSource("read", config(), configuredCatalog).messages() + CliRunner.source("read", config(), configuredCatalog).run().messages() } val actualReads: Map by lazy { val result: Map = allStreamNamesAndRecordData.keys.associateWith { - BufferingOutputConsumer(TestClockFactory().fixed()) + BufferingOutputConsumer(ClockFactory().fixed()) } for (msg in allReadMessages) { result[streamName(msg) ?: continue]?.accept(msg) diff --git a/airbyte-integrations/connectors/source-mysql-v2/src/test/resources/expected-spec.json b/airbyte-integrations/connectors/source-mysql-v2/src/test/resources/expected-spec.json index f7a871076922c..4e6c6f5e195d7 100644 --- a/airbyte-integrations/connectors/source-mysql-v2/src/test/resources/expected-spec.json +++ b/airbyte-integrations/connectors/source-mysql-v2/src/test/resources/expected-spec.json @@ -44,6 +44,20 @@ }, "description": "Incrementally detects new inserts and updates using the cursor column chosen when configuring a connection (e.g. created_at, updated_at).", "additionalProperties": true + }, + { + "type": "object", + "title": "Read Changes using Change Data Capture (CDC)", + "required": ["cursor_method"], + "properties": { + "cursor_method": { + "enum": ["cdc"], + "type": "string", + "default": "cdc" + } + }, + "description": "Recommended - Incrementally reads new inserts, updates, and deletes using Mysql's change data capture feature. This must be enabled on your database.", + "additionalProperties": true } ], "order": 10, diff --git a/airbyte-integrations/connectors/source-mysql/metadata.yaml b/airbyte-integrations/connectors/source-mysql/metadata.yaml index 11f1a73bdd892..13d8d6a895617 100644 --- a/airbyte-integrations/connectors/source-mysql/metadata.yaml +++ b/airbyte-integrations/connectors/source-mysql/metadata.yaml @@ -9,7 +9,7 @@ data: connectorSubtype: database connectorType: source definitionId: 435bb9a5-7887-4809-aa58-28c27df0d7ad - dockerImageTag: 3.7.1 + dockerImageTag: 3.7.2 dockerRepository: airbyte/source-mysql documentationUrl: https://docs.airbyte.com/integrations/sources/mysql githubIssueLabel: source-mysql diff --git a/airbyte-integrations/connectors/source-mysql/src/main/java/io/airbyte/integrations/source/mysql/initialsync/MySqlInitialLoadGlobalStateManager.java b/airbyte-integrations/connectors/source-mysql/src/main/java/io/airbyte/integrations/source/mysql/initialsync/MySqlInitialLoadGlobalStateManager.java index 5f2fa13144df1..9b3de8d4047e9 100644 --- a/airbyte-integrations/connectors/source-mysql/src/main/java/io/airbyte/integrations/source/mysql/initialsync/MySqlInitialLoadGlobalStateManager.java +++ b/airbyte-integrations/connectors/source-mysql/src/main/java/io/airbyte/integrations/source/mysql/initialsync/MySqlInitialLoadGlobalStateManager.java @@ -27,9 +27,12 @@ import java.util.Map; import java.util.Objects; import java.util.Set; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; public class MySqlInitialLoadGlobalStateManager extends MySqlInitialLoadStateManager { + private static final Logger LOGGER = LoggerFactory.getLogger(MySqlInitialLoadGlobalStateManager.class); protected StateManager stateManager; // Only one global state is emitted, which is fanned out into many entries in the DB by platform. As @@ -42,6 +45,7 @@ public class MySqlInitialLoadGlobalStateManager extends MySqlInitialLoadStateMan // non ResumableFullRefreshStreams do not have any state. We only report count for them. private Set nonResumableFullRefreshStreams; + private Set completedNonResumableFullRefreshStreams; private final boolean savedOffsetStillPresentOnServer; private final ConfiguredAirbyteCatalog catalog; @@ -69,6 +73,7 @@ private void initStreams(final InitialLoadStreams initialLoadStreams, this.streamsThatHaveCompletedSnapshot = new HashSet<>(); this.resumableFullRefreshStreams = new HashSet<>(); this.nonResumableFullRefreshStreams = new HashSet<>(); + this.completedNonResumableFullRefreshStreams = new HashSet<>(); catalog.getStreams().forEach(configuredAirbyteStream -> { var pairInStream = @@ -78,7 +83,8 @@ private void initStreams(final InitialLoadStreams initialLoadStreams, this.streamsThatHaveCompletedSnapshot.add(pairInStream); } if (configuredAirbyteStream.getSyncMode() == SyncMode.FULL_REFRESH) { - if (initialLoadStreams.streamsForInitialLoad().contains(configuredAirbyteStream)) { + if (configuredAirbyteStream.getStream().getSourceDefinedPrimaryKey() != null + && !configuredAirbyteStream.getStream().getSourceDefinedPrimaryKey().isEmpty()) { this.resumableFullRefreshStreams.add(pairInStream); } else { this.nonResumableFullRefreshStreams.add(pairInStream); @@ -115,6 +121,13 @@ public AirbyteStateMessage generateStateMessageAtCheckpoint(final ConfiguredAirb streamStates.add(getAirbyteStreamState(stream, (Jsons.jsonNode(pkStatus)))); } }); + + completedNonResumableFullRefreshStreams.forEach(stream -> { + streamStates.add(new AirbyteStreamState() + .withStreamDescriptor( + new StreamDescriptor().withName(stream.getName()).withNamespace(stream.getNamespace()))); + }); + if (airbyteStream.getSyncMode() == SyncMode.INCREMENTAL) { AirbyteStreamNameNamespacePair pair = new AirbyteStreamNameNamespacePair(airbyteStream.getStream().getName(), airbyteStream.getStream().getNamespace()); @@ -129,10 +142,12 @@ public AirbyteStateMessage generateStateMessageAtCheckpoint(final ConfiguredAirb @Override public AirbyteStateMessage createFinalStateMessage(final ConfiguredAirbyteStream airbyteStream) { + final AirbyteStreamNameNamespacePair pair = + new AirbyteStreamNameNamespacePair(airbyteStream.getStream().getName(), airbyteStream.getStream().getNamespace()); if (airbyteStream.getSyncMode() == SyncMode.INCREMENTAL) { - AirbyteStreamNameNamespacePair pair = - new AirbyteStreamNameNamespacePair(airbyteStream.getStream().getName(), airbyteStream.getStream().getNamespace()); streamsThatHaveCompletedSnapshot.add(pair); + } else if (nonResumableFullRefreshStreams.contains(pair)) { + completedNonResumableFullRefreshStreams.add(pair); } final List streamStates = new ArrayList<>(); @@ -146,7 +161,7 @@ public AirbyteStateMessage createFinalStateMessage(final ConfiguredAirbyteStream streamStates.add(getAirbyteStreamState(stream, (Jsons.jsonNode(pkStatus)))); }); - nonResumableFullRefreshStreams.forEach(stream -> { + completedNonResumableFullRefreshStreams.forEach(stream -> { streamStates.add(new AirbyteStreamState() .withStreamDescriptor( new StreamDescriptor().withName(stream.getName()).withNamespace(stream.getNamespace()))); diff --git a/airbyte-integrations/connectors/source-sendgrid/metadata.yaml b/airbyte-integrations/connectors/source-sendgrid/metadata.yaml index 5baac4db52b7c..3b0beebad3e8c 100644 --- a/airbyte-integrations/connectors/source-sendgrid/metadata.yaml +++ b/airbyte-integrations/connectors/source-sendgrid/metadata.yaml @@ -10,7 +10,7 @@ data: connectorSubtype: api connectorType: source definitionId: fbb5fbe2-16ad-4cf4-af7d-ff9d9c316c87 - dockerImageTag: 1.0.18 + dockerImageTag: 1.1.0 releases: breakingChanges: 1.0.0: diff --git a/airbyte-integrations/connectors/source-sendgrid/poetry.lock b/airbyte-integrations/connectors/source-sendgrid/poetry.lock index 09d71f58597e0..7942f0a456aa1 100644 --- a/airbyte-integrations/connectors/source-sendgrid/poetry.lock +++ b/airbyte-integrations/connectors/source-sendgrid/poetry.lock @@ -1,31 +1,33 @@ -# This file is automatically @generated by Poetry 1.6.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 1.8.2 and should not be changed by hand. [[package]] name = "airbyte-cdk" -version = "0.90.0" +version = "5.5.0" description = "A framework for writing Airbyte Connectors." optional = false -python-versions = "<4.0,>=3.9" +python-versions = "<4.0,>=3.10" files = [ - {file = "airbyte_cdk-0.90.0-py3-none-any.whl", hash = "sha256:bd0aa5843cdc4901f2e482f0e86695ca4e6db83b65c5017799255dd20535cf56"}, - {file = "airbyte_cdk-0.90.0.tar.gz", hash = "sha256:25cefc010718bada5cce3f87e7ae93068630732c0d34ce5145f8ddf7457d4d3c"}, + {file = "airbyte_cdk-5.5.0-py3-none-any.whl", hash = "sha256:bceaf20c40c9cc63337d2aee94d4d45938e606846df305d7b1910429a8d5024f"}, + {file = "airbyte_cdk-5.5.0.tar.gz", hash = "sha256:a44dc9d7e09ae25f1fb3353bab44e5de86cc4241a5cb5001ea1b8880ce267af3"}, ] [package.dependencies] -airbyte-protocol-models = ">=0.9.0,<1.0" +airbyte-protocol-models-dataclasses = ">=0.13,<0.14" backoff = "*" cachetools = "*" cryptography = ">=42.0.5,<43.0.0" Deprecated = ">=1.2,<1.3" -dpath = ">=2.0.1,<2.1.0" +dpath = ">=2.1.6,<3.0.0" genson = "1.2.2" isodate = ">=0.6.1,<0.7.0" Jinja2 = ">=3.1.2,<3.2.0" jsonref = ">=0.2,<0.3" jsonschema = ">=3.2.0,<3.3.0" langchain_core = "0.1.42" +nltk = "3.8.1" +orjson = ">=3.10.7,<4.0.0" pendulum = "<3.0.0" -pydantic = ">=1.10.8,<2.0.0" +pydantic = ">=2.7,<3.0" pyjwt = ">=2.8.0,<3.0.0" pyrate-limiter = ">=3.1.0,<3.2.0" python-dateutil = "*" @@ -33,26 +35,35 @@ pytz = "2024.1" PyYAML = ">=6.0.1,<7.0.0" requests = "*" requests_cache = "*" +serpyco-rs = ">=1.10.2,<2.0.0" wcmatch = "8.4" [package.extras] -file-based = ["avro (>=1.11.2,<1.12.0)", "fastavro (>=1.8.0,<1.9.0)", "markdown", "pdf2image (==1.16.3)", "pdfminer.six (==20221105)", "pyarrow (>=15.0.0,<15.1.0)", "pytesseract (==0.3.10)", "unstructured.pytesseract (>=0.3.12)", "unstructured[docx,pptx] (==0.10.27)"] +file-based = ["avro (>=1.11.2,<1.12.0)", "fastavro (>=1.8.0,<1.9.0)", "markdown", "pandas (==2.2.0)", "pdf2image (==1.16.3)", "pdfminer.six (==20221105)", "pyarrow (>=15.0.0,<15.1.0)", "pytesseract (==0.3.10)", "python-calamine (==0.2.3)", "unstructured.pytesseract (>=0.3.12)", "unstructured[docx,pptx] (==0.10.27)"] sphinx-docs = ["Sphinx (>=4.2,<4.3)", "sphinx-rtd-theme (>=1.0,<1.1)"] vector-db-based = ["cohere (==4.21)", "langchain (==0.1.16)", "openai[embeddings] (==0.27.9)", "tiktoken (==0.4.0)"] [[package]] -name = "airbyte-protocol-models" +name = "airbyte-protocol-models-dataclasses" version = "0.13.0" -description = "Declares the Airbyte Protocol." +description = "Declares the Airbyte Protocol using Python Dataclasses. Dataclasses in Python have less performance overhead compared to Pydantic models, making them a more efficient choice for scenarios where speed and memory usage are critical" optional = false python-versions = ">=3.8" files = [ - {file = "airbyte_protocol_models-0.13.0-py3-none-any.whl", hash = "sha256:fa8b7e1a85f9ae171c50b30d23b317da1740d051994fd3ed648f9dfba00250e2"}, - {file = "airbyte_protocol_models-0.13.0.tar.gz", hash = "sha256:09d8900ba8674a9315fa1799d17026f6b38d2187c08160449540ee93331ed2e7"}, + {file = "airbyte_protocol_models_dataclasses-0.13.0-py3-none-any.whl", hash = "sha256:0aedb99ffc4f9aab0ce91bba2c292fa17cd8fd4b42eeba196d6a16c20bbbd7a5"}, + {file = "airbyte_protocol_models_dataclasses-0.13.0.tar.gz", hash = "sha256:72e67850d661e2808406aec5839b3158ebb94d3553b798dbdae1b4a278548d2f"}, ] -[package.dependencies] -pydantic = ">=1.9.2,<2.0.0" +[[package]] +name = "annotated-types" +version = "0.7.0" +description = "Reusable constraint types to use with typing.Annotated" +optional = false +python-versions = ">=3.8" +files = [ + {file = "annotated_types-0.7.0-py3-none-any.whl", hash = "sha256:1f02e8b43a8fbbc3f3e0d4f0f4bfc8131bcb4eebe8849b8e5c773f3a1c582a53"}, + {file = "annotated_types-0.7.0.tar.gz", hash = "sha256:aff07c09a53a08bc8cfccb9c85b05f1aa9a2a6f23728d790723543408344ce89"}, +] [[package]] name = "anyio" @@ -86,6 +97,17 @@ files = [ {file = "atomicwrites-1.4.1.tar.gz", hash = "sha256:81b2c9071a49367a7f770170e5eec8cb66567cfbbc8c73d20ce5ca4a8d71cf11"}, ] +[[package]] +name = "attributes-doc" +version = "0.4.0" +description = "PEP 224 implementation" +optional = false +python-versions = ">=3.8" +files = [ + {file = "attributes-doc-0.4.0.tar.gz", hash = "sha256:b1576c94a714e9fc2c65c47cf10d0c8e1a5f7c4f5ae7f69006be108d95cbfbfb"}, + {file = "attributes_doc-0.4.0-py2.py3-none-any.whl", hash = "sha256:4c3007d9e58f3a6cb4b9c614c4d4ce2d92161581f28e594ddd8241cc3a113bdd"}, +] + [[package]] name = "attrs" version = "24.2.0" @@ -353,6 +375,20 @@ files = [ {file = "charset_normalizer-3.3.2-py3-none-any.whl", hash = "sha256:3e4d1f6587322d2788836a99c69062fbb091331ec940e02d12d179c1d53e25fc"}, ] +[[package]] +name = "click" +version = "8.1.7" +description = "Composable command line interface toolkit" +optional = false +python-versions = ">=3.7" +files = [ + {file = "click-8.1.7-py3-none-any.whl", hash = "sha256:ae74fb96c20a0277a1d615f1e4d73c8414f5a98db8b799a7931d1582f3390c28"}, + {file = "click-8.1.7.tar.gz", hash = "sha256:ca9853ad459e787e2192211578cc907e7594e294c7ccc834310722b41b9ca6de"}, +] + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + [[package]] name = "colorama" version = "0.4.6" @@ -437,13 +473,13 @@ dev = ["PyTest", "PyTest-Cov", "bump2version (<1)", "sphinx (<2)", "tox"] [[package]] name = "dpath" -version = "2.0.8" +version = "2.2.0" description = "Filesystem-like pathing and searching for dictionaries" optional = false python-versions = ">=3.7" files = [ - {file = "dpath-2.0.8-py3-none-any.whl", hash = "sha256:f92f595214dd93a00558d75d4b858beee519f4cffca87f02616ad6cd013f3436"}, - {file = "dpath-2.0.8.tar.gz", hash = "sha256:a3440157ebe80d0a3ad794f1b61c571bef125214800ffdb9afc9424e8250fe9b"}, + {file = "dpath-2.2.0-py3-none-any.whl", hash = "sha256:b330a375ded0a0d2ed404440f6c6a715deae5313af40bbb01c8a41d891900576"}, + {file = "dpath-2.2.0.tar.gz", hash = "sha256:34f7e630dc55ea3f219e555726f5da4b4b25f2200319c8e6902c394258dd6a3e"}, ] [[package]] @@ -580,6 +616,17 @@ MarkupSafe = ">=2.0" [package.extras] i18n = ["Babel (>=2.7)"] +[[package]] +name = "joblib" +version = "1.4.2" +description = "Lightweight pipelining with Python functions" +optional = false +python-versions = ">=3.8" +files = [ + {file = "joblib-1.4.2-py3-none-any.whl", hash = "sha256:06d478d5674cbc267e7496a410ee875abd68e4340feff4490bcb7afb88060ae6"}, + {file = "joblib-1.4.2.tar.gz", hash = "sha256:2382c5816b2636fbd20a09e0f4e9dad4736765fdfb7dca582943b9c1366b3f0e"}, +] + [[package]] name = "jsonpatch" version = "1.33" @@ -661,13 +708,13 @@ extended-testing = ["jinja2 (>=3,<4)"] [[package]] name = "langsmith" -version = "0.1.116" +version = "0.1.117" description = "Client library to connect to the LangSmith LLM Tracing and Evaluation Platform." optional = false python-versions = "<4.0,>=3.8.1" files = [ - {file = "langsmith-0.1.116-py3-none-any.whl", hash = "sha256:4b5ea64c81ba5ca309695c85dc3fb4617429a985129ed5d9eca00d1c9d6483f4"}, - {file = "langsmith-0.1.116.tar.gz", hash = "sha256:5ccd7f5c1840f7c507ab3ee56334a1391de28c8bf72669782e2d82cafeefffa7"}, + {file = "langsmith-0.1.117-py3-none-any.whl", hash = "sha256:e936ee9bcf8293b0496df7ba462a3702179fbe51f9dc28744b0fbec0dbf206ae"}, + {file = "langsmith-0.1.117.tar.gz", hash = "sha256:a1b532f49968b9339bcaff9118d141846d52ed3d803f342902e7448edf1d662b"}, ] [package.dependencies] @@ -746,59 +793,30 @@ files = [ ] [[package]] -name = "numpy" -version = "2.0.2" -description = "Fundamental package for array computing in Python" +name = "nltk" +version = "3.8.1" +description = "Natural Language Toolkit" optional = false -python-versions = ">=3.9" +python-versions = ">=3.7" files = [ - {file = "numpy-2.0.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:51129a29dbe56f9ca83438b706e2e69a39892b5eda6cedcb6b0c9fdc9b0d3ece"}, - {file = "numpy-2.0.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:f15975dfec0cf2239224d80e32c3170b1d168335eaedee69da84fbe9f1f9cd04"}, - {file = "numpy-2.0.2-cp310-cp310-macosx_14_0_arm64.whl", hash = "sha256:8c5713284ce4e282544c68d1c3b2c7161d38c256d2eefc93c1d683cf47683e66"}, - {file = "numpy-2.0.2-cp310-cp310-macosx_14_0_x86_64.whl", hash = "sha256:becfae3ddd30736fe1889a37f1f580e245ba79a5855bff5f2a29cb3ccc22dd7b"}, - {file = "numpy-2.0.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2da5960c3cf0df7eafefd806d4e612c5e19358de82cb3c343631188991566ccd"}, - {file = "numpy-2.0.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:496f71341824ed9f3d2fd36cf3ac57ae2e0165c143b55c3a035ee219413f3318"}, - {file = "numpy-2.0.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:a61ec659f68ae254e4d237816e33171497e978140353c0c2038d46e63282d0c8"}, - {file = "numpy-2.0.2-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:d731a1c6116ba289c1e9ee714b08a8ff882944d4ad631fd411106a30f083c326"}, - {file = "numpy-2.0.2-cp310-cp310-win32.whl", hash = "sha256:984d96121c9f9616cd33fbd0618b7f08e0cfc9600a7ee1d6fd9b239186d19d97"}, - {file = "numpy-2.0.2-cp310-cp310-win_amd64.whl", hash = "sha256:c7b0be4ef08607dd04da4092faee0b86607f111d5ae68036f16cc787e250a131"}, - {file = "numpy-2.0.2-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:49ca4decb342d66018b01932139c0961a8f9ddc7589611158cb3c27cbcf76448"}, - {file = "numpy-2.0.2-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:11a76c372d1d37437857280aa142086476136a8c0f373b2e648ab2c8f18fb195"}, - {file = "numpy-2.0.2-cp311-cp311-macosx_14_0_arm64.whl", hash = "sha256:807ec44583fd708a21d4a11d94aedf2f4f3c3719035c76a2bbe1fe8e217bdc57"}, - {file = "numpy-2.0.2-cp311-cp311-macosx_14_0_x86_64.whl", hash = "sha256:8cafab480740e22f8d833acefed5cc87ce276f4ece12fdaa2e8903db2f82897a"}, - {file = "numpy-2.0.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a15f476a45e6e5a3a79d8a14e62161d27ad897381fecfa4a09ed5322f2085669"}, - {file = "numpy-2.0.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:13e689d772146140a252c3a28501da66dfecd77490b498b168b501835041f951"}, - {file = "numpy-2.0.2-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:9ea91dfb7c3d1c56a0e55657c0afb38cf1eeae4544c208dc465c3c9f3a7c09f9"}, - {file = "numpy-2.0.2-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:c1c9307701fec8f3f7a1e6711f9089c06e6284b3afbbcd259f7791282d660a15"}, - {file = "numpy-2.0.2-cp311-cp311-win32.whl", hash = "sha256:a392a68bd329eafac5817e5aefeb39038c48b671afd242710b451e76090e81f4"}, - {file = "numpy-2.0.2-cp311-cp311-win_amd64.whl", hash = "sha256:286cd40ce2b7d652a6f22efdfc6d1edf879440e53e76a75955bc0c826c7e64dc"}, - {file = "numpy-2.0.2-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:df55d490dea7934f330006d0f81e8551ba6010a5bf035a249ef61a94f21c500b"}, - {file = "numpy-2.0.2-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:8df823f570d9adf0978347d1f926b2a867d5608f434a7cff7f7908c6570dcf5e"}, - {file = "numpy-2.0.2-cp312-cp312-macosx_14_0_arm64.whl", hash = "sha256:9a92ae5c14811e390f3767053ff54eaee3bf84576d99a2456391401323f4ec2c"}, - {file = "numpy-2.0.2-cp312-cp312-macosx_14_0_x86_64.whl", hash = "sha256:a842d573724391493a97a62ebbb8e731f8a5dcc5d285dfc99141ca15a3302d0c"}, - {file = "numpy-2.0.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c05e238064fc0610c840d1cf6a13bf63d7e391717d247f1bf0318172e759e692"}, - {file = "numpy-2.0.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0123ffdaa88fa4ab64835dcbde75dcdf89c453c922f18dced6e27c90d1d0ec5a"}, - {file = "numpy-2.0.2-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:96a55f64139912d61de9137f11bf39a55ec8faec288c75a54f93dfd39f7eb40c"}, - {file = "numpy-2.0.2-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:ec9852fb39354b5a45a80bdab5ac02dd02b15f44b3804e9f00c556bf24b4bded"}, - {file = "numpy-2.0.2-cp312-cp312-win32.whl", hash = "sha256:671bec6496f83202ed2d3c8fdc486a8fc86942f2e69ff0e986140339a63bcbe5"}, - {file = "numpy-2.0.2-cp312-cp312-win_amd64.whl", hash = "sha256:cfd41e13fdc257aa5778496b8caa5e856dc4896d4ccf01841daee1d96465467a"}, - {file = "numpy-2.0.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:9059e10581ce4093f735ed23f3b9d283b9d517ff46009ddd485f1747eb22653c"}, - {file = "numpy-2.0.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:423e89b23490805d2a5a96fe40ec507407b8ee786d66f7328be214f9679df6dd"}, - {file = "numpy-2.0.2-cp39-cp39-macosx_14_0_arm64.whl", hash = "sha256:2b2955fa6f11907cf7a70dab0d0755159bca87755e831e47932367fc8f2f2d0b"}, - {file = "numpy-2.0.2-cp39-cp39-macosx_14_0_x86_64.whl", hash = "sha256:97032a27bd9d8988b9a97a8c4d2c9f2c15a81f61e2f21404d7e8ef00cb5be729"}, - {file = "numpy-2.0.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e795a8be3ddbac43274f18588329c72939870a16cae810c2b73461c40718ab1"}, - {file = "numpy-2.0.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f26b258c385842546006213344c50655ff1555a9338e2e5e02a0756dc3e803dd"}, - {file = "numpy-2.0.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:5fec9451a7789926bcf7c2b8d187292c9f93ea30284802a0ab3f5be8ab36865d"}, - {file = "numpy-2.0.2-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:9189427407d88ff25ecf8f12469d4d39d35bee1db5d39fc5c168c6f088a6956d"}, - {file = "numpy-2.0.2-cp39-cp39-win32.whl", hash = "sha256:905d16e0c60200656500c95b6b8dca5d109e23cb24abc701d41c02d74c6b3afa"}, - {file = "numpy-2.0.2-cp39-cp39-win_amd64.whl", hash = "sha256:a3f4ab0caa7f053f6797fcd4e1e25caee367db3112ef2b6ef82d749530768c73"}, - {file = "numpy-2.0.2-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:7f0a0c6f12e07fa94133c8a67404322845220c06a9e80e85999afe727f7438b8"}, - {file = "numpy-2.0.2-pp39-pypy39_pp73-macosx_14_0_x86_64.whl", hash = "sha256:312950fdd060354350ed123c0e25a71327d3711584beaef30cdaa93320c392d4"}, - {file = "numpy-2.0.2-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:26df23238872200f63518dd2aa984cfca675d82469535dc7162dc2ee52d9dd5c"}, - {file = "numpy-2.0.2-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:a46288ec55ebbd58947d31d72be2c63cbf839f0a63b49cb755022310792a3385"}, - {file = "numpy-2.0.2.tar.gz", hash = "sha256:883c987dee1880e2a864ab0dc9892292582510604156762362d9326444636e78"}, + {file = "nltk-3.8.1-py3-none-any.whl", hash = "sha256:fd5c9109f976fa86bcadba8f91e47f5e9293bd034474752e92a520f81c93dda5"}, + {file = "nltk-3.8.1.zip", hash = "sha256:1834da3d0682cba4f2cede2f9aad6b0fafb6461ba451db0efb6f9c39798d64d3"}, ] +[package.dependencies] +click = "*" +joblib = "*" +regex = ">=2021.8.3" +tqdm = "*" + +[package.extras] +all = ["matplotlib", "numpy", "pyparsing", "python-crfsuite", "requests", "scikit-learn", "scipy", "twython"] +corenlp = ["requests"] +machine-learning = ["numpy", "python-crfsuite", "scikit-learn", "scipy"] +plot = ["matplotlib"] +tgrep = ["pyparsing"] +twitter = ["twython"] + [[package]] name = "numpy" version = "2.1.1" @@ -1046,19 +1064,19 @@ pytzdata = ">=2020.1" [[package]] name = "platformdirs" -version = "4.2.2" +version = "4.3.2" description = "A small Python package for determining appropriate platform-specific dirs, e.g. a `user data dir`." optional = false python-versions = ">=3.8" files = [ - {file = "platformdirs-4.2.2-py3-none-any.whl", hash = "sha256:2d7a1657e36a80ea911db832a8a6ece5ee53d8de21edd5cc5879af6530b1bfee"}, - {file = "platformdirs-4.2.2.tar.gz", hash = "sha256:38b7b51f512eed9e84a22788b4bce1de17c0adb134d6becb09836e37d8654cd3"}, + {file = "platformdirs-4.3.2-py3-none-any.whl", hash = "sha256:eb1c8582560b34ed4ba105009a4badf7f6f85768b30126f351328507b2beb617"}, + {file = "platformdirs-4.3.2.tar.gz", hash = "sha256:9e5e27a08aa095dd127b9f2e764d74254f482fef22b0970773bfba79d091ab8c"}, ] [package.extras] -docs = ["furo (>=2023.9.10)", "proselint (>=0.13)", "sphinx (>=7.2.6)", "sphinx-autodoc-typehints (>=1.25.2)"] -test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=7.4.3)", "pytest-cov (>=4.1)", "pytest-mock (>=3.12)"] -type = ["mypy (>=1.8)"] +docs = ["furo (>=2024.8.6)", "proselint (>=0.14)", "sphinx (>=8.0.2)", "sphinx-autodoc-typehints (>=2.4)"] +test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=8.3.2)", "pytest-cov (>=5)", "pytest-mock (>=3.14)"] +type = ["mypy (>=1.11.2)"] [[package]] name = "pluggy" @@ -1099,62 +1117,124 @@ files = [ [[package]] name = "pydantic" -version = "1.10.18" -description = "Data validation and settings management using python type hints" +version = "2.9.1" +description = "Data validation using Python type hints" optional = false -python-versions = ">=3.7" +python-versions = ">=3.8" files = [ - {file = "pydantic-1.10.18-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:e405ffcc1254d76bb0e760db101ee8916b620893e6edfbfee563b3c6f7a67c02"}, - {file = "pydantic-1.10.18-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e306e280ebebc65040034bff1a0a81fd86b2f4f05daac0131f29541cafd80b80"}, - {file = "pydantic-1.10.18-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:11d9d9b87b50338b1b7de4ebf34fd29fdb0d219dc07ade29effc74d3d2609c62"}, - {file = "pydantic-1.10.18-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b661ce52c7b5e5f600c0c3c5839e71918346af2ef20062705ae76b5c16914cab"}, - {file = "pydantic-1.10.18-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:c20f682defc9ef81cd7eaa485879ab29a86a0ba58acf669a78ed868e72bb89e0"}, - {file = "pydantic-1.10.18-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c5ae6b7c8483b1e0bf59e5f1843e4fd8fd405e11df7de217ee65b98eb5462861"}, - {file = "pydantic-1.10.18-cp310-cp310-win_amd64.whl", hash = "sha256:74fe19dda960b193b0eb82c1f4d2c8e5e26918d9cda858cbf3f41dd28549cb70"}, - {file = "pydantic-1.10.18-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:72fa46abace0a7743cc697dbb830a41ee84c9db8456e8d77a46d79b537efd7ec"}, - {file = "pydantic-1.10.18-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:ef0fe7ad7cbdb5f372463d42e6ed4ca9c443a52ce544472d8842a0576d830da5"}, - {file = "pydantic-1.10.18-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a00e63104346145389b8e8f500bc6a241e729feaf0559b88b8aa513dd2065481"}, - {file = "pydantic-1.10.18-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:ae6fa2008e1443c46b7b3a5eb03800121868d5ab6bc7cda20b5df3e133cde8b3"}, - {file = "pydantic-1.10.18-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:9f463abafdc92635da4b38807f5b9972276be7c8c5121989768549fceb8d2588"}, - {file = "pydantic-1.10.18-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:3445426da503c7e40baccefb2b2989a0c5ce6b163679dd75f55493b460f05a8f"}, - {file = "pydantic-1.10.18-cp311-cp311-win_amd64.whl", hash = "sha256:467a14ee2183bc9c902579bb2f04c3d3dac00eff52e252850509a562255b2a33"}, - {file = "pydantic-1.10.18-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:efbc8a7f9cb5fe26122acba1852d8dcd1e125e723727c59dcd244da7bdaa54f2"}, - {file = "pydantic-1.10.18-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:24a4a159d0f7a8e26bf6463b0d3d60871d6a52eac5bb6a07a7df85c806f4c048"}, - {file = "pydantic-1.10.18-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b74be007703547dc52e3c37344d130a7bfacca7df112a9e5ceeb840a9ce195c7"}, - {file = "pydantic-1.10.18-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:fcb20d4cb355195c75000a49bb4a31d75e4295200df620f454bbc6bdf60ca890"}, - {file = "pydantic-1.10.18-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:46f379b8cb8a3585e3f61bf9ae7d606c70d133943f339d38b76e041ec234953f"}, - {file = "pydantic-1.10.18-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:cbfbca662ed3729204090c4d09ee4beeecc1a7ecba5a159a94b5a4eb24e3759a"}, - {file = "pydantic-1.10.18-cp312-cp312-win_amd64.whl", hash = "sha256:c6d0a9f9eccaf7f438671a64acf654ef0d045466e63f9f68a579e2383b63f357"}, - {file = "pydantic-1.10.18-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:3d5492dbf953d7d849751917e3b2433fb26010d977aa7a0765c37425a4026ff1"}, - {file = "pydantic-1.10.18-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fe734914977eed33033b70bfc097e1baaffb589517863955430bf2e0846ac30f"}, - {file = "pydantic-1.10.18-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:15fdbe568beaca9aacfccd5ceadfb5f1a235087a127e8af5e48df9d8a45ae85c"}, - {file = "pydantic-1.10.18-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:c3e742f62198c9eb9201781fbebe64533a3bbf6a76a91b8d438d62b813079dbc"}, - {file = "pydantic-1.10.18-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:19a3bd00b9dafc2cd7250d94d5b578edf7a0bd7daf102617153ff9a8fa37871c"}, - {file = "pydantic-1.10.18-cp37-cp37m-win_amd64.whl", hash = "sha256:2ce3fcf75b2bae99aa31bd4968de0474ebe8c8258a0110903478bd83dfee4e3b"}, - {file = "pydantic-1.10.18-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:335a32d72c51a313b33fa3a9b0fe283503272ef6467910338e123f90925f0f03"}, - {file = "pydantic-1.10.18-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:34a3613c7edb8c6fa578e58e9abe3c0f5e7430e0fc34a65a415a1683b9c32d9a"}, - {file = "pydantic-1.10.18-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e9ee4e6ca1d9616797fa2e9c0bfb8815912c7d67aca96f77428e316741082a1b"}, - {file = "pydantic-1.10.18-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:23e8ec1ce4e57b4f441fc91e3c12adba023fedd06868445a5b5f1d48f0ab3682"}, - {file = "pydantic-1.10.18-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:44ae8a3e35a54d2e8fa88ed65e1b08967a9ef8c320819a969bfa09ce5528fafe"}, - {file = "pydantic-1.10.18-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:d5389eb3b48a72da28c6e061a247ab224381435256eb541e175798483368fdd3"}, - {file = "pydantic-1.10.18-cp38-cp38-win_amd64.whl", hash = "sha256:069b9c9fc645474d5ea3653788b544a9e0ccd3dca3ad8c900c4c6eac844b4620"}, - {file = "pydantic-1.10.18-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:80b982d42515632eb51f60fa1d217dfe0729f008e81a82d1544cc392e0a50ddf"}, - {file = "pydantic-1.10.18-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:aad8771ec8dbf9139b01b56f66386537c6fe4e76c8f7a47c10261b69ad25c2c9"}, - {file = "pydantic-1.10.18-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:941a2eb0a1509bd7f31e355912eb33b698eb0051730b2eaf9e70e2e1589cae1d"}, - {file = "pydantic-1.10.18-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:65f7361a09b07915a98efd17fdec23103307a54db2000bb92095457ca758d485"}, - {file = "pydantic-1.10.18-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:6951f3f47cb5ca4da536ab161ac0163cab31417d20c54c6de5ddcab8bc813c3f"}, - {file = "pydantic-1.10.18-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:7a4c5eec138a9b52c67f664c7d51d4c7234c5ad65dd8aacd919fb47445a62c86"}, - {file = "pydantic-1.10.18-cp39-cp39-win_amd64.whl", hash = "sha256:49e26c51ca854286bffc22b69787a8d4063a62bf7d83dc21d44d2ff426108518"}, - {file = "pydantic-1.10.18-py3-none-any.whl", hash = "sha256:06a189b81ffc52746ec9c8c007f16e5167c8b0a696e1a726369327e3db7b2a82"}, - {file = "pydantic-1.10.18.tar.gz", hash = "sha256:baebdff1907d1d96a139c25136a9bb7d17e118f133a76a2ef3b845e831e3403a"}, + {file = "pydantic-2.9.1-py3-none-any.whl", hash = "sha256:7aff4db5fdf3cf573d4b3c30926a510a10e19a0774d38fc4967f78beb6deb612"}, + {file = "pydantic-2.9.1.tar.gz", hash = "sha256:1363c7d975c7036df0db2b4a61f2e062fbc0aa5ab5f2772e0ffc7191a4f4bce2"}, ] [package.dependencies] -typing-extensions = ">=4.2.0" +annotated-types = ">=0.6.0" +pydantic-core = "2.23.3" +typing-extensions = {version = ">=4.6.1", markers = "python_version < \"3.13\""} [package.extras] -dotenv = ["python-dotenv (>=0.10.4)"] -email = ["email-validator (>=1.0.3)"] +email = ["email-validator (>=2.0.0)"] +timezone = ["tzdata"] + +[[package]] +name = "pydantic-core" +version = "2.23.3" +description = "Core functionality for Pydantic validation and serialization" +optional = false +python-versions = ">=3.8" +files = [ + {file = "pydantic_core-2.23.3-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:7f10a5d1b9281392f1bf507d16ac720e78285dfd635b05737c3911637601bae6"}, + {file = "pydantic_core-2.23.3-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:3c09a7885dd33ee8c65266e5aa7fb7e2f23d49d8043f089989726391dd7350c5"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6470b5a1ec4d1c2e9afe928c6cb37eb33381cab99292a708b8cb9aa89e62429b"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:9172d2088e27d9a185ea0a6c8cebe227a9139fd90295221d7d495944d2367700"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:86fc6c762ca7ac8fbbdff80d61b2c59fb6b7d144aa46e2d54d9e1b7b0e780e01"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f0cb80fd5c2df4898693aa841425ea1727b1b6d2167448253077d2a49003e0ed"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:03667cec5daf43ac4995cefa8aaf58f99de036204a37b889c24a80927b629cec"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:047531242f8e9c2db733599f1c612925de095e93c9cc0e599e96cf536aaf56ba"}, + {file = "pydantic_core-2.23.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:5499798317fff7f25dbef9347f4451b91ac2a4330c6669821c8202fd354c7bee"}, + {file = "pydantic_core-2.23.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:bbb5e45eab7624440516ee3722a3044b83fff4c0372efe183fd6ba678ff681fe"}, + {file = "pydantic_core-2.23.3-cp310-none-win32.whl", hash = "sha256:8b5b3ed73abb147704a6e9f556d8c5cb078f8c095be4588e669d315e0d11893b"}, + {file = "pydantic_core-2.23.3-cp310-none-win_amd64.whl", hash = "sha256:2b603cde285322758a0279995b5796d64b63060bfbe214b50a3ca23b5cee3e83"}, + {file = "pydantic_core-2.23.3-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:c889fd87e1f1bbeb877c2ee56b63bb297de4636661cc9bbfcf4b34e5e925bc27"}, + {file = "pydantic_core-2.23.3-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:ea85bda3189fb27503af4c45273735bcde3dd31c1ab17d11f37b04877859ef45"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a7f7f72f721223f33d3dc98a791666ebc6a91fa023ce63733709f4894a7dc611"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:2b2b55b0448e9da68f56b696f313949cda1039e8ec7b5d294285335b53104b61"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c24574c7e92e2c56379706b9a3f07c1e0c7f2f87a41b6ee86653100c4ce343e5"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f2b05e6ccbee333a8f4b8f4d7c244fdb7a979e90977ad9c51ea31261e2085ce0"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2c409ce1c219c091e47cb03feb3c4ed8c2b8e004efc940da0166aaee8f9d6c8"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:d965e8b325f443ed3196db890d85dfebbb09f7384486a77461347f4adb1fa7f8"}, + {file = "pydantic_core-2.23.3-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:f56af3a420fb1ffaf43ece3ea09c2d27c444e7c40dcb7c6e7cf57aae764f2b48"}, + {file = "pydantic_core-2.23.3-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:5b01a078dd4f9a52494370af21aa52964e0a96d4862ac64ff7cea06e0f12d2c5"}, + {file = "pydantic_core-2.23.3-cp311-none-win32.whl", hash = "sha256:560e32f0df04ac69b3dd818f71339983f6d1f70eb99d4d1f8e9705fb6c34a5c1"}, + {file = "pydantic_core-2.23.3-cp311-none-win_amd64.whl", hash = "sha256:c744fa100fdea0d000d8bcddee95213d2de2e95b9c12be083370b2072333a0fa"}, + {file = "pydantic_core-2.23.3-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:e0ec50663feedf64d21bad0809f5857bac1ce91deded203efc4a84b31b2e4305"}, + {file = "pydantic_core-2.23.3-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:db6e6afcb95edbe6b357786684b71008499836e91f2a4a1e55b840955b341dbb"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:98ccd69edcf49f0875d86942f4418a4e83eb3047f20eb897bffa62a5d419c8fa"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:a678c1ac5c5ec5685af0133262103defb427114e62eafeda12f1357a12140162"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:01491d8b4d8db9f3391d93b0df60701e644ff0894352947f31fff3e52bd5c801"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:fcf31facf2796a2d3b7fe338fe8640aa0166e4e55b4cb108dbfd1058049bf4cb"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7200fd561fb3be06827340da066df4311d0b6b8eb0c2116a110be5245dceb326"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:dc1636770a809dee2bd44dd74b89cc80eb41172bcad8af75dd0bc182c2666d4c"}, + {file = "pydantic_core-2.23.3-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:67a5def279309f2e23014b608c4150b0c2d323bd7bccd27ff07b001c12c2415c"}, + {file = "pydantic_core-2.23.3-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:748bdf985014c6dd3e1e4cc3db90f1c3ecc7246ff5a3cd4ddab20c768b2f1dab"}, + {file = "pydantic_core-2.23.3-cp312-none-win32.whl", hash = "sha256:255ec6dcb899c115f1e2a64bc9ebc24cc0e3ab097775755244f77360d1f3c06c"}, + {file = "pydantic_core-2.23.3-cp312-none-win_amd64.whl", hash = "sha256:40b8441be16c1e940abebed83cd006ddb9e3737a279e339dbd6d31578b802f7b"}, + {file = "pydantic_core-2.23.3-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:6daaf5b1ba1369a22c8b050b643250e3e5efc6a78366d323294aee54953a4d5f"}, + {file = "pydantic_core-2.23.3-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:d015e63b985a78a3d4ccffd3bdf22b7c20b3bbd4b8227809b3e8e75bc37f9cb2"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a3fc572d9b5b5cfe13f8e8a6e26271d5d13f80173724b738557a8c7f3a8a3791"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:f6bd91345b5163ee7448bee201ed7dd601ca24f43f439109b0212e296eb5b423"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:fc379c73fd66606628b866f661e8785088afe2adaba78e6bbe80796baf708a63"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:fbdce4b47592f9e296e19ac31667daed8753c8367ebb34b9a9bd89dacaa299c9"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fc3cf31edf405a161a0adad83246568647c54404739b614b1ff43dad2b02e6d5"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:8e22b477bf90db71c156f89a55bfe4d25177b81fce4aa09294d9e805eec13855"}, + {file = "pydantic_core-2.23.3-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:0a0137ddf462575d9bce863c4c95bac3493ba8e22f8c28ca94634b4a1d3e2bb4"}, + {file = "pydantic_core-2.23.3-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:203171e48946c3164fe7691fc349c79241ff8f28306abd4cad5f4f75ed80bc8d"}, + {file = "pydantic_core-2.23.3-cp313-none-win32.whl", hash = "sha256:76bdab0de4acb3f119c2a4bff740e0c7dc2e6de7692774620f7452ce11ca76c8"}, + {file = "pydantic_core-2.23.3-cp313-none-win_amd64.whl", hash = "sha256:37ba321ac2a46100c578a92e9a6aa33afe9ec99ffa084424291d84e456f490c1"}, + {file = "pydantic_core-2.23.3-cp38-cp38-macosx_10_12_x86_64.whl", hash = "sha256:d063c6b9fed7d992bcbebfc9133f4c24b7a7f215d6b102f3e082b1117cddb72c"}, + {file = "pydantic_core-2.23.3-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:6cb968da9a0746a0cf521b2b5ef25fc5a0bee9b9a1a8214e0a1cfaea5be7e8a4"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:edbefe079a520c5984e30e1f1f29325054b59534729c25b874a16a5048028d16"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:cbaaf2ef20d282659093913da9d402108203f7cb5955020bd8d1ae5a2325d1c4"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:fb539d7e5dc4aac345846f290cf504d2fd3c1be26ac4e8b5e4c2b688069ff4cf"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:7e6f33503c5495059148cc486867e1d24ca35df5fc064686e631e314d959ad5b"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:04b07490bc2f6f2717b10c3969e1b830f5720b632f8ae2f3b8b1542394c47a8e"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:03795b9e8a5d7fda05f3873efc3f59105e2dcff14231680296b87b80bb327295"}, + {file = "pydantic_core-2.23.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:c483dab0f14b8d3f0df0c6c18d70b21b086f74c87ab03c59250dbf6d3c89baba"}, + {file = "pydantic_core-2.23.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8b2682038e255e94baf2c473dca914a7460069171ff5cdd4080be18ab8a7fd6e"}, + {file = "pydantic_core-2.23.3-cp38-none-win32.whl", hash = "sha256:f4a57db8966b3a1d1a350012839c6a0099f0898c56512dfade8a1fe5fb278710"}, + {file = "pydantic_core-2.23.3-cp38-none-win_amd64.whl", hash = "sha256:13dd45ba2561603681a2676ca56006d6dee94493f03d5cadc055d2055615c3ea"}, + {file = "pydantic_core-2.23.3-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:82da2f4703894134a9f000e24965df73cc103e31e8c31906cc1ee89fde72cbd8"}, + {file = "pydantic_core-2.23.3-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:dd9be0a42de08f4b58a3cc73a123f124f65c24698b95a54c1543065baca8cf0e"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:89b731f25c80830c76fdb13705c68fef6a2b6dc494402987c7ea9584fe189f5d"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:c6de1ec30c4bb94f3a69c9f5f2182baeda5b809f806676675e9ef6b8dc936f28"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:bb68b41c3fa64587412b104294b9cbb027509dc2f6958446c502638d481525ef"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1c3980f2843de5184656aab58698011b42763ccba11c4a8c35936c8dd6c7068c"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:94f85614f2cba13f62c3c6481716e4adeae48e1eaa7e8bac379b9d177d93947a"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:510b7fb0a86dc8f10a8bb43bd2f97beb63cffad1203071dc434dac26453955cd"}, + {file = "pydantic_core-2.23.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:1eba2f7ce3e30ee2170410e2171867ea73dbd692433b81a93758ab2de6c64835"}, + {file = "pydantic_core-2.23.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:4b259fd8409ab84b4041b7b3f24dcc41e4696f180b775961ca8142b5b21d0e70"}, + {file = "pydantic_core-2.23.3-cp39-none-win32.whl", hash = "sha256:40d9bd259538dba2f40963286009bf7caf18b5112b19d2b55b09c14dde6db6a7"}, + {file = "pydantic_core-2.23.3-cp39-none-win_amd64.whl", hash = "sha256:5a8cd3074a98ee70173a8633ad3c10e00dcb991ecec57263aacb4095c5efb958"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:f399e8657c67313476a121a6944311fab377085ca7f490648c9af97fc732732d"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:6b5547d098c76e1694ba85f05b595720d7c60d342f24d5aad32c3049131fa5c4"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0dda0290a6f608504882d9f7650975b4651ff91c85673341789a476b1159f211"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:65b6e5da855e9c55a0c67f4db8a492bf13d8d3316a59999cfbaf98cc6e401961"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:09e926397f392059ce0afdcac920df29d9c833256354d0c55f1584b0b70cf07e"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:87cfa0ed6b8c5bd6ae8b66de941cece179281239d482f363814d2b986b79cedc"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:e61328920154b6a44d98cabcb709f10e8b74276bc709c9a513a8c37a18786cc4"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:ce3317d155628301d649fe5e16a99528d5680af4ec7aa70b90b8dacd2d725c9b"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:e89513f014c6be0d17b00a9a7c81b1c426f4eb9224b15433f3d98c1a071f8433"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:4f62c1c953d7ee375df5eb2e44ad50ce2f5aff931723b398b8bc6f0ac159791a"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2718443bc671c7ac331de4eef9b673063b10af32a0bb385019ad61dcf2cc8f6c"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a0d90e08b2727c5d01af1b5ef4121d2f0c99fbee692c762f4d9d0409c9da6541"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:2b676583fc459c64146debea14ba3af54e540b61762dfc0613dc4e98c3f66eeb"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:50e4661f3337977740fdbfbae084ae5693e505ca2b3130a6d4eb0f2281dc43b8"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:68f4cf373f0de6abfe599a38307f4417c1c867ca381c03df27c873a9069cda25"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:59d52cf01854cb26c46958552a21acb10dd78a52aa34c86f284e66b209db8cab"}, + {file = "pydantic_core-2.23.3.tar.gz", hash = "sha256:3cb0f65d8b4121c1b015c60104a685feb929a29d7cf204387c7f2688c7974690"}, +] + +[package.dependencies] +typing-extensions = ">=4.6.0,<4.7.0 || >4.7.0" [[package]] name = "pyjwt" @@ -1368,6 +1448,94 @@ files = [ {file = "pyyaml-6.0.2.tar.gz", hash = "sha256:d584d9ec91ad65861cc08d42e834324ef890a082e591037abe114850ff7bbc3e"}, ] +[[package]] +name = "regex" +version = "2024.7.24" +description = "Alternative regular expression module, to replace re." +optional = false +python-versions = ">=3.8" +files = [ + {file = "regex-2024.7.24-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:228b0d3f567fafa0633aee87f08b9276c7062da9616931382993c03808bb68ce"}, + {file = "regex-2024.7.24-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:3426de3b91d1bc73249042742f45c2148803c111d1175b283270177fdf669024"}, + {file = "regex-2024.7.24-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:f273674b445bcb6e4409bf8d1be67bc4b58e8b46fd0d560055d515b8830063cd"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:23acc72f0f4e1a9e6e9843d6328177ae3074b4182167e34119ec7233dfeccf53"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:65fd3d2e228cae024c411c5ccdffae4c315271eee4a8b839291f84f796b34eca"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c414cbda77dbf13c3bc88b073a1a9f375c7b0cb5e115e15d4b73ec3a2fbc6f59"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bf7a89eef64b5455835f5ed30254ec19bf41f7541cd94f266ab7cbd463f00c41"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:19c65b00d42804e3fbea9708f0937d157e53429a39b7c61253ff15670ff62cb5"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7a5486ca56c8869070a966321d5ab416ff0f83f30e0e2da1ab48815c8d165d46"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:6f51f9556785e5a203713f5efd9c085b4a45aecd2a42573e2b5041881b588d1f"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_i686.whl", hash = "sha256:a4997716674d36a82eab3e86f8fa77080a5d8d96a389a61ea1d0e3a94a582cf7"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_ppc64le.whl", hash = "sha256:c0abb5e4e8ce71a61d9446040c1e86d4e6d23f9097275c5bd49ed978755ff0fe"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_s390x.whl", hash = "sha256:18300a1d78cf1290fa583cd8b7cde26ecb73e9f5916690cf9d42de569c89b1ce"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:416c0e4f56308f34cdb18c3f59849479dde5b19febdcd6e6fa4d04b6c31c9faa"}, + {file = "regex-2024.7.24-cp310-cp310-win32.whl", hash = "sha256:fb168b5924bef397b5ba13aabd8cf5df7d3d93f10218d7b925e360d436863f66"}, + {file = "regex-2024.7.24-cp310-cp310-win_amd64.whl", hash = "sha256:6b9fc7e9cc983e75e2518496ba1afc524227c163e43d706688a6bb9eca41617e"}, + {file = "regex-2024.7.24-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:382281306e3adaaa7b8b9ebbb3ffb43358a7bbf585fa93821300a418bb975281"}, + {file = "regex-2024.7.24-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:4fdd1384619f406ad9037fe6b6eaa3de2749e2e12084abc80169e8e075377d3b"}, + {file = "regex-2024.7.24-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:3d974d24edb231446f708c455fd08f94c41c1ff4f04bcf06e5f36df5ef50b95a"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a2ec4419a3fe6cf8a4795752596dfe0adb4aea40d3683a132bae9c30b81e8d73"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:eb563dd3aea54c797adf513eeec819c4213d7dbfc311874eb4fd28d10f2ff0f2"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:45104baae8b9f67569f0f1dca5e1f1ed77a54ae1cd8b0b07aba89272710db61e"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:994448ee01864501912abf2bad9203bffc34158e80fe8bfb5b031f4f8e16da51"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3fac296f99283ac232d8125be932c5cd7644084a30748fda013028c815ba3364"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:7e37e809b9303ec3a179085415cb5f418ecf65ec98cdfe34f6a078b46ef823ee"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_i686.whl", hash = "sha256:01b689e887f612610c869421241e075c02f2e3d1ae93a037cb14f88ab6a8934c"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_ppc64le.whl", hash = "sha256:f6442f0f0ff81775eaa5b05af8a0ffa1dda36e9cf6ec1e0d3d245e8564b684ce"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_s390x.whl", hash = "sha256:871e3ab2838fbcb4e0865a6e01233975df3a15e6fce93b6f99d75cacbd9862d1"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:c918b7a1e26b4ab40409820ddccc5d49871a82329640f5005f73572d5eaa9b5e"}, + {file = "regex-2024.7.24-cp311-cp311-win32.whl", hash = "sha256:2dfbb8baf8ba2c2b9aa2807f44ed272f0913eeeba002478c4577b8d29cde215c"}, + {file = "regex-2024.7.24-cp311-cp311-win_amd64.whl", hash = "sha256:538d30cd96ed7d1416d3956f94d54e426a8daf7c14527f6e0d6d425fcb4cca52"}, + {file = "regex-2024.7.24-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:fe4ebef608553aff8deb845c7f4f1d0740ff76fa672c011cc0bacb2a00fbde86"}, + {file = "regex-2024.7.24-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:74007a5b25b7a678459f06559504f1eec2f0f17bca218c9d56f6a0a12bfffdad"}, + {file = "regex-2024.7.24-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:7df9ea48641da022c2a3c9c641650cd09f0cd15e8908bf931ad538f5ca7919c9"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6a1141a1dcc32904c47f6846b040275c6e5de0bf73f17d7a409035d55b76f289"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:80c811cfcb5c331237d9bad3bea2c391114588cf4131707e84d9493064d267f9"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:7214477bf9bd195894cf24005b1e7b496f46833337b5dedb7b2a6e33f66d962c"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d55588cba7553f0b6ec33130bc3e114b355570b45785cebdc9daed8c637dd440"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:558a57cfc32adcf19d3f791f62b5ff564922942e389e3cfdb538a23d65a6b610"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:a512eed9dfd4117110b1881ba9a59b31433caed0c4101b361f768e7bcbaf93c5"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:86b17ba823ea76256b1885652e3a141a99a5c4422f4a869189db328321b73799"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:5eefee9bfe23f6df09ffb6dfb23809f4d74a78acef004aa904dc7c88b9944b05"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:731fcd76bbdbf225e2eb85b7c38da9633ad3073822f5ab32379381e8c3c12e94"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:eaef80eac3b4cfbdd6de53c6e108b4c534c21ae055d1dbea2de6b3b8ff3def38"}, + {file = "regex-2024.7.24-cp312-cp312-win32.whl", hash = "sha256:185e029368d6f89f36e526764cf12bf8d6f0e3a2a7737da625a76f594bdfcbfc"}, + {file = "regex-2024.7.24-cp312-cp312-win_amd64.whl", hash = "sha256:2f1baff13cc2521bea83ab2528e7a80cbe0ebb2c6f0bfad15be7da3aed443908"}, + {file = "regex-2024.7.24-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:66b4c0731a5c81921e938dcf1a88e978264e26e6ac4ec96a4d21ae0354581ae0"}, + {file = "regex-2024.7.24-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:88ecc3afd7e776967fa16c80f974cb79399ee8dc6c96423321d6f7d4b881c92b"}, + {file = "regex-2024.7.24-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:64bd50cf16bcc54b274e20235bf8edbb64184a30e1e53873ff8d444e7ac656b2"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:eb462f0e346fcf41a901a126b50f8781e9a474d3927930f3490f38a6e73b6950"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a82465ebbc9b1c5c50738536fdfa7cab639a261a99b469c9d4c7dcbb2b3f1e57"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:68a8f8c046c6466ac61a36b65bb2395c74451df2ffb8458492ef49900efed293"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dac8e84fff5d27420f3c1e879ce9929108e873667ec87e0c8eeb413a5311adfe"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:ba2537ef2163db9e6ccdbeb6f6424282ae4dea43177402152c67ef869cf3978b"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:43affe33137fcd679bdae93fb25924979517e011f9dea99163f80b82eadc7e53"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_aarch64.whl", hash = "sha256:c9bb87fdf2ab2370f21e4d5636e5317775e5d51ff32ebff2cf389f71b9b13750"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_i686.whl", hash = "sha256:945352286a541406f99b2655c973852da7911b3f4264e010218bbc1cc73168f2"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_ppc64le.whl", hash = "sha256:8bc593dcce679206b60a538c302d03c29b18e3d862609317cb560e18b66d10cf"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_s390x.whl", hash = "sha256:3f3b6ca8eae6d6c75a6cff525c8530c60e909a71a15e1b731723233331de4169"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_x86_64.whl", hash = "sha256:c51edc3541e11fbe83f0c4d9412ef6c79f664a3745fab261457e84465ec9d5a8"}, + {file = "regex-2024.7.24-cp38-cp38-win32.whl", hash = "sha256:d0a07763776188b4db4c9c7fb1b8c494049f84659bb387b71c73bbc07f189e96"}, + {file = "regex-2024.7.24-cp38-cp38-win_amd64.whl", hash = "sha256:8fd5afd101dcf86a270d254364e0e8dddedebe6bd1ab9d5f732f274fa00499a5"}, + {file = "regex-2024.7.24-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:0ffe3f9d430cd37d8fa5632ff6fb36d5b24818c5c986893063b4e5bdb84cdf24"}, + {file = "regex-2024.7.24-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:25419b70ba00a16abc90ee5fce061228206173231f004437730b67ac77323f0d"}, + {file = "regex-2024.7.24-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:33e2614a7ce627f0cdf2ad104797d1f68342d967de3695678c0cb84f530709f8"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d33a0021893ede5969876052796165bab6006559ab845fd7b515a30abdd990dc"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:04ce29e2c5fedf296b1a1b0acc1724ba93a36fb14031f3abfb7abda2806c1535"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b16582783f44fbca6fcf46f61347340c787d7530d88b4d590a397a47583f31dd"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:836d3cc225b3e8a943d0b02633fb2f28a66e281290302a79df0e1eaa984ff7c1"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:438d9f0f4bc64e8dea78274caa5af971ceff0f8771e1a2333620969936ba10be"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:973335b1624859cb0e52f96062a28aa18f3a5fc77a96e4a3d6d76e29811a0e6e"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:c5e69fd3eb0b409432b537fe3c6f44ac089c458ab6b78dcec14478422879ec5f"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_i686.whl", hash = "sha256:fbf8c2f00904eaf63ff37718eb13acf8e178cb940520e47b2f05027f5bb34ce3"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_ppc64le.whl", hash = "sha256:ae2757ace61bc4061b69af19e4689fa4416e1a04840f33b441034202b5cd02d4"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_s390x.whl", hash = "sha256:44fc61b99035fd9b3b9453f1713234e5a7c92a04f3577252b45feefe1b327759"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:84c312cdf839e8b579f504afcd7b65f35d60b6285d892b19adea16355e8343c9"}, + {file = "regex-2024.7.24-cp39-cp39-win32.whl", hash = "sha256:ca5b2028c2f7af4e13fb9fc29b28d0ce767c38c7facdf64f6c2cd040413055f1"}, + {file = "regex-2024.7.24-cp39-cp39-win_amd64.whl", hash = "sha256:7c479f5ae937ec9985ecaf42e2e10631551d909f203e31308c12d703922742f9"}, + {file = "regex-2024.7.24.tar.gz", hash = "sha256:9cfd009eed1a46b27c14039ad5bbc5e71b6367c5b2e6d5f5da0ea91600817506"}, +] + [[package]] name = "requests" version = "2.32.3" @@ -1436,6 +1604,60 @@ requests = ">=2.22,<3" [package.extras] fixture = ["fixtures"] +[[package]] +name = "serpyco-rs" +version = "1.11.0" +description = "" +optional = false +python-versions = ">=3.9" +files = [ + {file = "serpyco_rs-1.11.0-cp310-cp310-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:4b2bd933539bd8c84315e2fb5ae52ef7a58ace5a6dfe3f8b73f74dc71216779e"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:627f957889ff73c4d2269fc7b6bba93212381befe03633e7cb5495de66ba9a33"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:b0933620abc01434023e0e3e22255b7e4ab9b427b5a9a5ee00834656d792377a"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:9ce46683d92e34abb20304817fc5ac6cb141a06fc7468dedb1d8865a8a9682f6"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:bda437d86e8859bf91c189c1f4650899822f6d6d7b02b48f5729da904eb7bb7d"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5a72bfbd282af17ebe76d122639013e802c09902543fdbbd828fb2159ec9755e"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4d4808df5384e3e8581e31a90ba7a1fa501c0837b1f174284bb8a4555b6864ea"}, + {file = "serpyco_rs-1.11.0-cp310-none-win_amd64.whl", hash = "sha256:c7b60aef4c16d68efb0d6241f05d0a434d873d98449cbb4366b0d385f0a7172b"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:8d47ee577cf4d69b53917615cb031ad8708eb2f59fe78194b1968c13130fc2f7"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6090d9a1487237cdd4e9362a823eede23249602019b917e7bd57846179286e79"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7192eb3df576386fefd595ea31ae25c62522841ffec7e7aeb37a80b55bdc3213"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:b52ef8affb7e71b9b98a7d5216d6a7ad03b04e990acb147cd9211c8b931c5487"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3480e09e473560c60e74aaa789e6b4d079637371aae0a98235440111464bbba7"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5c92e36b0ab6fe866601c2331f7e99c809a126d21963c03d8a5c29331526deed"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:84f497361952d4566bc1f77e9e15a84a2614f593cc671fbf0a0fa80046f9c3d7"}, + {file = "serpyco_rs-1.11.0-cp311-none-win_amd64.whl", hash = "sha256:37fc1cf192bef9784fbf1f4e03cec21750b9e704bef55cc0442f71a715eee920"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:3ea93d485f03dc8b0cfb0d477f0ad2e86e78f0461b53010656ab5b4db1b41fb0"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7772410d15694b03f9c5500a2c47d62eed76e191bea4087ad042250346b1a38e"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:42118463c1679846cffd2f06f47744c9b9eb33c5d0448afd88ea19e1a81a8ddd"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:79481a455b76cc56021dc55bb6d5bdda1b2b32bcb6a1ee711b597140d112e9b1"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c8fd79051f9af9591fc03cf7d3033ff180416301f6a4fd3d1e3d92ebd2d68697"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:d29c8f9aeed734a3b51f7349d04ec9063516ffa4e10b632d75e9b1309e4930e4"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:15609158b0d9591ffa118302cd9d0039970cb3faf91dce32975f7d276e7411d5"}, + {file = "serpyco_rs-1.11.0-cp312-none-win_amd64.whl", hash = "sha256:00081eae77fbf4c5d88371c5586317ab02ccb293a330b460869a283edf2b7b69"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:3028893366a1985adcedb13fa8f6f98c087c185efc427f94c2ccdafa40f45832"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3c18bf511316f3abf648a68ee62ef88617bec57d3fcde69466b4361102715ae5"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:e7dde9ef09cdfaf7c62378186b9e29f54ec76114be4c347be6a06dd559c5681e"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:18500ebc5e75285841e35585a238629a990b709e14f68933233640d15ca17d5f"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f47c23132d4e03982703a7630aa09877b41e499722142f76b6153f6619b612f3"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5f8e6ba499f6a0825bee0d8f8764569d367af871b563fc6512c171474e8e5383"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:15438a076047c34cff6601a977df54948e8d39d1a86f89d05c48bc60f4c12a61"}, + {file = "serpyco_rs-1.11.0-cp313-none-win_amd64.whl", hash = "sha256:84ee2c109415bd81904fc9abb9aec86a5dd13166808c21142cf23ec639f683bd"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:5c97c16c865261577fac4effeccc7ef5e0a1e8e35e7a3ee6c90c77c3a4cd7ff9"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:47825e70f86fd6ef7c4a835dea3d6e8eef4fee354ed7b39ced99f31aba74a86e"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:24d220220365110edba2f778f41ab3cf396883da0f26e1361a3ada9bd0227f73"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:3a46f334af5a9d77acc6e1e58f355ae497900a2798929371f0545e274f6e6166"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:29d72b748acce4b4e3c7c9724e1eb33d033a1c26b08a698b393e0288060e0901"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e2b8b6f205e8cc038d4d30dd0e70eece7bbecc816eb2f3787c330dc2218e232d"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:038d748bfff31f150f0c3edab2766b8843edb952cb1bd3bf547886beb0912dae"}, + {file = "serpyco_rs-1.11.0-cp39-none-win_amd64.whl", hash = "sha256:0fee1c89ec2cb013dc232e4ebef88e2844357ce8631063b56639dbfb83762f20"}, + {file = "serpyco_rs-1.11.0.tar.gz", hash = "sha256:70a844615ffb229e6e89c204b3ab7404aacaf2838911814c7d847969b8da2e3a"}, +] + +[package.dependencies] +attributes-doc = "*" +typing-extensions = "*" + [[package]] name = "setuptools" version = "74.1.2" @@ -1504,6 +1726,26 @@ files = [ {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, ] +[[package]] +name = "tqdm" +version = "4.66.5" +description = "Fast, Extensible Progress Meter" +optional = false +python-versions = ">=3.7" +files = [ + {file = "tqdm-4.66.5-py3-none-any.whl", hash = "sha256:90279a3770753eafc9194a0364852159802111925aa30eb3f9d85b0e805ac7cd"}, + {file = "tqdm-4.66.5.tar.gz", hash = "sha256:e1020aef2e5096702d8a025ac7d16b1577279c9d63f8375b63083e9a5f0fcbad"}, +] + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + +[package.extras] +dev = ["pytest (>=6)", "pytest-cov", "pytest-timeout", "pytest-xdist"] +notebook = ["ipywidgets (>=6)"] +slack = ["slack-sdk"] +telegram = ["requests"] + [[package]] name = "typing-extensions" version = "4.12.2" @@ -1652,5 +1894,5 @@ files = [ [metadata] lock-version = "2.0" -python-versions = "^3.9,<3.12" -content-hash = "b6e517853295db78c861e5ce27360f284dd28a95ff3e4a858f9c80ecfb2aa92b" +python-versions = "^3.10,<3.12" +content-hash = "12365ababcf35c6a01cf066b541467060b57be3acb69ba00c503a2a70f06b959" diff --git a/airbyte-integrations/connectors/source-sendgrid/pyproject.toml b/airbyte-integrations/connectors/source-sendgrid/pyproject.toml index 2520921792e05..60278fb34b4de 100644 --- a/airbyte-integrations/connectors/source-sendgrid/pyproject.toml +++ b/airbyte-integrations/connectors/source-sendgrid/pyproject.toml @@ -3,7 +3,7 @@ requires = [ "poetry-core>=1.0.0",] build-backend = "poetry.core.masonry.api" [tool.poetry] -version = "1.0.18" +version = "1.1.0" name = "source-sendgrid" description = "Source implementation for Sendgrid." authors = [ "Airbyte ",] @@ -16,8 +16,8 @@ repository = "https://github.com/airbytehq/airbyte" include = "source_sendgrid" [tool.poetry.dependencies] -python = "^3.9,<3.12" -airbyte-cdk = "^0" +python = "^3.10,<3.12" +airbyte_cdk = "^5" pandas = "^2.1.1" [tool.poetry.scripts] diff --git a/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/config_migrations.py b/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/config_migrations.py index 222a4136aa876..4aef50b467ad7 100644 --- a/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/config_migrations.py +++ b/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/config_migrations.py @@ -8,8 +8,10 @@ import pendulum from airbyte_cdk.config_observation import create_connector_config_control_message from airbyte_cdk.entrypoint import AirbyteEntrypoint +from airbyte_cdk.models import AirbyteMessageSerializer from airbyte_cdk.sources import Source from airbyte_cdk.sources.message import InMemoryMessageRepository, MessageRepository +from orjson import orjson logger = logging.getLogger("airbyte_logger") @@ -68,7 +70,8 @@ def modify_and_save(cls, config_path: str, source: Source, config: Mapping[str, @classmethod def emit_control_message(cls, migrated_config: Mapping[str, Any]) -> None: - print(create_connector_config_control_message(migrated_config).json(exclude_unset=True)) + message = create_connector_config_control_message(migrated_config) + print(orjson.dumps(AirbyteMessageSerializer.dump(message)).decode()) @classmethod def migrate(cls, args: List[str], source: Source) -> None: diff --git a/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/manifest.yaml b/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/manifest.yaml index 675dbe5878511..9542f54c2e2e9 100644 --- a/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/manifest.yaml +++ b/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/manifest.yaml @@ -1,4 +1,4 @@ -version: 0.81.1 +version: 5.5.0 type: DeclarativeSource check: type: CheckStream @@ -874,6 +874,62 @@ streams: page_size: 100 cursor_value: '{{ response.get("_metadata", {}).get("next", {}) }}' stop_condition: '{{ not response.get("_metadata", {}).get("next", {}) }}' + + - type: DeclarativeStream + name: contacts + primary_key: + - contact_id + $parameters: + name: contacts + schema_loader: + type: JsonFileSchemaLoader + file_path: "./source_sendgrid/schemas/{{ parameters['name'] }}.json" + retriever: + type: AsyncRetriever + status_mapping: + running: + - pending + completed: + - ready + failed: + - failed + timeout: + - timeout + status_extractor: + type: DpathExtractor + field_path: ["status"] + urls_extractor: + type: DpathExtractor + field_path: ["urls"] + creation_requester: + type: HttpRequester + http_method: POST + url_base: https://api.sendgrid.com + path: /v3/marketing/contacts/exports + authenticator: + type: BearerAuthenticator + api_token: "{{ config['api_key'] }}" + polling_requester: + type: HttpRequester + http_method: GET + url_base: https://api.sendgrid.com + path: "/v3/marketing/contacts/exports/{{stream_slice['create_job_response'].json()['id'] }}" + authenticator: + type: BearerAuthenticator + api_token: "{{ config['api_key'] }}" + download_requester: + type: HttpRequester + http_method: GET + url_base: "" + path: "{{stream_slice['url']}}" + record_selector: + type: RecordSelector + extractor: + type: DpathExtractor + field_path: [] + transformations: + - type: KeysToLower + spec: connection_specification: $schema: http://json-schema.org/draft-07/schema# diff --git a/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/source.py b/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/source.py index 336aa554bcb0a..6a02ae4aa52f5 100644 --- a/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/source.py +++ b/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/source.py @@ -2,26 +2,10 @@ # Copyright (c) 2023 Airbyte, Inc., all rights reserved. # -from typing import Any, List, Mapping from airbyte_cdk.sources.declarative.yaml_declarative_source import YamlDeclarativeSource -from airbyte_cdk.sources.streams import Stream -from airbyte_cdk.sources.streams.http.requests_native_auth import TokenAuthenticator -from .streams import Contacts - -# Hybrid Declarative Source class SourceSendgrid(YamlDeclarativeSource): - def __init__(self): - # this takes care of check and other methods + def __init__(self) -> None: super().__init__(**{"path_to_yaml": "manifest.yaml"}) - - def streams(self, config: Mapping[str, Any]) -> List[Stream]: - # get all the lowcode streams - streams = super().streams(config) - authenticator = TokenAuthenticator(config["api_key"]) - # this stream download a csv file from sendgrid and emits the records - # it's not currently easy to do in lowcode, so we do it in python - streams.append(Contacts(authenticator=authenticator)) - return streams diff --git a/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/streams.py b/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/streams.py deleted file mode 100644 index 7d46efaf0b2aa..0000000000000 --- a/airbyte-integrations/connectors/source-sendgrid/source_sendgrid/streams.py +++ /dev/null @@ -1,199 +0,0 @@ -# -# Copyright (c) 2023 Airbyte, Inc., all rights reserved. -# - -import math -import os -import time -import zlib -from abc import ABC -from contextlib import closing -from typing import Any, Iterable, List, Mapping, Optional, Tuple -from urllib.parse import urlparse - -import pandas as pd -import pendulum -import requests -from airbyte_cdk.models import SyncMode -from airbyte_cdk.sources.streams.http import HttpStream -from airbyte_cdk.sources.streams.http.rate_limiting import default_backoff_handler -from numpy import nan -from pendulum import DateTime -from requests import codes, exceptions - - -class SendgridStream(HttpStream, ABC): - url_base = "https://api.sendgrid.com/" - primary_key = "id" - limit = 50 - data_field = None - raise_on_http_errors = True - permission_error_codes = { - 400: "authorization required", - 401: "authorization required", - } - - def next_page_token(self, response: requests.Response) -> Optional[Mapping[str, Any]]: - pass - - def parse_response( - self, - response: requests.Response, - stream_state: Mapping[str, Any] = None, - stream_slice: Mapping[str, Any] = None, - next_page_token: Mapping[str, Any] = None, - ) -> Iterable[Mapping]: - pass # not actually used because Contacts does read_records - - -class Contacts(SendgridStream): - primary_key = "contact_id" - MAX_RETRY_NUMBER = 3 - DEFAULT_WAIT_TIMEOUT_SECONDS = 60 - MAX_CHECK_INTERVAL_SECONDS = 2.0 - encoding = "utf-8" - - def path(self, **kwargs) -> str: - return "v3/marketing/contacts/exports" - - @default_backoff_handler(max_tries=5, factor=15) - def _send_http_request(self, method: str, url: str, stream: bool = False, enable_auth: bool = True): - headers = self._session.auth.get_auth_header() if enable_auth else None - response = self._session.request(method, url=url, headers=headers, stream=stream) - if response.status_code not in [200, 202]: - self.logger.error(f"error body: {response.text}") - response.raise_for_status() - return response - - def read_records( - self, - sync_mode: SyncMode, - cursor_field: List[str] = None, - stream_slice: Mapping[str, Any] = None, - stream_state: Mapping[str, Any] = None, - ) -> Iterable[Mapping[str, Any]]: - csv_urls, job_status = self.execute_export_job(url=f"{self.url_base}{self.path()}") - if job_status == "failed": - raise Exception(f"Export Job failed for more than 3 times, skipping reading stream {self.name}") - for url in csv_urls: - for record in self.read_with_chunks(*self.download_data(url=url)): - yield record - - def execute_export_job(self, url: str) -> Tuple[Optional[str], Optional[str]]: - job_status = "failed" - for i in range(0, self.MAX_RETRY_NUMBER): - job_id = self.create_export_job(url=url) - if not job_id: - return None, job_status - job_full_url = f"{url}/{job_id}" - urls, job_status = self.wait_for_job(url=job_full_url) - if urls: - break - self.logger.error(f"Waiting error. Try to run this job again {i + 1}/{self.MAX_RETRY_NUMBER}...") - - return urls, job_status - - def create_export_job(self, url: str) -> Optional[str]: - """ - docs: https://docs.sendgrid.com/api-reference/contacts/export-contacts - """ - try: - response = self._send_http_request("POST", url) - job_id: str = response.json().get("id") - return job_id - except exceptions.HTTPError as error: - if error.response.status_code in [codes.BAD_REQUEST, codes.UNAUTHORIZED, codes.FORBIDDEN, codes.NOT_FOUND, codes.SERVER_ERROR]: - error_data = error.response.json().get("errors")[0] - error_id = error_data.get("error_id") - error_message = error_data.get("message") - error_parameter = error_data.get("parameter") - self.logger.error(f"Cannot receive data for stream '{self.name}' ," f"{error_message=}, {error_id=}, {error_parameter=}") - else: - raise error - return None - - def wait_for_job(self, url: str) -> Tuple[List[str], str]: - """ - docs: https://docs.sendgrid.com/api-reference/contacts/export-contacts-status - """ - expiration_time: DateTime = pendulum.now().add(seconds=self.DEFAULT_WAIT_TIMEOUT_SECONDS) - job_status = "pending" - urls: List[str] = [] - delay_timeout = 0.0 - delay_cnt = 0 - job_info = None - time.sleep(0.5) - while pendulum.now() < expiration_time: - job_info = self._send_http_request("GET", url=url).json() - job_status = job_info.get("status") - urls = job_info.get("urls", []) - if job_status in ("ready", "failure"): - if job_status != "ready": - self.logger.error(f"JobStatus: {job_status}, error message: '{job_info}'") - - return urls, job_status - - if delay_timeout < self.MAX_CHECK_INTERVAL_SECONDS: - delay_timeout = 0.5 + math.exp(delay_cnt) / 1000.0 - delay_cnt += 1 - - time.sleep(delay_timeout) - job_id = job_info["id"] - self.logger.info( - f"Sleeping {delay_timeout} seconds while waiting for Job: {self.name}/{job_id} to complete. Current state: {job_status}" - ) - - self.logger.warning(f"Not wait the {self.name} data for {self.DEFAULT_WAIT_TIMEOUT_SECONDS} seconds, data: {job_info}!!") - return urls, job_status - - def download_data(self, url: str, chunk_size: int = 1024) -> tuple[str, str]: - """ - Retrieves binary data result from successfully `executed_job`, using chunks, to avoid local memory limitations. - Response received in .gzip binary format. - @ url: string - the url of the `executed_job` - @ chunk_size: int - the buffer size for each chunk to fetch from stream, in bytes, default: 1024 bytes - Return the tuple containing string with file path of downloaded binary data (Saved temporarily) and file encoding. - """ - # set filepath for binary data from response - decompressor = zlib.decompressobj(zlib.MAX_WBITS | 32) - - url_parsed = urlparse(url) - tmp_file = os.path.realpath(os.path.basename(url_parsed.path[1:-5])) - download_session = requests.get(f"{url}", stream=True) - with closing(download_session) as response, open(tmp_file, "wb") as data_file: - for chunk in response.iter_content(chunk_size=chunk_size): - try: - # see if it's compressed. we are seeing some that are not all of a sudden. - # but let's also guard against the case where sendgrid changes it back. - data_file.write(decompressor.decompress(chunk)) - except zlib.error as e: - # it's not actually compressed! - data_file.write(chunk) - # check the file exists - if os.path.isfile(tmp_file): - return tmp_file, self.encoding - else: - raise Exception(f"The IO/Error occured while verifying binary data. Stream: {self.name}, file {tmp_file} doesn't exist.") - - def read_with_chunks(self, path: str, file_encoding: str, chunk_size: int = 100) -> Iterable[Tuple[int, Mapping[str, Any]]]: - """ - Reads the downloaded binary data, using lines chunks, set by `chunk_size`. - @ path: string - the path to the downloaded temporarily binary data. - @ file_encoding: string - encoding for binary data file according to Standard Encodings from codecs module - @ chunk_size: int - the number of lines to read at a time, default: 100 lines / time. - """ - try: - with open(path, "r", encoding=file_encoding) as data: - chunks = pd.read_csv(data, chunksize=chunk_size, iterator=True, dialect="unix", dtype=str) - for chunk in chunks: - chunk = ({k.lower(): v for k, v in x.items()} for x in chunk.replace({nan: None}).to_dict(orient="records")) - for row in chunk: - yield row - except pd.errors.EmptyDataError as e: - self.logger.info(f"Empty data received. {e}") - yield from [] - except IOError as ioe: - raise Exception(f"The IO/Error occured while reading tmp data. Called: {path}. Stream: {self.name}", ioe) - finally: - # remove binary tmp file, after data is read - os.remove(path) diff --git a/airbyte-integrations/connectors/source-sendgrid/unit_tests/unit_test.py b/airbyte-integrations/connectors/source-sendgrid/unit_tests/unit_test.py index 4e6e0c8706b13..3f72904f16478 100644 --- a/airbyte-integrations/connectors/source-sendgrid/unit_tests/unit_test.py +++ b/airbyte-integrations/connectors/source-sendgrid/unit_tests/unit_test.py @@ -4,22 +4,23 @@ import logging import os -import unittest -from unittest.mock import MagicMock, Mock +from typing import Any, List +from unittest.mock import MagicMock import pandas as pd import pendulum import pytest from airbyte_cdk.models import SyncMode +from airbyte_cdk.sources.streams.core import StreamData +from airbyte_cdk.sources.streams.http.error_handlers.response_models import ResponseAction from numpy import nan from requests import codes from source_sendgrid.source import SourceSendgrid -from source_sendgrid.streams import Contacts, SendgridStream FAKE_NOW = pendulum.DateTime(2022, 1, 1, tzinfo=pendulum.timezone("utc")) FAKE_NOW_ISO_STRING = FAKE_NOW.to_iso8601_string() - +@staticmethod def find_stream(stream_name): streams = SourceSendgrid().streams(config={"api_key": "wrong.api.key123"}) # find by name @@ -28,31 +29,15 @@ def find_stream(stream_name): return stream raise ValueError(f"Stream {stream_name} not found") - -@pytest.fixture(name="sendgrid_stream") -def sendgrid_stream_fixture(mocker) -> SendgridStream: - # Wipe the internal list of abstract methods to allow instantiating - # the abstract class without implementing its abstract methods - mocker.patch("source_sendgrid.streams.SendgridStream.__abstractmethods__", set()) - # Mypy yells at us because we're initializing an abstract class - return SendgridStream() # type: ignore - - -@pytest.fixture() -def mock_pendulum_now(monkeypatch): - pendulum_mock = unittest.mock.MagicMock(wraps=pendulum.now) - pendulum_mock.return_value = FAKE_NOW - monkeypatch.setattr(pendulum, "now", pendulum_mock) - - -@pytest.fixture() -def mock_authenticator(): - mock = Mock() - mock.get_auth_header.return_value = {"Authorization": "Bearer fake_token"} - return mock +@staticmethod +def record_keys_to_lowercase(records: List[StreamData]) -> List[dict[str, str | Any]]: + return [ + {k.lower(): v if isinstance(v, str) else v for k, v in d.items()} + for d in records + ] -def test_source_wrong_credentials(): +def test_source_wrong_credentials() -> None: source = SourceSendgrid() status, error = source.check_connection(logger=logging.getLogger("airbyte"), config={"api_key": "wrong.api.key123"}) assert not status @@ -60,132 +45,74 @@ def test_source_wrong_credentials(): def test_streams(): streams = SourceSendgrid().streams(config={"api_key": "wrong.api.key123", "start_date": FAKE_NOW_ISO_STRING}) - assert len(streams) == 15 @pytest.mark.parametrize( - "stream_name, url , expected", - ( - ["templates", "https://api.sendgrid.com/v3/templates", []], - ["lists", "https://api.sendgrid.com/v3/marketing/lists", []], - ["campaigns", "https://api.sendgrid.com/v3/marketing/campaigns", []], - ["segments", "https://api.sendgrid.com/v3/marketing/segments/2.0", []], - ["blocks", "https://api.sendgrid.com/v3/suppression/blocks", ["name", "id", "contact_count", "_metadata"]], - ["suppression_group_members", "https://api.sendgrid.com/v3/asm/suppressions", ["name", "id", "contact_count", "_metadata"]], - ["suppression_groups", "https://api.sendgrid.com/v3/asm/groups", ["name", "id", "contact_count", "_metadata"]], - ["global_suppressions", "https://api.sendgrid.com/v3/suppression/unsubscribes", ["name", "id", "contact_count", "_metadata"]], - ), -) -def test_read_records( - stream_name, - url, - expected, - requests_mock -): - requests_mock.get("https://api.sendgrid.com/v3/marketing/contacts/exports", json={}) - stream = find_stream(stream_name) - requests_mock.get("https://api.sendgrid.com/v3/marketing", json={}) - requests_mock.get(url, json={"name": "test", "id": "id", "contact_count": 20, "_metadata": {"self": "self"}}) - records = list(stream.read_records(sync_mode=SyncMode)) - if len(records) == 0: - assert [] == expected - else: - keys = list(records[0].keys()) - assert keys == expected - - -@pytest.mark.parametrize( - "stream_name, expected", + "stream_name, status, expected", ( - ["templates", "v3/templates"], - ["lists", "v3/marketing/lists"], - ["campaigns", "v3/marketing/campaigns"], - ["contacts", "v3/marketing/contacts/exports"], - ["segments", "v3/marketing/segments/2.0"], - ["blocks", "v3/suppression/blocks"], - ["suppression_group_members", "v3/asm/suppressions"], - ["suppression_groups", "v3/asm/groups"], - ["global_suppressions", "v3/suppression/unsubscribes"], - ["bounces", "v3/suppression/bounces"], - ["invalid_emails", "v3/suppression/invalid_emails"], - ["spam_reports", "v3/suppression/spam_reports"], + ("blocks", 400, ResponseAction.RETRY), + ("blocks", 429, ResponseAction.RETRY), + ("suppression_group_members", 401, ResponseAction.RETRY), ), ) -def test_path(stream_name, expected): +def test_should_retry_on_permission_error(stream_name, status, expected) -> None: stream = find_stream(stream_name) - if hasattr(stream, "path"): - path = stream.path() # Contacts for example - else: - path = stream.retriever.requester.get_path(stream_state=None, stream_slice=None, next_page_token=None) - - assert path == expected + response_mock = MagicMock() + response_mock.status_code = status + response_action = stream.retriever.requester.error_handler.interpret_response(response_mock).response_action + assert response_action == expected @pytest.mark.parametrize( - "stream_name, status, expected", + "stream_name, compressed_or_decompressed_file", ( - ("blocks", 400, False), - ("blocks", 429, True), - ("suppression_group_members", 401, False), + ("contacts", "decompressed_response.csv"), + ("contacts", "compressed_response"), ), + ids=[ + "Decompressed response", + "Compressed (gzipped) response", + ] ) -def test_should_retry_on_permission_error(stream_name, status, expected): - stream = find_stream(stream_name) - response_mock = MagicMock() - response_mock.status_code = status - assert stream.retriever.requester._should_retry(response_mock) == expected - - -def test_compressed_contact_response(requests_mock, mock_authenticator): - stream = Contacts() - stream._session.auth = mock_authenticator +def test_contact_stream_response(requests_mock, stream_name, compressed_or_decompressed_file) -> None: + # instantiate the stream from low-code + streams = SourceSendgrid().streams(config={"api_key": "wrong.api.key123"}) + stream = [stream for stream in streams if stream.name == stream_name][0] - with open(os.path.dirname(__file__) + "/compressed_response", "rb") as file_response: + with open(os.path.dirname(__file__) + "/" + compressed_or_decompressed_file, "rb") as file_response: + # mocking job creation requests url = "https://api.sendgrid.com/v3/marketing/contacts/exports" requests_mock.register_uri("POST", url, [{"json": {"id": "random_id"}, "status_code": 202}]) - url = "https://api.sendgrid.com/v3/marketing/contacts/exports/random_id" - resp_bodies = [ - {"json": {"status": "pending", "id": "random_id", "urls": []}, "status_code": 202}, - {"json": {"status": "ready", "urls": ["https://sample_url/sample_csv.csv.gzip"]}, "status_code": 202}, - ] - requests_mock.register_uri("GET", url, resp_bodies) - requests_mock.register_uri("GET", "https://sample_url/sample_csv.csv.gzip", [{"body": file_response, "status_code": 202}]) - recs = list(stream.read_records(sync_mode=SyncMode.full_refresh)) - decompressed_response = pd.read_csv(os.path.dirname(__file__) + "/decompressed_response.csv", dtype=str) - expected_records = [ - {k.lower(): v for k, v in x.items()} for x in decompressed_response.replace({nan: None}).to_dict(orient="records") - ] - - assert recs == expected_records - -def test_uncompressed_contact_response(requests_mock, mock_authenticator): - stream = Contacts() - stream._session.auth = mock_authenticator - - with open(os.path.dirname(__file__) + "/decompressed_response.csv", "rb") as file_response: - url = "https://api.sendgrid.com/v3/marketing/contacts/exports" - requests_mock.register_uri("POST", url, [{"json": {"id": "random_id"}, "status_code": 202}]) - url = "https://api.sendgrid.com/v3/marketing/contacts/exports/random_id" + # mocking status requests + created_job_url = "https://api.sendgrid.com/v3/marketing/contacts/exports/random_id" resp_bodies = [ {"json": {"status": "pending", "id": "random_id", "urls": []}, "status_code": 202}, {"json": {"status": "ready", "urls": ["https://sample_url/sample_csv.csv.gzip"]}, "status_code": 202}, ] - requests_mock.register_uri("GET", url, resp_bodies) + requests_mock.register_uri("GET", created_job_url, resp_bodies) requests_mock.register_uri("GET", "https://sample_url/sample_csv.csv.gzip", [{"body": file_response, "status_code": 202}]) - recs = list(stream.read_records(sync_mode=SyncMode.full_refresh)) + + # read the records + stream_slice = next(iter(stream.stream_slices(sync_mode=SyncMode.full_refresh))) + recs = list(stream.read_records(sync_mode=SyncMode.full_refresh, stream_slice=stream_slice)) decompressed_response = pd.read_csv(os.path.dirname(__file__) + "/decompressed_response.csv", dtype=str) + + # process results expected_records = [ - {k.lower(): v for k, v in x.items()} for x in decompressed_response.replace({nan: None}).to_dict(orient="records") + {k.lower(): v for k, v in x.items()} + for x in decompressed_response.replace({nan: None}).to_dict(orient="records") ] - + recs = record_keys_to_lowercase(recs) assert recs == expected_records -def test_bad_job_response(requests_mock, mock_authenticator): - stream = Contacts() - stream._session.auth = mock_authenticator +def test_bad_job_response(requests_mock) -> None: + # instantiate the stream from low-code + streams = SourceSendgrid().streams(config={"api_key": "wrong.api.key123"}) + stream = [stream for stream in streams if stream.name == "contacts"][0] + url = "https://api.sendgrid.com/v3/marketing/contacts/exports" requests_mock.register_uri( @@ -193,12 +120,3 @@ def test_bad_job_response(requests_mock, mock_authenticator): ) with pytest.raises(Exception): list(stream.read_records(sync_mode=SyncMode.full_refresh)) - - -def test_read_chunks_pd(): - stream = Contacts() - with open("file_not_exist.csv", "w"): - pass - list(stream.read_with_chunks(path="file_not_exist.csv", file_encoding="utf-8")) - with pytest.raises(FileNotFoundError): - list(stream.read_with_chunks(path="file_not_exist.csv", file_encoding="utf-8")) diff --git a/airbyte-integrations/connectors/source-stripe/acceptance-test-config.yml b/airbyte-integrations/connectors/source-stripe/acceptance-test-config.yml index 122254a082d28..41c0fbd785044 100644 --- a/airbyte-integrations/connectors/source-stripe/acceptance-test-config.yml +++ b/airbyte-integrations/connectors/source-stripe/acceptance-test-config.yml @@ -39,8 +39,6 @@ acceptance_tests: bypass_reason: "This stream can't be seeded in our sandbox account" - name: "external_account_cards" bypass_reason: "This stream can't be seeded in our sandbox account" - - name: "payment_methods" - bypass_reason: "This stream can't be seeded in our sandbox account" - name: "persons" bypass_reason: "This stream can't be seeded in our sandbox account" - name: "reviews" diff --git a/airbyte-integrations/connectors/source-stripe/integration_tests/expected_records.jsonl b/airbyte-integrations/connectors/source-stripe/integration_tests/expected_records.jsonl index 73c5aa8aefaf3..d9e4f800f283e 100644 --- a/airbyte-integrations/connectors/source-stripe/integration_tests/expected_records.jsonl +++ b/airbyte-integrations/connectors/source-stripe/integration_tests/expected_records.jsonl @@ -23,6 +23,8 @@ {"stream": "customers", "data": {"id": "cus_LIiHR6omh14Xdg", "object": "customer", "address": {"city": "san francisco", "country": "US", "line1": "san francisco", "line2": "", "postal_code": "", "state": "CA"}, "balance": 0, "created": 1646998902, "currency": "usd", "default_source": "card_1MSHU1EcXtiJtvvhytSN6V54", "delinquent": false, "description": "test", "discount": null, "email": "test@airbyte_integration_test.com", "invoice_prefix": "09A6A98F", "invoice_settings": {"custom_fields": null, "default_payment_method": null, "footer": null, "rendering_options": null}, "livemode": false, "metadata": {}, "name": "Test", "next_invoice_sequence": 1, "phone": null, "preferred_locales": [], "shipping": {"address": {"city": "", "country": "US", "line1": "", "line2": "", "postal_code": "", "state": ""}, "name": "", "phone": ""}, "tax_exempt": "none", "test_clock": null, "updated": 1646998902}, "emitted_at": 1697627278433} {"stream": "customers", "data": {"id": "cus_Kou8knsO3qQOwU", "object": "customer", "address": null, "balance": 0, "created": 1640123795, "currency": "usd", "default_source": "src_1MSID8EcXtiJtvvhxIT9lXRy", "delinquent": false, "description": null, "discount": null, "email": "edward.gao+stripe-test-customer-1@airbyte.io", "invoice_prefix": "CA35DF83", "invoice_settings": {"custom_fields": null, "default_payment_method": null, "footer": null, "rendering_options": null}, "livemode": false, "metadata": {}, "name": "edgao-test-customer-1", "next_invoice_sequence": 2, "phone": null, "preferred_locales": [], "shipping": null, "tax_exempt": "none", "test_clock": null, "updated": 1640123795}, "emitted_at": 1697627278435} {"stream": "customers", "data": {"id": "cus_NGoTFiJFVbSsvZ", "object": "customer", "address": {"city": "", "country": "US", "line1": "Street 2, 34567", "line2": "", "postal_code": "94114", "state": "CA"}, "balance": 0, "created": 1675160053, "currency": "usd", "default_source": "src_1MWGs8EcXtiJtvvh4nYdQvEr", "delinquent": false, "description": "Test Customer 2 description", "discount": null, "email": "user1.sample@zohomail.eu", "invoice_prefix": "C09C1837", "invoice_settings": {"custom_fields": null, "default_payment_method": null, "footer": null, "rendering_options": null}, "livemode": false, "metadata": {}, "name": "Test Customer 2", "next_invoice_sequence": 15, "phone": null, "preferred_locales": ["en-US"], "shipping": {"address": {"city": "", "country": "US", "line1": "Street 2, 34567", "line2": "", "postal_code": "94114", "state": "CA"}, "name": "Test Customer 2", "phone": ""}, "tax_exempt": "none", "test_clock": null, "updated": 1675160053}, "emitted_at": 1697627278439} +{"stream":"payment_methods","data":{"id":"src_1MWGs8EcXtiJtvvh4nYdQvEr","object":"payment_method","billing_details":{"address":{"city":null,"country":null,"line1":null,"line2":null,"postal_code":"94114","state":null},"email":null,"name":null,"phone":null},"card":{"brand":"visa","checks":{"address_line1_check":null,"address_postal_code_check":"pass","cvc_check":"pass"},"country":"US","display_brand":"visa","exp_month":12,"exp_year":2024,"fingerprint":"X7e9fFB0r8MMcdo6","funding":"credit","generated_from":null,"last4":"4242","networks":{"available":["visa"],"preferred":null},"three_d_secure_usage":{"supported":true},"wallet":null},"created":1675160128,"customer":"cus_NGoTFiJFVbSsvZ","livemode":false,"metadata":{},"type":"card","updated":1675160128},"emitted_at":1725546716514} +{"stream":"payment_methods","data":{"id":"pm_1PYSZ3EcXtiJtvvhIos7UZSV","object":"payment_method","allow_redisplay":"limited","billing_details":{"address":{"city":null,"country":"CA","line1":null,"line2":null,"postal_code":"K1P 5L9","state":null},"email":"customer99900@example.com","name":"Customer 999","phone":null},"card":{"brand":"visa","checks":{"address_line1_check":null,"address_postal_code_check":"pass","cvc_check":"unchecked"},"country":"US","display_brand":"visa","exp_month":1,"exp_year":2026,"fingerprint":"X7e9fFB0r8MMcdo6","funding":"credit","generated_from":null,"last4":"4242","networks":{"available":["visa"],"preferred":null},"three_d_secure_usage":{"supported":true},"wallet":null},"created":1720010738,"customer":"cus_QPH7FKQ1vXX4N0","livemode":false,"metadata":{"order_id":"6735"},"type":"card","updated":1720010738},"emitted_at":1725546770308} {"stream": "cardholders", "data": {"id": "ich_1KUKBeEcXtiJtvvhCEFgko6h", "object": "issuing.cardholder", "billing": {"address": {"city": "San Francisco", "country": "US", "line1": "1234 Main Street", "line2": null, "postal_code": "94111", "state": "CA"}}, "company": null, "created": 1645143542, "email": "jenny.rosen@example.com", "individual": null, "livemode": false, "metadata": {}, "name": "Jenny Rosen", "phone_number": "+18888675309", "preferred_locales": [], "requirements": {"disabled_reason": null, "past_due": []}, "spending_controls": {"allowed_categories": [], "blocked_categories": [], "spending_limits": [], "spending_limits_currency": null}, "status": "active", "type": "individual", "updated": 1645143542}, "emitted_at": 1697627292209} {"stream": "charges", "data": {"id": "ch_3K9FSOEcXtiJtvvh0zxb7clc", "object": "charge", "amount": 5300, "amount_captured": 5300, "amount_refunded": 0, "amount_updates": [], "application": null, "application_fee": null, "application_fee_amount": null, "balance_transaction": "txn_3K9FSOEcXtiJtvvh0KoS5mx7", "billing_details": {"address": {"city": null, "country": null, "line1": null, "line2": null, "postal_code": null, "state": null}, "email": null, "name": null, "phone": null}, "calculated_statement_descriptor": "AIRBYTE.IO", "captured": true, "created": 1640120473, "currency": "usd", "customer": null, "description": null, "destination": null, "dispute": null, "disputed": false, "failure_balance_transaction": null, "failure_code": null, "failure_message": null, "fraud_details": {}, "invoice": null, "livemode": false, "metadata": {}, "on_behalf_of": null, "order": null, "outcome": {"network_status": "approved_by_network", "reason": null, "risk_level": "normal", "risk_score": 48, "seller_message": "Payment complete.", "type": "authorized"}, "paid": true, "payment_intent": "pi_3K9FSOEcXtiJtvvh0AEIFllC", "payment_method": "src_1K9FSOEcXtiJtvvhHGu1qtOx", "payment_method_details": {"card": {"amount_authorized": 5300, "brand": "visa", "checks": {"address_line1_check": null, "address_postal_code_check": null, "cvc_check": "pass"}, "country": "US", "exp_month": 12, "exp_year": 2034, "extended_authorization": {"status": "disabled"}, "fingerprint": "X7e9fFB0r8MMcdo6", "funding": "credit", "incremental_authorization": {"status": "unavailable"}, "installments": null, "last4": "4242", "mandate": null, "multicapture": {"status": "unavailable"}, "network": "visa", "network_token": {"used": false}, "overcapture": {"maximum_amount_capturable": 5300, "status": "unavailable"}, "three_d_secure": null, "wallet": null}, "type": "card"}, "receipt_email": null, "receipt_number": "1509-9197", "receipt_url": "https://pay.stripe.com/receipts/payment/CAcaFwoVYWNjdF8xSndub2lFY1h0aUp0dnZoKJ35vqkGMgYYlboX7Hs6LBbBoR6yFToo5WeMCCwbkvCz7nl3E1KToovFFZKMJYnrpAHBlWJrVMJK6BWm", "refunded": false, "refunds": {"object": "list", "data": [], "has_more": false, "total_count": 0.0, "url": "/v1/charges/ch_3K9FSOEcXtiJtvvh0zxb7clc/refunds"}, "review": null, "shipping": null, "source": {"id": "src_1K9FSOEcXtiJtvvhHGu1qtOx", "object": "source", "amount": null, "card": {"address_line1_check": null, "address_zip_check": null, "brand": "Visa", "country": "US", "cvc_check": "pass", "dynamic_last4": null, "exp_month": 12, "exp_year": 2034, "fingerprint": "X7e9fFB0r8MMcdo6", "funding": "credit", "last4": "4242", "name": null, "three_d_secure": "optional", "tokenization_method": null}, "client_secret": "src_client_secret_3WszbFGtWT8vmMjqnNztOwhU", "created": 1640120473, "currency": null, "flow": "none", "livemode": false, "metadata": {}, "owner": {"address": null, "email": null, "name": null, "phone": null, "verified_address": null, "verified_email": null, "verified_name": null, "verified_phone": null}, "statement_descriptor": null, "status": "consumed", "type": "card", "usage": "reusable"}, "source_transfer": null, "statement_descriptor": "airbyte.io", "statement_descriptor_suffix": null, "status": "succeeded", "transfer_data": null, "transfer_group": null, "updated": 1640120473}, "emitted_at": 1697627293840} {"stream": "charges", "data": {"id": "ch_3K9F5DEcXtiJtvvh1w2MaTpj", "object": "charge", "amount": 4200, "amount_captured": 4200, "amount_refunded": 0, "amount_updates": [], "application": null, "application_fee": null, "application_fee_amount": null, "balance_transaction": "txn_3K9F5DEcXtiJtvvh1qsqmHcH", "billing_details": {"address": {"city": null, "country": null, "line1": null, "line2": null, "postal_code": null, "state": null}, "email": null, "name": null, "phone": null}, "calculated_statement_descriptor": "AIRBYTE.IO", "captured": true, "created": 1640119035, "currency": "usd", "customer": null, "description": "edgao test", "destination": null, "dispute": null, "disputed": false, "failure_balance_transaction": null, "failure_code": null, "failure_message": null, "fraud_details": {}, "invoice": null, "livemode": false, "metadata": {}, "on_behalf_of": null, "order": null, "outcome": {"network_status": "approved_by_network", "reason": null, "risk_level": "normal", "risk_score": 63, "seller_message": "Payment complete.", "type": "authorized"}, "paid": true, "payment_intent": "pi_3K9F5DEcXtiJtvvh16scJMp6", "payment_method": "src_1K9F5CEcXtiJtvvhrsZdur8Y", "payment_method_details": {"card": {"amount_authorized": 4200, "brand": "visa", "checks": {"address_line1_check": null, "address_postal_code_check": null, "cvc_check": "pass"}, "country": "US", "exp_month": 9, "exp_year": 2028, "extended_authorization": {"status": "disabled"}, "fingerprint": "X7e9fFB0r8MMcdo6", "funding": "credit", "incremental_authorization": {"status": "unavailable"}, "installments": null, "last4": "4242", "mandate": null, "multicapture": {"status": "unavailable"}, "network": "visa", "network_token": {"used": false}, "overcapture": {"maximum_amount_capturable": 4200, "status": "unavailable"}, "three_d_secure": null, "wallet": null}, "type": "card"}, "receipt_email": null, "receipt_number": "1549-5630", "receipt_url": "https://pay.stripe.com/receipts/payment/CAcaFwoVYWNjdF8xSndub2lFY1h0aUp0dnZoKJ35vqkGMgbg2Y1Ao1M6LBYViHyCHYtYZtCIzc8I1Pm_oXAcXtgPDTNCfzyB3XOfFO4N-RK2w9sLuPjq", "refunded": false, "refunds": {"object": "list", "data": [], "has_more": false, "total_count": 0.0, "url": "/v1/charges/ch_3K9F5DEcXtiJtvvh1w2MaTpj/refunds"}, "review": null, "shipping": null, "source": {"id": "src_1K9F5CEcXtiJtvvhrsZdur8Y", "object": "source", "amount": null, "card": {"address_line1_check": null, "address_zip_check": null, "brand": "Visa", "country": "US", "cvc_check": "pass", "dynamic_last4": null, "exp_month": 9, "exp_year": 2028, "fingerprint": "X7e9fFB0r8MMcdo6", "funding": "credit", "last4": "4242", "name": null, "three_d_secure": "optional", "tokenization_method": null}, "client_secret": "src_client_secret_QyH8xuqSyiZh8oxzzIszqQ92", "created": 1640119035, "currency": null, "flow": "none", "livemode": false, "metadata": {}, "owner": {"address": null, "email": null, "name": null, "phone": null, "verified_address": null, "verified_email": null, "verified_name": null, "verified_phone": null}, "statement_descriptor": null, "status": "consumed", "type": "card", "usage": "reusable"}, "source_transfer": null, "statement_descriptor": "airbyte.io", "statement_descriptor_suffix": null, "status": "succeeded", "transfer_data": null, "transfer_group": null, "updated": 1640119035}, "emitted_at": 1697627293843} diff --git a/airbyte-integrations/connectors/source-stripe/metadata.yaml b/airbyte-integrations/connectors/source-stripe/metadata.yaml index e65e8e2993d9e..d2ccfca192acc 100644 --- a/airbyte-integrations/connectors/source-stripe/metadata.yaml +++ b/airbyte-integrations/connectors/source-stripe/metadata.yaml @@ -10,7 +10,7 @@ data: connectorSubtype: api connectorType: source definitionId: e094cb9a-26de-4645-8761-65c0c425d1de - dockerImageTag: 5.5.3 + dockerImageTag: 5.6.0 dockerRepository: airbyte/source-stripe documentationUrl: https://docs.airbyte.com/integrations/sources/stripe erdUrl: https://dbdocs.io/airbyteio/source-stripe?view=relationships diff --git a/airbyte-integrations/connectors/source-stripe/poetry.lock b/airbyte-integrations/connectors/source-stripe/poetry.lock index f471f8796a357..25149610c9336 100644 --- a/airbyte-integrations/connectors/source-stripe/poetry.lock +++ b/airbyte-integrations/connectors/source-stripe/poetry.lock @@ -1,18 +1,18 @@ -# This file is automatically @generated by Poetry 1.6.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 1.8.3 and should not be changed by hand. [[package]] name = "airbyte-cdk" -version = "4.3.2" +version = "5.5.2" description = "A framework for writing Airbyte Connectors." optional = false python-versions = "<4.0,>=3.10" files = [ - {file = "airbyte_cdk-4.3.2-py3-none-any.whl", hash = "sha256:1dd92de77e2212b13ed6f1e9c4b2559baa905eff6db5bf14b0fbaf1149e60e4c"}, - {file = "airbyte_cdk-4.3.2.tar.gz", hash = "sha256:89db68167e214e5b55d5ef5f821f017ee64bf859f44c60bc0169071fa376e9af"}, + {file = "airbyte_cdk-5.5.2-py3-none-any.whl", hash = "sha256:cbca686ce52b1b26a49801308927662ef477400ca0142832f06f0add3073bf0e"}, + {file = "airbyte_cdk-5.5.2.tar.gz", hash = "sha256:7e105be721a141979852229fbeb1a2aaf12bd2adf6b51806867f07ca4c3d365b"}, ] [package.dependencies] -airbyte-protocol-models-pdv2 = ">=0.12.2,<0.13.0" +airbyte-protocol-models-dataclasses = ">=0.13,<0.14" backoff = "*" cachetools = "*" cryptography = ">=42.0.5,<43.0.0" @@ -24,6 +24,9 @@ Jinja2 = ">=3.1.2,<3.2.0" jsonref = ">=0.2,<0.3" jsonschema = ">=3.2.0,<3.3.0" langchain_core = "0.1.42" +nltk = "3.8.1" +orjson = ">=3.10.7,<4.0.0" +pandas = "2.2.0" pendulum = "<3.0.0" pydantic = ">=2.7,<3.0" pyjwt = ">=2.8.0,<3.0.0" @@ -33,27 +36,25 @@ pytz = "2024.1" PyYAML = ">=6.0.1,<7.0.0" requests = "*" requests_cache = "*" +serpyco-rs = ">=1.10.2,<2.0.0" wcmatch = "8.4" [package.extras] -file-based = ["avro (>=1.11.2,<1.12.0)", "fastavro (>=1.8.0,<1.9.0)", "markdown", "pdf2image (==1.16.3)", "pdfminer.six (==20221105)", "pyarrow (>=15.0.0,<15.1.0)", "pytesseract (==0.3.10)", "unstructured.pytesseract (>=0.3.12)", "unstructured[docx,pptx] (==0.10.27)"] +file-based = ["avro (>=1.11.2,<1.12.0)", "fastavro (>=1.8.0,<1.9.0)", "markdown", "pdf2image (==1.16.3)", "pdfminer.six (==20221105)", "pyarrow (>=15.0.0,<15.1.0)", "pytesseract (==0.3.10)", "python-calamine (==0.2.3)", "unstructured.pytesseract (>=0.3.12)", "unstructured[docx,pptx] (==0.10.27)"] sphinx-docs = ["Sphinx (>=4.2,<4.3)", "sphinx-rtd-theme (>=1.0,<1.1)"] vector-db-based = ["cohere (==4.21)", "langchain (==0.1.16)", "openai[embeddings] (==0.27.9)", "tiktoken (==0.4.0)"] [[package]] -name = "airbyte-protocol-models-pdv2" -version = "0.12.2" -description = "Declares the Airbyte Protocol." +name = "airbyte-protocol-models-dataclasses" +version = "0.13.0" +description = "Declares the Airbyte Protocol using Python Dataclasses. Dataclasses in Python have less performance overhead compared to Pydantic models, making them a more efficient choice for scenarios where speed and memory usage are critical" optional = false python-versions = ">=3.8" files = [ - {file = "airbyte_protocol_models_pdv2-0.12.2-py3-none-any.whl", hash = "sha256:8b3f9d0388928547cdf2e9134c0d589e4bcaa6f63bf71a21299f6824bfb7ad0e"}, - {file = "airbyte_protocol_models_pdv2-0.12.2.tar.gz", hash = "sha256:130c9ab289f3f53749ce63ff1abbfb67a44b7e5bd2794865315a2976138b672b"}, + {file = "airbyte_protocol_models_dataclasses-0.13.0-py3-none-any.whl", hash = "sha256:0aedb99ffc4f9aab0ce91bba2c292fa17cd8fd4b42eeba196d6a16c20bbbd7a5"}, + {file = "airbyte_protocol_models_dataclasses-0.13.0.tar.gz", hash = "sha256:72e67850d661e2808406aec5839b3158ebb94d3553b798dbdae1b4a278548d2f"}, ] -[package.dependencies] -pydantic = ">=2.7.2,<3.0.0" - [[package]] name = "annotated-types" version = "0.7.0" @@ -66,13 +67,36 @@ files = [ ] [[package]] -name = "atomicwrites" -version = "1.4.1" -description = "Atomic file writes." +name = "anyio" +version = "4.4.0" +description = "High level compatibility layer for multiple asynchronous event loop implementations" optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" +python-versions = ">=3.8" files = [ - {file = "atomicwrites-1.4.1.tar.gz", hash = "sha256:81b2c9071a49367a7f770170e5eec8cb66567cfbbc8c73d20ce5ca4a8d71cf11"}, + {file = "anyio-4.4.0-py3-none-any.whl", hash = "sha256:c1b2d8f46a8a812513012e1107cb0e68c17159a7a594208005a57dc776e1bdc7"}, + {file = "anyio-4.4.0.tar.gz", hash = "sha256:5aadc6a1bbb7cdb0bede386cac5e2940f5e2ff3aa20277e991cf028e0585ce94"}, +] + +[package.dependencies] +exceptiongroup = {version = ">=1.0.2", markers = "python_version < \"3.11\""} +idna = ">=2.8" +sniffio = ">=1.1" +typing-extensions = {version = ">=4.1", markers = "python_version < \"3.11\""} + +[package.extras] +doc = ["Sphinx (>=7)", "packaging", "sphinx-autodoc-typehints (>=1.2.0)", "sphinx-rtd-theme"] +test = ["anyio[trio]", "coverage[toml] (>=7)", "exceptiongroup (>=1.2.0)", "hypothesis (>=4.0)", "psutil (>=5.9)", "pytest (>=7.0)", "pytest-mock (>=3.6.1)", "trustme", "uvloop (>=0.17)"] +trio = ["trio (>=0.23)"] + +[[package]] +name = "attributes-doc" +version = "0.4.0" +description = "PEP 224 implementation" +optional = false +python-versions = ">=3.8" +files = [ + {file = "attributes-doc-0.4.0.tar.gz", hash = "sha256:b1576c94a714e9fc2c65c47cf10d0c8e1a5f7c4f5ae7f69006be108d95cbfbfb"}, + {file = "attributes_doc-0.4.0-py2.py3-none-any.whl", hash = "sha256:4c3007d9e58f3a6cb4b9c614c4d4ce2d92161581f28e594ddd8241cc3a113bdd"}, ] [[package]] @@ -118,24 +142,24 @@ files = [ [[package]] name = "cachetools" -version = "5.4.0" +version = "5.5.0" description = "Extensible memoizing collections and decorators" optional = false python-versions = ">=3.7" files = [ - {file = "cachetools-5.4.0-py3-none-any.whl", hash = "sha256:3ae3b49a3d5e28a77a0be2b37dbcb89005058959cb2323858c2657c4a8cab474"}, - {file = "cachetools-5.4.0.tar.gz", hash = "sha256:b8adc2e7c07f105ced7bc56dbb6dfbe7c4a00acce20e2227b3f355be89bc6827"}, + {file = "cachetools-5.5.0-py3-none-any.whl", hash = "sha256:02134e8439cdc2ffb62023ce1debca2944c3f289d66bb17ead3ab3dede74b292"}, + {file = "cachetools-5.5.0.tar.gz", hash = "sha256:2cc24fb4cbe39633fb7badd9db9ca6295d766d9c2995f245725a46715d050f2a"}, ] [[package]] name = "cattrs" -version = "23.2.3" +version = "24.1.0" description = "Composable complex class support for attrs and dataclasses." optional = false python-versions = ">=3.8" files = [ - {file = "cattrs-23.2.3-py3-none-any.whl", hash = "sha256:0341994d94971052e9ee70662542699a3162ea1e0c62f7ce1b4a57f563685108"}, - {file = "cattrs-23.2.3.tar.gz", hash = "sha256:a934090d95abaa9e911dac357e3a8699e0b4b14f8529bcc7d2b1ad9d51672b9f"}, + {file = "cattrs-24.1.0-py3-none-any.whl", hash = "sha256:043bb8af72596432a7df63abcff0055ac0f198a4d2e95af8db5a936a7074a761"}, + {file = "cattrs-24.1.0.tar.gz", hash = "sha256:8274f18b253bf7674a43da851e3096370d67088165d23138b04a1c04c8eaf48e"}, ] [package.dependencies] @@ -147,6 +171,7 @@ typing-extensions = {version = ">=4.1.0,<4.6.3 || >4.6.3", markers = "python_ver bson = ["pymongo (>=4.4.0)"] cbor2 = ["cbor2 (>=5.4.6)"] msgpack = ["msgpack (>=1.0.5)"] +msgspec = ["msgspec (>=0.18.5)"] orjson = ["orjson (>=3.9.2)"] pyyaml = ["pyyaml (>=6.0)"] tomlkit = ["tomlkit (>=0.11.8)"] @@ -154,89 +179,89 @@ ujson = ["ujson (>=5.7.0)"] [[package]] name = "certifi" -version = "2024.7.4" +version = "2024.8.30" description = "Python package for providing Mozilla's CA Bundle." optional = false python-versions = ">=3.6" files = [ - {file = "certifi-2024.7.4-py3-none-any.whl", hash = "sha256:c198e21b1289c2ab85ee4e67bb4b4ef3ead0892059901a8d5b622f24a1101e90"}, - {file = "certifi-2024.7.4.tar.gz", hash = "sha256:5a1e7645bc0ec61a09e26c36f6106dd4cf40c6db3a1fb6352b0244e7fb057c7b"}, + {file = "certifi-2024.8.30-py3-none-any.whl", hash = "sha256:922820b53db7a7257ffbda3f597266d435245903d80737e34f8a45ff3e3230d8"}, + {file = "certifi-2024.8.30.tar.gz", hash = "sha256:bec941d2aa8195e248a60b31ff9f0558284cf01a52591ceda73ea9afffd69fd9"}, ] [[package]] name = "cffi" -version = "1.17.0" +version = "1.17.1" description = "Foreign Function Interface for Python calling C code." optional = false python-versions = ">=3.8" files = [ - {file = "cffi-1.17.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f9338cc05451f1942d0d8203ec2c346c830f8e86469903d5126c1f0a13a2bcbb"}, - {file = "cffi-1.17.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:a0ce71725cacc9ebf839630772b07eeec220cbb5f03be1399e0457a1464f8e1a"}, - {file = "cffi-1.17.0-cp310-cp310-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:c815270206f983309915a6844fe994b2fa47e5d05c4c4cef267c3b30e34dbe42"}, - {file = "cffi-1.17.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d6bdcd415ba87846fd317bee0774e412e8792832e7805938987e4ede1d13046d"}, - {file = "cffi-1.17.0-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:8a98748ed1a1df4ee1d6f927e151ed6c1a09d5ec21684de879c7ea6aa96f58f2"}, - {file = "cffi-1.17.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0a048d4f6630113e54bb4b77e315e1ba32a5a31512c31a273807d0027a7e69ab"}, - {file = "cffi-1.17.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:24aa705a5f5bd3a8bcfa4d123f03413de5d86e497435693b638cbffb7d5d8a1b"}, - {file = "cffi-1.17.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:856bf0924d24e7f93b8aee12a3a1095c34085600aa805693fb7f5d1962393206"}, - {file = "cffi-1.17.0-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:4304d4416ff032ed50ad6bb87416d802e67139e31c0bde4628f36a47a3164bfa"}, - {file = "cffi-1.17.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:331ad15c39c9fe9186ceaf87203a9ecf5ae0ba2538c9e898e3a6967e8ad3db6f"}, - {file = "cffi-1.17.0-cp310-cp310-win32.whl", hash = "sha256:669b29a9eca6146465cc574659058ed949748f0809a2582d1f1a324eb91054dc"}, - {file = "cffi-1.17.0-cp310-cp310-win_amd64.whl", hash = "sha256:48b389b1fd5144603d61d752afd7167dfd205973a43151ae5045b35793232aa2"}, - {file = "cffi-1.17.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:c5d97162c196ce54af6700949ddf9409e9833ef1003b4741c2b39ef46f1d9720"}, - {file = "cffi-1.17.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:5ba5c243f4004c750836f81606a9fcb7841f8874ad8f3bf204ff5e56332b72b9"}, - {file = "cffi-1.17.0-cp311-cp311-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:bb9333f58fc3a2296fb1d54576138d4cf5d496a2cc118422bd77835e6ae0b9cb"}, - {file = "cffi-1.17.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:435a22d00ec7d7ea533db494da8581b05977f9c37338c80bc86314bec2619424"}, - {file = "cffi-1.17.0-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d1df34588123fcc88c872f5acb6f74ae59e9d182a2707097f9e28275ec26a12d"}, - {file = "cffi-1.17.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:df8bb0010fdd0a743b7542589223a2816bdde4d94bb5ad67884348fa2c1c67e8"}, - {file = "cffi-1.17.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a8b5b9712783415695663bd463990e2f00c6750562e6ad1d28e072a611c5f2a6"}, - {file = "cffi-1.17.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:ffef8fd58a36fb5f1196919638f73dd3ae0db1a878982b27a9a5a176ede4ba91"}, - {file = "cffi-1.17.0-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:4e67d26532bfd8b7f7c05d5a766d6f437b362c1bf203a3a5ce3593a645e870b8"}, - {file = "cffi-1.17.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:45f7cd36186db767d803b1473b3c659d57a23b5fa491ad83c6d40f2af58e4dbb"}, - {file = "cffi-1.17.0-cp311-cp311-win32.whl", hash = "sha256:a9015f5b8af1bb6837a3fcb0cdf3b874fe3385ff6274e8b7925d81ccaec3c5c9"}, - {file = "cffi-1.17.0-cp311-cp311-win_amd64.whl", hash = "sha256:b50aaac7d05c2c26dfd50c3321199f019ba76bb650e346a6ef3616306eed67b0"}, - {file = "cffi-1.17.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:aec510255ce690d240f7cb23d7114f6b351c733a74c279a84def763660a2c3bc"}, - {file = "cffi-1.17.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:2770bb0d5e3cc0e31e7318db06efcbcdb7b31bcb1a70086d3177692a02256f59"}, - {file = "cffi-1.17.0-cp312-cp312-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:db9a30ec064129d605d0f1aedc93e00894b9334ec74ba9c6bdd08147434b33eb"}, - {file = "cffi-1.17.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a47eef975d2b8b721775a0fa286f50eab535b9d56c70a6e62842134cf7841195"}, - {file = "cffi-1.17.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f3e0992f23bbb0be00a921eae5363329253c3b86287db27092461c887b791e5e"}, - {file = "cffi-1.17.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:6107e445faf057c118d5050560695e46d272e5301feffda3c41849641222a828"}, - {file = "cffi-1.17.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:eb862356ee9391dc5a0b3cbc00f416b48c1b9a52d252d898e5b7696a5f9fe150"}, - {file = "cffi-1.17.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:c1c13185b90bbd3f8b5963cd8ce7ad4ff441924c31e23c975cb150e27c2bf67a"}, - {file = "cffi-1.17.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:17c6d6d3260c7f2d94f657e6872591fe8733872a86ed1345bda872cfc8c74885"}, - {file = "cffi-1.17.0-cp312-cp312-win32.whl", hash = "sha256:c3b8bd3133cd50f6b637bb4322822c94c5ce4bf0d724ed5ae70afce62187c492"}, - {file = "cffi-1.17.0-cp312-cp312-win_amd64.whl", hash = "sha256:dca802c8db0720ce1c49cce1149ff7b06e91ba15fa84b1d59144fef1a1bc7ac2"}, - {file = "cffi-1.17.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:6ce01337d23884b21c03869d2f68c5523d43174d4fc405490eb0091057943118"}, - {file = "cffi-1.17.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:cab2eba3830bf4f6d91e2d6718e0e1c14a2f5ad1af68a89d24ace0c6b17cced7"}, - {file = "cffi-1.17.0-cp313-cp313-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:14b9cbc8f7ac98a739558eb86fabc283d4d564dafed50216e7f7ee62d0d25377"}, - {file = "cffi-1.17.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b00e7bcd71caa0282cbe3c90966f738e2db91e64092a877c3ff7f19a1628fdcb"}, - {file = "cffi-1.17.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:41f4915e09218744d8bae14759f983e466ab69b178de38066f7579892ff2a555"}, - {file = "cffi-1.17.0-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e4760a68cab57bfaa628938e9c2971137e05ce48e762a9cb53b76c9b569f1204"}, - {file = "cffi-1.17.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:011aff3524d578a9412c8b3cfaa50f2c0bd78e03eb7af7aa5e0df59b158efb2f"}, - {file = "cffi-1.17.0-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:a003ac9edc22d99ae1286b0875c460351f4e101f8c9d9d2576e78d7e048f64e0"}, - {file = "cffi-1.17.0-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:ef9528915df81b8f4c7612b19b8628214c65c9b7f74db2e34a646a0a2a0da2d4"}, - {file = "cffi-1.17.0-cp313-cp313-win32.whl", hash = "sha256:70d2aa9fb00cf52034feac4b913181a6e10356019b18ef89bc7c12a283bf5f5a"}, - {file = "cffi-1.17.0-cp313-cp313-win_amd64.whl", hash = "sha256:b7b6ea9e36d32582cda3465f54c4b454f62f23cb083ebc7a94e2ca6ef011c3a7"}, - {file = "cffi-1.17.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:964823b2fc77b55355999ade496c54dde161c621cb1f6eac61dc30ed1b63cd4c"}, - {file = "cffi-1.17.0-cp38-cp38-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:516a405f174fd3b88829eabfe4bb296ac602d6a0f68e0d64d5ac9456194a5b7e"}, - {file = "cffi-1.17.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dec6b307ce928e8e112a6bb9921a1cb00a0e14979bf28b98e084a4b8a742bd9b"}, - {file = "cffi-1.17.0-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e4094c7b464cf0a858e75cd14b03509e84789abf7b79f8537e6a72152109c76e"}, - {file = "cffi-1.17.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2404f3de742f47cb62d023f0ba7c5a916c9c653d5b368cc966382ae4e57da401"}, - {file = "cffi-1.17.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3aa9d43b02a0c681f0bfbc12d476d47b2b2b6a3f9287f11ee42989a268a1833c"}, - {file = "cffi-1.17.0-cp38-cp38-win32.whl", hash = "sha256:0bb15e7acf8ab35ca8b24b90af52c8b391690ef5c4aec3d31f38f0d37d2cc499"}, - {file = "cffi-1.17.0-cp38-cp38-win_amd64.whl", hash = "sha256:93a7350f6706b31f457c1457d3a3259ff9071a66f312ae64dc024f049055f72c"}, - {file = "cffi-1.17.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:1a2ddbac59dc3716bc79f27906c010406155031a1c801410f1bafff17ea304d2"}, - {file = "cffi-1.17.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:6327b572f5770293fc062a7ec04160e89741e8552bf1c358d1a23eba68166759"}, - {file = "cffi-1.17.0-cp39-cp39-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dbc183e7bef690c9abe5ea67b7b60fdbca81aa8da43468287dae7b5c046107d4"}, - {file = "cffi-1.17.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5bdc0f1f610d067c70aa3737ed06e2726fd9d6f7bfee4a351f4c40b6831f4e82"}, - {file = "cffi-1.17.0-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:6d872186c1617d143969defeadac5a904e6e374183e07977eedef9c07c8953bf"}, - {file = "cffi-1.17.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0d46ee4764b88b91f16661a8befc6bfb24806d885e27436fdc292ed7e6f6d058"}, - {file = "cffi-1.17.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6f76a90c345796c01d85e6332e81cab6d70de83b829cf1d9762d0a3da59c7932"}, - {file = "cffi-1.17.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:0e60821d312f99d3e1569202518dddf10ae547e799d75aef3bca3a2d9e8ee693"}, - {file = "cffi-1.17.0-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:eb09b82377233b902d4c3fbeeb7ad731cdab579c6c6fda1f763cd779139e47c3"}, - {file = "cffi-1.17.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:24658baf6224d8f280e827f0a50c46ad819ec8ba380a42448e24459daf809cf4"}, - {file = "cffi-1.17.0-cp39-cp39-win32.whl", hash = "sha256:0fdacad9e0d9fc23e519efd5ea24a70348305e8d7d85ecbb1a5fa66dc834e7fb"}, - {file = "cffi-1.17.0-cp39-cp39-win_amd64.whl", hash = "sha256:7cbc78dc018596315d4e7841c8c3a7ae31cc4d638c9b627f87d52e8abaaf2d29"}, - {file = "cffi-1.17.0.tar.gz", hash = "sha256:f3157624b7558b914cb039fd1af735e5e8049a87c817cc215109ad1c8779df76"}, + {file = "cffi-1.17.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:df8b1c11f177bc2313ec4b2d46baec87a5f3e71fc8b45dab2ee7cae86d9aba14"}, + {file = "cffi-1.17.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:8f2cdc858323644ab277e9bb925ad72ae0e67f69e804f4898c070998d50b1a67"}, + {file = "cffi-1.17.1-cp310-cp310-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:edae79245293e15384b51f88b00613ba9f7198016a5948b5dddf4917d4d26382"}, + {file = "cffi-1.17.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:45398b671ac6d70e67da8e4224a065cec6a93541bb7aebe1b198a61b58c7b702"}, + {file = "cffi-1.17.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:ad9413ccdeda48c5afdae7e4fa2192157e991ff761e7ab8fdd8926f40b160cc3"}, + {file = "cffi-1.17.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5da5719280082ac6bd9aa7becb3938dc9f9cbd57fac7d2871717b1feb0902ab6"}, + {file = "cffi-1.17.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2bb1a08b8008b281856e5971307cc386a8e9c5b625ac297e853d36da6efe9c17"}, + {file = "cffi-1.17.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:045d61c734659cc045141be4bae381a41d89b741f795af1dd018bfb532fd0df8"}, + {file = "cffi-1.17.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6883e737d7d9e4899a8a695e00ec36bd4e5e4f18fabe0aca0efe0a4b44cdb13e"}, + {file = "cffi-1.17.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:6b8b4a92e1c65048ff98cfe1f735ef8f1ceb72e3d5f0c25fdb12087a23da22be"}, + {file = "cffi-1.17.1-cp310-cp310-win32.whl", hash = "sha256:c9c3d058ebabb74db66e431095118094d06abf53284d9c81f27300d0e0d8bc7c"}, + {file = "cffi-1.17.1-cp310-cp310-win_amd64.whl", hash = "sha256:0f048dcf80db46f0098ccac01132761580d28e28bc0f78ae0d58048063317e15"}, + {file = "cffi-1.17.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:a45e3c6913c5b87b3ff120dcdc03f6131fa0065027d0ed7ee6190736a74cd401"}, + {file = "cffi-1.17.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:30c5e0cb5ae493c04c8b42916e52ca38079f1b235c2f8ae5f4527b963c401caf"}, + {file = "cffi-1.17.1-cp311-cp311-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:f75c7ab1f9e4aca5414ed4d8e5c0e303a34f4421f8a0d47a4d019ceff0ab6af4"}, + {file = "cffi-1.17.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a1ed2dd2972641495a3ec98445e09766f077aee98a1c896dcb4ad0d303628e41"}, + {file = "cffi-1.17.1-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:46bf43160c1a35f7ec506d254e5c890f3c03648a4dbac12d624e4490a7046cd1"}, + {file = "cffi-1.17.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a24ed04c8ffd54b0729c07cee15a81d964e6fee0e3d4d342a27b020d22959dc6"}, + {file = "cffi-1.17.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:610faea79c43e44c71e1ec53a554553fa22321b65fae24889706c0a84d4ad86d"}, + {file = "cffi-1.17.1-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:a9b15d491f3ad5d692e11f6b71f7857e7835eb677955c00cc0aefcd0669adaf6"}, + {file = "cffi-1.17.1-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:de2ea4b5833625383e464549fec1bc395c1bdeeb5f25c4a3a82b5a8c756ec22f"}, + {file = "cffi-1.17.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:fc48c783f9c87e60831201f2cce7f3b2e4846bf4d8728eabe54d60700b318a0b"}, + {file = "cffi-1.17.1-cp311-cp311-win32.whl", hash = "sha256:85a950a4ac9c359340d5963966e3e0a94a676bd6245a4b55bc43949eee26a655"}, + {file = "cffi-1.17.1-cp311-cp311-win_amd64.whl", hash = "sha256:caaf0640ef5f5517f49bc275eca1406b0ffa6aa184892812030f04c2abf589a0"}, + {file = "cffi-1.17.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:805b4371bf7197c329fcb3ead37e710d1bca9da5d583f5073b799d5c5bd1eee4"}, + {file = "cffi-1.17.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:733e99bc2df47476e3848417c5a4540522f234dfd4ef3ab7fafdf555b082ec0c"}, + {file = "cffi-1.17.1-cp312-cp312-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1257bdabf294dceb59f5e70c64a3e2f462c30c7ad68092d01bbbfb1c16b1ba36"}, + {file = "cffi-1.17.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:da95af8214998d77a98cc14e3a3bd00aa191526343078b530ceb0bd710fb48a5"}, + {file = "cffi-1.17.1-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d63afe322132c194cf832bfec0dc69a99fb9bb6bbd550f161a49e9e855cc78ff"}, + {file = "cffi-1.17.1-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f79fc4fc25f1c8698ff97788206bb3c2598949bfe0fef03d299eb1b5356ada99"}, + {file = "cffi-1.17.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b62ce867176a75d03a665bad002af8e6d54644fad99a3c70905c543130e39d93"}, + {file = "cffi-1.17.1-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:386c8bf53c502fff58903061338ce4f4950cbdcb23e2902d86c0f722b786bbe3"}, + {file = "cffi-1.17.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:4ceb10419a9adf4460ea14cfd6bc43d08701f0835e979bf821052f1805850fe8"}, + {file = "cffi-1.17.1-cp312-cp312-win32.whl", hash = "sha256:a08d7e755f8ed21095a310a693525137cfe756ce62d066e53f502a83dc550f65"}, + {file = "cffi-1.17.1-cp312-cp312-win_amd64.whl", hash = "sha256:51392eae71afec0d0c8fb1a53b204dbb3bcabcb3c9b807eedf3e1e6ccf2de903"}, + {file = "cffi-1.17.1-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:f3a2b4222ce6b60e2e8b337bb9596923045681d71e5a082783484d845390938e"}, + {file = "cffi-1.17.1-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:0984a4925a435b1da406122d4d7968dd861c1385afe3b45ba82b750f229811e2"}, + {file = "cffi-1.17.1-cp313-cp313-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:d01b12eeeb4427d3110de311e1774046ad344f5b1a7403101878976ecd7a10f3"}, + {file = "cffi-1.17.1-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:706510fe141c86a69c8ddc029c7910003a17353970cff3b904ff0686a5927683"}, + {file = "cffi-1.17.1-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:de55b766c7aa2e2a3092c51e0483d700341182f08e67c63630d5b6f200bb28e5"}, + {file = "cffi-1.17.1-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c59d6e989d07460165cc5ad3c61f9fd8f1b4796eacbd81cee78957842b834af4"}, + {file = "cffi-1.17.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dd398dbc6773384a17fe0d3e7eeb8d1a21c2200473ee6806bb5e6a8e62bb73dd"}, + {file = "cffi-1.17.1-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:3edc8d958eb099c634dace3c7e16560ae474aa3803a5df240542b305d14e14ed"}, + {file = "cffi-1.17.1-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:72e72408cad3d5419375fc87d289076ee319835bdfa2caad331e377589aebba9"}, + {file = "cffi-1.17.1-cp313-cp313-win32.whl", hash = "sha256:e03eab0a8677fa80d646b5ddece1cbeaf556c313dcfac435ba11f107ba117b5d"}, + {file = "cffi-1.17.1-cp313-cp313-win_amd64.whl", hash = "sha256:f6a16c31041f09ead72d69f583767292f750d24913dadacf5756b966aacb3f1a"}, + {file = "cffi-1.17.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:636062ea65bd0195bc012fea9321aca499c0504409f413dc88af450b57ffd03b"}, + {file = "cffi-1.17.1-cp38-cp38-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:c7eac2ef9b63c79431bc4b25f1cd649d7f061a28808cbc6c47b534bd789ef964"}, + {file = "cffi-1.17.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e221cf152cff04059d011ee126477f0d9588303eb57e88923578ace7baad17f9"}, + {file = "cffi-1.17.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:31000ec67d4221a71bd3f67df918b1f88f676f1c3b535a7eb473255fdc0b83fc"}, + {file = "cffi-1.17.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:6f17be4345073b0a7b8ea599688f692ac3ef23ce28e5df79c04de519dbc4912c"}, + {file = "cffi-1.17.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0e2b1fac190ae3ebfe37b979cc1ce69c81f4e4fe5746bb401dca63a9062cdaf1"}, + {file = "cffi-1.17.1-cp38-cp38-win32.whl", hash = "sha256:7596d6620d3fa590f677e9ee430df2958d2d6d6de2feeae5b20e82c00b76fbf8"}, + {file = "cffi-1.17.1-cp38-cp38-win_amd64.whl", hash = "sha256:78122be759c3f8a014ce010908ae03364d00a1f81ab5c7f4a7a5120607ea56e1"}, + {file = "cffi-1.17.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b2ab587605f4ba0bf81dc0cb08a41bd1c0a5906bd59243d56bad7668a6fc6c16"}, + {file = "cffi-1.17.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:28b16024becceed8c6dfbc75629e27788d8a3f9030691a1dbf9821a128b22c36"}, + {file = "cffi-1.17.1-cp39-cp39-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1d599671f396c4723d016dbddb72fe8e0397082b0a77a4fab8028923bec050e8"}, + {file = "cffi-1.17.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ca74b8dbe6e8e8263c0ffd60277de77dcee6c837a3d0881d8c1ead7268c9e576"}, + {file = "cffi-1.17.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f7f5baafcc48261359e14bcd6d9bff6d4b28d9103847c9e136694cb0501aef87"}, + {file = "cffi-1.17.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:98e3969bcff97cae1b2def8ba499ea3d6f31ddfdb7635374834cf89a1a08ecf0"}, + {file = "cffi-1.17.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cdf5ce3acdfd1661132f2a9c19cac174758dc2352bfe37d98aa7512c6b7178b3"}, + {file = "cffi-1.17.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:9755e4345d1ec879e3849e62222a18c7174d65a6a92d5b346b1863912168b595"}, + {file = "cffi-1.17.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:f1e22e8c4419538cb197e4dd60acc919d7696e5ef98ee4da4e01d3f8cfa4cc5a"}, + {file = "cffi-1.17.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:c03e868a0b3bc35839ba98e74211ed2b05d2119be4e8a0f224fba9384f1fe02e"}, + {file = "cffi-1.17.1-cp39-cp39-win32.whl", hash = "sha256:e31ae45bc2e29f6b2abd0de1cc3b9d5205aa847cafaecb8af1476a609a2f6eb7"}, + {file = "cffi-1.17.1-cp39-cp39-win_amd64.whl", hash = "sha256:d016c76bdd850f3c626af19b0542c9677ba156e4ee4fccfdd7848803533ef662"}, + {file = "cffi-1.17.1.tar.gz", hash = "sha256:1c39c6016c32bc48dd54561950ebd6836e1670f2ae46128f67cf49e789c52824"}, ] [package.dependencies] @@ -341,6 +366,20 @@ files = [ {file = "charset_normalizer-3.3.2-py3-none-any.whl", hash = "sha256:3e4d1f6587322d2788836a99c69062fbb091331ec940e02d12d179c1d53e25fc"}, ] +[[package]] +name = "click" +version = "8.1.7" +description = "Composable command line interface toolkit" +optional = false +python-versions = ">=3.7" +files = [ + {file = "click-8.1.7-py3-none-any.whl", hash = "sha256:ae74fb96c20a0277a1d615f1e4d73c8414f5a98db8b799a7931d1582f3390c28"}, + {file = "click-8.1.7.tar.gz", hash = "sha256:ca9853ad459e787e2192211578cc907e7594e294c7ccc834310722b41b9ca6de"}, +] + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + [[package]] name = "colorama" version = "0.4.6" @@ -472,15 +511,72 @@ files = [ {file = "genson-1.2.2.tar.gz", hash = "sha256:8caf69aa10af7aee0e1a1351d1d06801f4696e005f06cedef438635384346a16"}, ] +[[package]] +name = "h11" +version = "0.14.0" +description = "A pure-Python, bring-your-own-I/O implementation of HTTP/1.1" +optional = false +python-versions = ">=3.7" +files = [ + {file = "h11-0.14.0-py3-none-any.whl", hash = "sha256:e3fe4ac4b851c468cc8363d500db52c2ead036020723024a109d37346efaa761"}, + {file = "h11-0.14.0.tar.gz", hash = "sha256:8f19fbbe99e72420ff35c00b27a34cb9937e902a8b810e2c88300c6f0a3b699d"}, +] + +[[package]] +name = "httpcore" +version = "1.0.5" +description = "A minimal low-level HTTP client." +optional = false +python-versions = ">=3.8" +files = [ + {file = "httpcore-1.0.5-py3-none-any.whl", hash = "sha256:421f18bac248b25d310f3cacd198d55b8e6125c107797b609ff9b7a6ba7991b5"}, + {file = "httpcore-1.0.5.tar.gz", hash = "sha256:34a38e2f9291467ee3b44e89dd52615370e152954ba21721378a87b2960f7a61"}, +] + +[package.dependencies] +certifi = "*" +h11 = ">=0.13,<0.15" + +[package.extras] +asyncio = ["anyio (>=4.0,<5.0)"] +http2 = ["h2 (>=3,<5)"] +socks = ["socksio (==1.*)"] +trio = ["trio (>=0.22.0,<0.26.0)"] + +[[package]] +name = "httpx" +version = "0.27.2" +description = "The next generation HTTP client." +optional = false +python-versions = ">=3.8" +files = [ + {file = "httpx-0.27.2-py3-none-any.whl", hash = "sha256:7bb2708e112d8fdd7829cd4243970f0c223274051cb35ee80c03301ee29a3df0"}, + {file = "httpx-0.27.2.tar.gz", hash = "sha256:f7c2be1d2f3c3c3160d441802406b206c2b76f5947b11115e6df10c6c65e66c2"}, +] + +[package.dependencies] +anyio = "*" +certifi = "*" +httpcore = "==1.*" +idna = "*" +sniffio = "*" + +[package.extras] +brotli = ["brotli", "brotlicffi"] +cli = ["click (==8.*)", "pygments (==2.*)", "rich (>=10,<14)"] +http2 = ["h2 (>=3,<5)"] +socks = ["socksio (==1.*)"] +zstd = ["zstandard (>=0.18.0)"] + [[package]] name = "idna" -version = "3.7" +version = "3.8" description = "Internationalized Domain Names in Applications (IDNA)" optional = false -python-versions = ">=3.5" +python-versions = ">=3.6" files = [ - {file = "idna-3.7-py3-none-any.whl", hash = "sha256:82fee1fc78add43492d3a1898bfa6d8a904cc97d8427f683ed8e798d07761aa0"}, - {file = "idna-3.7.tar.gz", hash = "sha256:028ff3aadf0609c1fd278d8ea3089299412a7a8b9bd005dd08b9f8285bcb5cfc"}, + {file = "idna-3.8-py3-none-any.whl", hash = "sha256:050b4e5baadcd44d760cedbd2b8e639f2ff89bbc7a5730fcc662954303377aac"}, + {file = "idna-3.8.tar.gz", hash = "sha256:d838c2c0ed6fced7693d5e8ab8e734d5f8fda53a039c0164afb0b82e771e3603"}, ] [[package]] @@ -525,6 +621,17 @@ MarkupSafe = ">=2.0" [package.extras] i18n = ["Babel (>=2.7)"] +[[package]] +name = "joblib" +version = "1.4.2" +description = "Lightweight pipelining with Python functions" +optional = false +python-versions = ">=3.8" +files = [ + {file = "joblib-1.4.2-py3-none-any.whl", hash = "sha256:06d478d5674cbc267e7496a410ee875abd68e4340feff4490bcb7afb88060ae6"}, + {file = "joblib-1.4.2.tar.gz", hash = "sha256:2382c5816b2636fbd20a09e0f4e9dad4736765fdfb7dca582943b9c1366b3f0e"}, +] + [[package]] name = "jsonpatch" version = "1.33" @@ -606,16 +713,17 @@ extended-testing = ["jinja2 (>=3,<4)"] [[package]] name = "langsmith" -version = "0.1.98" +version = "0.1.117" description = "Client library to connect to the LangSmith LLM Tracing and Evaluation Platform." optional = false python-versions = "<4.0,>=3.8.1" files = [ - {file = "langsmith-0.1.98-py3-none-any.whl", hash = "sha256:f79e8a128652bbcee4606d10acb6236973b5cd7dde76e3741186d3b97b5698e9"}, - {file = "langsmith-0.1.98.tar.gz", hash = "sha256:e07678219a0502e8f26d35294e72127a39d25e32fafd091af5a7bb661e9a6bd1"}, + {file = "langsmith-0.1.117-py3-none-any.whl", hash = "sha256:e936ee9bcf8293b0496df7ba462a3702179fbe51f9dc28744b0fbec0dbf206ae"}, + {file = "langsmith-0.1.117.tar.gz", hash = "sha256:a1b532f49968b9339bcaff9118d141846d52ed3d803f342902e7448edf1d662b"}, ] [package.dependencies] +httpx = ">=0.23.0,<1" orjson = ">=3.9.14,<4.0.0" pydantic = {version = ">=1,<3", markers = "python_full_version < \"3.12.4\""} requests = ">=2,<3" @@ -689,6 +797,76 @@ files = [ {file = "MarkupSafe-2.1.5.tar.gz", hash = "sha256:d283d37a890ba4c1ae73ffadf8046435c76e7bc2247bbb63c00bd1a709c6544b"}, ] +[[package]] +name = "nltk" +version = "3.8.1" +description = "Natural Language Toolkit" +optional = false +python-versions = ">=3.7" +files = [ + {file = "nltk-3.8.1-py3-none-any.whl", hash = "sha256:fd5c9109f976fa86bcadba8f91e47f5e9293bd034474752e92a520f81c93dda5"}, + {file = "nltk-3.8.1.zip", hash = "sha256:1834da3d0682cba4f2cede2f9aad6b0fafb6461ba451db0efb6f9c39798d64d3"}, +] + +[package.dependencies] +click = "*" +joblib = "*" +regex = ">=2021.8.3" +tqdm = "*" + +[package.extras] +all = ["matplotlib", "numpy", "pyparsing", "python-crfsuite", "requests", "scikit-learn", "scipy", "twython"] +corenlp = ["requests"] +machine-learning = ["numpy", "python-crfsuite", "scikit-learn", "scipy"] +plot = ["matplotlib"] +tgrep = ["pyparsing"] +twitter = ["twython"] + +[[package]] +name = "numpy" +version = "1.26.4" +description = "Fundamental package for array computing in Python" +optional = false +python-versions = ">=3.9" +files = [ + {file = "numpy-1.26.4-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:9ff0f4f29c51e2803569d7a51c2304de5554655a60c5d776e35b4a41413830d0"}, + {file = "numpy-1.26.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:2e4ee3380d6de9c9ec04745830fd9e2eccb3e6cf790d39d7b98ffd19b0dd754a"}, + {file = "numpy-1.26.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d209d8969599b27ad20994c8e41936ee0964e6da07478d6c35016bc386b66ad4"}, + {file = "numpy-1.26.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ffa75af20b44f8dba823498024771d5ac50620e6915abac414251bd971b4529f"}, + {file = "numpy-1.26.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:62b8e4b1e28009ef2846b4c7852046736bab361f7aeadeb6a5b89ebec3c7055a"}, + {file = "numpy-1.26.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:a4abb4f9001ad2858e7ac189089c42178fcce737e4169dc61321660f1a96c7d2"}, + {file = "numpy-1.26.4-cp310-cp310-win32.whl", hash = "sha256:bfe25acf8b437eb2a8b2d49d443800a5f18508cd811fea3181723922a8a82b07"}, + {file = "numpy-1.26.4-cp310-cp310-win_amd64.whl", hash = "sha256:b97fe8060236edf3662adfc2c633f56a08ae30560c56310562cb4f95500022d5"}, + {file = "numpy-1.26.4-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:4c66707fabe114439db9068ee468c26bbdf909cac0fb58686a42a24de1760c71"}, + {file = "numpy-1.26.4-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:edd8b5fe47dab091176d21bb6de568acdd906d1887a4584a15a9a96a1dca06ef"}, + {file = "numpy-1.26.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7ab55401287bfec946ced39700c053796e7cc0e3acbef09993a9ad2adba6ca6e"}, + {file = "numpy-1.26.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:666dbfb6ec68962c033a450943ded891bed2d54e6755e35e5835d63f4f6931d5"}, + {file = "numpy-1.26.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:96ff0b2ad353d8f990b63294c8986f1ec3cb19d749234014f4e7eb0112ceba5a"}, + {file = "numpy-1.26.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:60dedbb91afcbfdc9bc0b1f3f402804070deed7392c23eb7a7f07fa857868e8a"}, + {file = "numpy-1.26.4-cp311-cp311-win32.whl", hash = "sha256:1af303d6b2210eb850fcf03064d364652b7120803a0b872f5211f5234b399f20"}, + {file = "numpy-1.26.4-cp311-cp311-win_amd64.whl", hash = "sha256:cd25bcecc4974d09257ffcd1f098ee778f7834c3ad767fe5db785be9a4aa9cb2"}, + {file = "numpy-1.26.4-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:b3ce300f3644fb06443ee2222c2201dd3a89ea6040541412b8fa189341847218"}, + {file = "numpy-1.26.4-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:03a8c78d01d9781b28a6989f6fa1bb2c4f2d51201cf99d3dd875df6fbd96b23b"}, + {file = "numpy-1.26.4-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9fad7dcb1aac3c7f0584a5a8133e3a43eeb2fe127f47e3632d43d677c66c102b"}, + {file = "numpy-1.26.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:675d61ffbfa78604709862923189bad94014bef562cc35cf61d3a07bba02a7ed"}, + {file = "numpy-1.26.4-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:ab47dbe5cc8210f55aa58e4805fe224dac469cde56b9f731a4c098b91917159a"}, + {file = "numpy-1.26.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:1dda2e7b4ec9dd512f84935c5f126c8bd8b9f2fc001e9f54af255e8c5f16b0e0"}, + {file = "numpy-1.26.4-cp312-cp312-win32.whl", hash = "sha256:50193e430acfc1346175fcbdaa28ffec49947a06918b7b92130744e81e640110"}, + {file = "numpy-1.26.4-cp312-cp312-win_amd64.whl", hash = "sha256:08beddf13648eb95f8d867350f6a018a4be2e5ad54c8d8caed89ebca558b2818"}, + {file = "numpy-1.26.4-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:7349ab0fa0c429c82442a27a9673fc802ffdb7c7775fad780226cb234965e53c"}, + {file = "numpy-1.26.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:52b8b60467cd7dd1e9ed082188b4e6bb35aa5cdd01777621a1658910745b90be"}, + {file = "numpy-1.26.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d5241e0a80d808d70546c697135da2c613f30e28251ff8307eb72ba696945764"}, + {file = "numpy-1.26.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f870204a840a60da0b12273ef34f7051e98c3b5961b61b0c2c1be6dfd64fbcd3"}, + {file = "numpy-1.26.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:679b0076f67ecc0138fd2ede3a8fd196dddc2ad3254069bcb9faf9a79b1cebcd"}, + {file = "numpy-1.26.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:47711010ad8555514b434df65f7d7b076bb8261df1ca9bb78f53d3b2db02e95c"}, + {file = "numpy-1.26.4-cp39-cp39-win32.whl", hash = "sha256:a354325ee03388678242a4d7ebcd08b5c727033fcff3b2f536aea978e15ee9e6"}, + {file = "numpy-1.26.4-cp39-cp39-win_amd64.whl", hash = "sha256:3373d5d70a5fe74a2c1bb6d2cfd9609ecf686d47a2d7b1d37a8f3b6bf6003aea"}, + {file = "numpy-1.26.4-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:afedb719a9dcfc7eaf2287b839d8198e06dcd4cb5d276a3df279231138e83d30"}, + {file = "numpy-1.26.4-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:95a7476c59002f2f6c590b9b7b998306fba6a5aa646b1e22ddfeaf8f78c3a29c"}, + {file = "numpy-1.26.4-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:7e50d0a0cc3189f9cb0aeb3a6a6af18c16f59f004b866cd2be1c14b36134a4a0"}, + {file = "numpy-1.26.4.tar.gz", hash = "sha256:2a02aba9ed12e4ac4eb3ea9421c420301a0c6460d9830d74a9df87efa4912010"}, +] + [[package]] name = "orjson" version = "3.10.7" @@ -766,6 +944,77 @@ files = [ {file = "packaging-23.2.tar.gz", hash = "sha256:048fb0e9405036518eaaf48a55953c750c11e1a1b68e0dd1a9d62ed0c092cfc5"}, ] +[[package]] +name = "pandas" +version = "2.2.0" +description = "Powerful data structures for data analysis, time series, and statistics" +optional = false +python-versions = ">=3.9" +files = [ + {file = "pandas-2.2.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:8108ee1712bb4fa2c16981fba7e68b3f6ea330277f5ca34fa8d557e986a11670"}, + {file = "pandas-2.2.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:736da9ad4033aeab51d067fc3bd69a0ba36f5a60f66a527b3d72e2030e63280a"}, + {file = "pandas-2.2.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:38e0b4fc3ddceb56ec8a287313bc22abe17ab0eb184069f08fc6a9352a769b18"}, + {file = "pandas-2.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:20404d2adefe92aed3b38da41d0847a143a09be982a31b85bc7dd565bdba0f4e"}, + {file = "pandas-2.2.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:7ea3ee3f125032bfcade3a4cf85131ed064b4f8dd23e5ce6fa16473e48ebcaf5"}, + {file = "pandas-2.2.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:f9670b3ac00a387620489dfc1bca66db47a787f4e55911f1293063a78b108df1"}, + {file = "pandas-2.2.0-cp310-cp310-win_amd64.whl", hash = "sha256:5a946f210383c7e6d16312d30b238fd508d80d927014f3b33fb5b15c2f895430"}, + {file = "pandas-2.2.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:a1b438fa26b208005c997e78672f1aa8138f67002e833312e6230f3e57fa87d5"}, + {file = "pandas-2.2.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:8ce2fbc8d9bf303ce54a476116165220a1fedf15985b09656b4b4275300e920b"}, + {file = "pandas-2.2.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2707514a7bec41a4ab81f2ccce8b382961a29fbe9492eab1305bb075b2b1ff4f"}, + {file = "pandas-2.2.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:85793cbdc2d5bc32620dc8ffa715423f0c680dacacf55056ba13454a5be5de88"}, + {file = "pandas-2.2.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:cfd6c2491dc821b10c716ad6776e7ab311f7df5d16038d0b7458bc0b67dc10f3"}, + {file = "pandas-2.2.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:a146b9dcacc3123aa2b399df1a284de5f46287a4ab4fbfc237eac98a92ebcb71"}, + {file = "pandas-2.2.0-cp311-cp311-win_amd64.whl", hash = "sha256:fbc1b53c0e1fdf16388c33c3cca160f798d38aea2978004dd3f4d3dec56454c9"}, + {file = "pandas-2.2.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:a41d06f308a024981dcaa6c41f2f2be46a6b186b902c94c2674e8cb5c42985bc"}, + {file = "pandas-2.2.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:159205c99d7a5ce89ecfc37cb08ed179de7783737cea403b295b5eda8e9c56d1"}, + {file = "pandas-2.2.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:eb1e1f3861ea9132b32f2133788f3b14911b68102d562715d71bd0013bc45440"}, + {file = "pandas-2.2.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:761cb99b42a69005dec2b08854fb1d4888fdf7b05db23a8c5a099e4b886a2106"}, + {file = "pandas-2.2.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:a20628faaf444da122b2a64b1e5360cde100ee6283ae8effa0d8745153809a2e"}, + {file = "pandas-2.2.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:f5be5d03ea2073627e7111f61b9f1f0d9625dc3c4d8dda72cc827b0c58a1d042"}, + {file = "pandas-2.2.0-cp312-cp312-win_amd64.whl", hash = "sha256:a626795722d893ed6aacb64d2401d017ddc8a2341b49e0384ab9bf7112bdec30"}, + {file = "pandas-2.2.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:9f66419d4a41132eb7e9a73dcec9486cf5019f52d90dd35547af11bc58f8637d"}, + {file = "pandas-2.2.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:57abcaeda83fb80d447f28ab0cc7b32b13978f6f733875ebd1ed14f8fbc0f4ab"}, + {file = "pandas-2.2.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e60f1f7dba3c2d5ca159e18c46a34e7ca7247a73b5dd1a22b6d59707ed6b899a"}, + {file = "pandas-2.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:eb61dc8567b798b969bcc1fc964788f5a68214d333cade8319c7ab33e2b5d88a"}, + {file = "pandas-2.2.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:52826b5f4ed658fa2b729264d63f6732b8b29949c7fd234510d57c61dbeadfcd"}, + {file = "pandas-2.2.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:bde2bc699dbd80d7bc7f9cab1e23a95c4375de615860ca089f34e7c64f4a8de7"}, + {file = "pandas-2.2.0-cp39-cp39-win_amd64.whl", hash = "sha256:3de918a754bbf2da2381e8a3dcc45eede8cd7775b047b923f9006d5f876802ae"}, + {file = "pandas-2.2.0.tar.gz", hash = "sha256:30b83f7c3eb217fb4d1b494a57a2fda5444f17834f5df2de6b2ffff68dc3c8e2"}, +] + +[package.dependencies] +numpy = [ + {version = ">=1.22.4,<2", markers = "python_version < \"3.11\""}, + {version = ">=1.23.2,<2", markers = "python_version == \"3.11\""}, +] +python-dateutil = ">=2.8.2" +pytz = ">=2020.1" +tzdata = ">=2022.7" + +[package.extras] +all = ["PyQt5 (>=5.15.9)", "SQLAlchemy (>=2.0.0)", "adbc-driver-postgresql (>=0.8.0)", "adbc-driver-sqlite (>=0.8.0)", "beautifulsoup4 (>=4.11.2)", "bottleneck (>=1.3.6)", "dataframe-api-compat (>=0.1.7)", "fastparquet (>=2022.12.0)", "fsspec (>=2022.11.0)", "gcsfs (>=2022.11.0)", "html5lib (>=1.1)", "hypothesis (>=6.46.1)", "jinja2 (>=3.1.2)", "lxml (>=4.9.2)", "matplotlib (>=3.6.3)", "numba (>=0.56.4)", "numexpr (>=2.8.4)", "odfpy (>=1.4.1)", "openpyxl (>=3.1.0)", "pandas-gbq (>=0.19.0)", "psycopg2 (>=2.9.6)", "pyarrow (>=10.0.1)", "pymysql (>=1.0.2)", "pyreadstat (>=1.2.0)", "pytest (>=7.3.2)", "pytest-xdist (>=2.2.0)", "python-calamine (>=0.1.7)", "pyxlsb (>=1.0.10)", "qtpy (>=2.3.0)", "s3fs (>=2022.11.0)", "scipy (>=1.10.0)", "tables (>=3.8.0)", "tabulate (>=0.9.0)", "xarray (>=2022.12.0)", "xlrd (>=2.0.1)", "xlsxwriter (>=3.0.5)", "zstandard (>=0.19.0)"] +aws = ["s3fs (>=2022.11.0)"] +clipboard = ["PyQt5 (>=5.15.9)", "qtpy (>=2.3.0)"] +compression = ["zstandard (>=0.19.0)"] +computation = ["scipy (>=1.10.0)", "xarray (>=2022.12.0)"] +consortium-standard = ["dataframe-api-compat (>=0.1.7)"] +excel = ["odfpy (>=1.4.1)", "openpyxl (>=3.1.0)", "python-calamine (>=0.1.7)", "pyxlsb (>=1.0.10)", "xlrd (>=2.0.1)", "xlsxwriter (>=3.0.5)"] +feather = ["pyarrow (>=10.0.1)"] +fss = ["fsspec (>=2022.11.0)"] +gcp = ["gcsfs (>=2022.11.0)", "pandas-gbq (>=0.19.0)"] +hdf5 = ["tables (>=3.8.0)"] +html = ["beautifulsoup4 (>=4.11.2)", "html5lib (>=1.1)", "lxml (>=4.9.2)"] +mysql = ["SQLAlchemy (>=2.0.0)", "pymysql (>=1.0.2)"] +output-formatting = ["jinja2 (>=3.1.2)", "tabulate (>=0.9.0)"] +parquet = ["pyarrow (>=10.0.1)"] +performance = ["bottleneck (>=1.3.6)", "numba (>=0.56.4)", "numexpr (>=2.8.4)"] +plot = ["matplotlib (>=3.6.3)"] +postgresql = ["SQLAlchemy (>=2.0.0)", "adbc-driver-postgresql (>=0.8.0)", "psycopg2 (>=2.9.6)"] +spss = ["pyreadstat (>=1.2.0)"] +sql-other = ["SQLAlchemy (>=2.0.0)", "adbc-driver-postgresql (>=0.8.0)", "adbc-driver-sqlite (>=0.8.0)"] +test = ["hypothesis (>=6.46.1)", "pytest (>=7.3.2)", "pytest-xdist (>=2.2.0)"] +xml = ["lxml (>=4.9.2)"] + [[package]] name = "pendulum" version = "2.1.2" @@ -802,19 +1051,19 @@ pytzdata = ">=2020.1" [[package]] name = "platformdirs" -version = "4.2.2" +version = "4.3.2" description = "A small Python package for determining appropriate platform-specific dirs, e.g. a `user data dir`." optional = false python-versions = ">=3.8" files = [ - {file = "platformdirs-4.2.2-py3-none-any.whl", hash = "sha256:2d7a1657e36a80ea911db832a8a6ece5ee53d8de21edd5cc5879af6530b1bfee"}, - {file = "platformdirs-4.2.2.tar.gz", hash = "sha256:38b7b51f512eed9e84a22788b4bce1de17c0adb134d6becb09836e37d8654cd3"}, + {file = "platformdirs-4.3.2-py3-none-any.whl", hash = "sha256:eb1c8582560b34ed4ba105009a4badf7f6f85768b30126f351328507b2beb617"}, + {file = "platformdirs-4.3.2.tar.gz", hash = "sha256:9e5e27a08aa095dd127b9f2e764d74254f482fef22b0970773bfba79d091ab8c"}, ] [package.extras] -docs = ["furo (>=2023.9.10)", "proselint (>=0.13)", "sphinx (>=7.2.6)", "sphinx-autodoc-typehints (>=1.25.2)"] -test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=7.4.3)", "pytest-cov (>=4.1)", "pytest-mock (>=3.12)"] -type = ["mypy (>=1.8)"] +docs = ["furo (>=2024.8.6)", "proselint (>=0.14)", "sphinx (>=8.0.2)", "sphinx-autodoc-typehints (>=2.4)"] +test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=8.3.2)", "pytest-cov (>=5)", "pytest-mock (>=3.14)"] +type = ["mypy (>=1.11.2)"] [[package]] name = "pluggy" @@ -831,17 +1080,6 @@ files = [ dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "py" -version = "1.11.0" -description = "library with cross-python path, ini-parsing, io, code, log facilities" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" -files = [ - {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, - {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, -] - [[package]] name = "pycparser" version = "2.22" @@ -855,119 +1093,120 @@ files = [ [[package]] name = "pydantic" -version = "2.8.2" +version = "2.9.1" description = "Data validation using Python type hints" optional = false python-versions = ">=3.8" files = [ - {file = "pydantic-2.8.2-py3-none-any.whl", hash = "sha256:73ee9fddd406dc318b885c7a2eab8a6472b68b8fb5ba8150949fc3db939f23c8"}, - {file = "pydantic-2.8.2.tar.gz", hash = "sha256:6f62c13d067b0755ad1c21a34bdd06c0c12625a22b0fc09c6b149816604f7c2a"}, + {file = "pydantic-2.9.1-py3-none-any.whl", hash = "sha256:7aff4db5fdf3cf573d4b3c30926a510a10e19a0774d38fc4967f78beb6deb612"}, + {file = "pydantic-2.9.1.tar.gz", hash = "sha256:1363c7d975c7036df0db2b4a61f2e062fbc0aa5ab5f2772e0ffc7191a4f4bce2"}, ] [package.dependencies] -annotated-types = ">=0.4.0" -pydantic-core = "2.20.1" +annotated-types = ">=0.6.0" +pydantic-core = "2.23.3" typing-extensions = {version = ">=4.6.1", markers = "python_version < \"3.13\""} [package.extras] email = ["email-validator (>=2.0.0)"] +timezone = ["tzdata"] [[package]] name = "pydantic-core" -version = "2.20.1" +version = "2.23.3" description = "Core functionality for Pydantic validation and serialization" optional = false python-versions = ">=3.8" files = [ - {file = "pydantic_core-2.20.1-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:3acae97ffd19bf091c72df4d726d552c473f3576409b2a7ca36b2f535ffff4a3"}, - {file = "pydantic_core-2.20.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:41f4c96227a67a013e7de5ff8f20fb496ce573893b7f4f2707d065907bffdbd6"}, - {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5f239eb799a2081495ea659d8d4a43a8f42cd1fe9ff2e7e436295c38a10c286a"}, - {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:53e431da3fc53360db73eedf6f7124d1076e1b4ee4276b36fb25514544ceb4a3"}, - {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f1f62b2413c3a0e846c3b838b2ecd6c7a19ec6793b2a522745b0869e37ab5bc1"}, - {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5d41e6daee2813ecceea8eda38062d69e280b39df793f5a942fa515b8ed67953"}, - {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3d482efec8b7dc6bfaedc0f166b2ce349df0011f5d2f1f25537ced4cfc34fd98"}, - {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:e93e1a4b4b33daed65d781a57a522ff153dcf748dee70b40c7258c5861e1768a"}, - {file = "pydantic_core-2.20.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:e7c4ea22b6739b162c9ecaaa41d718dfad48a244909fe7ef4b54c0b530effc5a"}, - {file = "pydantic_core-2.20.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:4f2790949cf385d985a31984907fecb3896999329103df4e4983a4a41e13e840"}, - {file = "pydantic_core-2.20.1-cp310-none-win32.whl", hash = "sha256:5e999ba8dd90e93d57410c5e67ebb67ffcaadcea0ad973240fdfd3a135506250"}, - {file = "pydantic_core-2.20.1-cp310-none-win_amd64.whl", hash = "sha256:512ecfbefef6dac7bc5eaaf46177b2de58cdf7acac8793fe033b24ece0b9566c"}, - {file = "pydantic_core-2.20.1-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:d2a8fa9d6d6f891f3deec72f5cc668e6f66b188ab14bb1ab52422fe8e644f312"}, - {file = "pydantic_core-2.20.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:175873691124f3d0da55aeea1d90660a6ea7a3cfea137c38afa0a5ffabe37b88"}, - {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:37eee5b638f0e0dcd18d21f59b679686bbd18917b87db0193ae36f9c23c355fc"}, - {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:25e9185e2d06c16ee438ed39bf62935ec436474a6ac4f9358524220f1b236e43"}, - {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:150906b40ff188a3260cbee25380e7494ee85048584998c1e66df0c7a11c17a6"}, - {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:8ad4aeb3e9a97286573c03df758fc7627aecdd02f1da04516a86dc159bf70121"}, - {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d3f3ed29cd9f978c604708511a1f9c2fdcb6c38b9aae36a51905b8811ee5cbf1"}, - {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:b0dae11d8f5ded51699c74d9548dcc5938e0804cc8298ec0aa0da95c21fff57b"}, - {file = "pydantic_core-2.20.1-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:faa6b09ee09433b87992fb5a2859efd1c264ddc37280d2dd5db502126d0e7f27"}, - {file = "pydantic_core-2.20.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:9dc1b507c12eb0481d071f3c1808f0529ad41dc415d0ca11f7ebfc666e66a18b"}, - {file = "pydantic_core-2.20.1-cp311-none-win32.whl", hash = "sha256:fa2fddcb7107e0d1808086ca306dcade7df60a13a6c347a7acf1ec139aa6789a"}, - {file = "pydantic_core-2.20.1-cp311-none-win_amd64.whl", hash = "sha256:40a783fb7ee353c50bd3853e626f15677ea527ae556429453685ae32280c19c2"}, - {file = "pydantic_core-2.20.1-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:595ba5be69b35777474fa07f80fc260ea71255656191adb22a8c53aba4479231"}, - {file = "pydantic_core-2.20.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:a4f55095ad087474999ee28d3398bae183a66be4823f753cd7d67dd0153427c9"}, - {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f9aa05d09ecf4c75157197f27cdc9cfaeb7c5f15021c6373932bf3e124af029f"}, - {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:e97fdf088d4b31ff4ba35db26d9cc472ac7ef4a2ff2badeabf8d727b3377fc52"}, - {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:bc633a9fe1eb87e250b5c57d389cf28998e4292336926b0b6cdaee353f89a237"}, - {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:d573faf8eb7e6b1cbbcb4f5b247c60ca8be39fe2c674495df0eb4318303137fe"}, - {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:26dc97754b57d2fd00ac2b24dfa341abffc380b823211994c4efac7f13b9e90e"}, - {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:33499e85e739a4b60c9dac710c20a08dc73cb3240c9a0e22325e671b27b70d24"}, - {file = "pydantic_core-2.20.1-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:bebb4d6715c814597f85297c332297c6ce81e29436125ca59d1159b07f423eb1"}, - {file = "pydantic_core-2.20.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:516d9227919612425c8ef1c9b869bbbee249bc91912c8aaffb66116c0b447ebd"}, - {file = "pydantic_core-2.20.1-cp312-none-win32.whl", hash = "sha256:469f29f9093c9d834432034d33f5fe45699e664f12a13bf38c04967ce233d688"}, - {file = "pydantic_core-2.20.1-cp312-none-win_amd64.whl", hash = "sha256:035ede2e16da7281041f0e626459bcae33ed998cca6a0a007a5ebb73414ac72d"}, - {file = "pydantic_core-2.20.1-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:0827505a5c87e8aa285dc31e9ec7f4a17c81a813d45f70b1d9164e03a813a686"}, - {file = "pydantic_core-2.20.1-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:19c0fa39fa154e7e0b7f82f88ef85faa2a4c23cc65aae2f5aea625e3c13c735a"}, - {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4aa223cd1e36b642092c326d694d8bf59b71ddddc94cdb752bbbb1c5c91d833b"}, - {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:c336a6d235522a62fef872c6295a42ecb0c4e1d0f1a3e500fe949415761b8a19"}, - {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:7eb6a0587eded33aeefea9f916899d42b1799b7b14b8f8ff2753c0ac1741edac"}, - {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:70c8daf4faca8da5a6d655f9af86faf6ec2e1768f4b8b9d0226c02f3d6209703"}, - {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e9fa4c9bf273ca41f940bceb86922a7667cd5bf90e95dbb157cbb8441008482c"}, - {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:11b71d67b4725e7e2a9f6e9c0ac1239bbc0c48cce3dc59f98635efc57d6dac83"}, - {file = "pydantic_core-2.20.1-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:270755f15174fb983890c49881e93f8f1b80f0b5e3a3cc1394a255706cabd203"}, - {file = "pydantic_core-2.20.1-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:c81131869240e3e568916ef4c307f8b99583efaa60a8112ef27a366eefba8ef0"}, - {file = "pydantic_core-2.20.1-cp313-none-win32.whl", hash = "sha256:b91ced227c41aa29c672814f50dbb05ec93536abf8f43cd14ec9521ea09afe4e"}, - {file = "pydantic_core-2.20.1-cp313-none-win_amd64.whl", hash = "sha256:65db0f2eefcaad1a3950f498aabb4875c8890438bc80b19362cf633b87a8ab20"}, - {file = "pydantic_core-2.20.1-cp38-cp38-macosx_10_12_x86_64.whl", hash = "sha256:4745f4ac52cc6686390c40eaa01d48b18997cb130833154801a442323cc78f91"}, - {file = "pydantic_core-2.20.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:a8ad4c766d3f33ba8fd692f9aa297c9058970530a32c728a2c4bfd2616d3358b"}, - {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:41e81317dd6a0127cabce83c0c9c3fbecceae981c8391e6f1dec88a77c8a569a"}, - {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:04024d270cf63f586ad41fff13fde4311c4fc13ea74676962c876d9577bcc78f"}, - {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:eaad4ff2de1c3823fddf82f41121bdf453d922e9a238642b1dedb33c4e4f98ad"}, - {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:26ab812fa0c845df815e506be30337e2df27e88399b985d0bb4e3ecfe72df31c"}, - {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3c5ebac750d9d5f2706654c638c041635c385596caf68f81342011ddfa1e5598"}, - {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:2aafc5a503855ea5885559eae883978c9b6d8c8993d67766ee73d82e841300dd"}, - {file = "pydantic_core-2.20.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:4868f6bd7c9d98904b748a2653031fc9c2f85b6237009d475b1008bfaeb0a5aa"}, - {file = "pydantic_core-2.20.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:aa2f457b4af386254372dfa78a2eda2563680d982422641a85f271c859df1987"}, - {file = "pydantic_core-2.20.1-cp38-none-win32.whl", hash = "sha256:225b67a1f6d602de0ce7f6c1c3ae89a4aa25d3de9be857999e9124f15dab486a"}, - {file = "pydantic_core-2.20.1-cp38-none-win_amd64.whl", hash = "sha256:6b507132dcfc0dea440cce23ee2182c0ce7aba7054576efc65634f080dbe9434"}, - {file = "pydantic_core-2.20.1-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:b03f7941783b4c4a26051846dea594628b38f6940a2fdc0df00b221aed39314c"}, - {file = "pydantic_core-2.20.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:1eedfeb6089ed3fad42e81a67755846ad4dcc14d73698c120a82e4ccf0f1f9f6"}, - {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:635fee4e041ab9c479e31edda27fcf966ea9614fff1317e280d99eb3e5ab6fe2"}, - {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77bf3ac639c1ff567ae3b47f8d4cc3dc20f9966a2a6dd2311dcc055d3d04fb8a"}, - {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:7ed1b0132f24beeec5a78b67d9388656d03e6a7c837394f99257e2d55b461611"}, - {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c6514f963b023aeee506678a1cf821fe31159b925c4b76fe2afa94cc70b3222b"}, - {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10d4204d8ca33146e761c79f83cc861df20e7ae9f6487ca290a97702daf56006"}, - {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:2d036c7187b9422ae5b262badb87a20a49eb6c5238b2004e96d4da1231badef1"}, - {file = "pydantic_core-2.20.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:9ebfef07dbe1d93efb94b4700f2d278494e9162565a54f124c404a5656d7ff09"}, - {file = "pydantic_core-2.20.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:6b9d9bb600328a1ce523ab4f454859e9d439150abb0906c5a1983c146580ebab"}, - {file = "pydantic_core-2.20.1-cp39-none-win32.whl", hash = "sha256:784c1214cb6dd1e3b15dd8b91b9a53852aed16671cc3fbe4786f4f1db07089e2"}, - {file = "pydantic_core-2.20.1-cp39-none-win_amd64.whl", hash = "sha256:d2fe69c5434391727efa54b47a1e7986bb0186e72a41b203df8f5b0a19a4f669"}, - {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:a45f84b09ac9c3d35dfcf6a27fd0634d30d183205230a0ebe8373a0e8cfa0906"}, - {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:d02a72df14dfdbaf228424573a07af10637bd490f0901cee872c4f434a735b94"}, - {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d2b27e6af28f07e2f195552b37d7d66b150adbaa39a6d327766ffd695799780f"}, - {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:084659fac3c83fd674596612aeff6041a18402f1e1bc19ca39e417d554468482"}, - {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:242b8feb3c493ab78be289c034a1f659e8826e2233786e36f2893a950a719bb6"}, - {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:38cf1c40a921d05c5edc61a785c0ddb4bed67827069f535d794ce6bcded919fc"}, - {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:e0bbdd76ce9aa5d4209d65f2b27fc6e5ef1312ae6c5333c26db3f5ade53a1e99"}, - {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:254ec27fdb5b1ee60684f91683be95e5133c994cc54e86a0b0963afa25c8f8a6"}, - {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:407653af5617f0757261ae249d3fba09504d7a71ab36ac057c938572d1bc9331"}, - {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:c693e916709c2465b02ca0ad7b387c4f8423d1db7b4649c551f27a529181c5ad"}, - {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5b5ff4911aea936a47d9376fd3ab17e970cc543d1b68921886e7f64bd28308d1"}, - {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:177f55a886d74f1808763976ac4efd29b7ed15c69f4d838bbd74d9d09cf6fa86"}, - {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:964faa8a861d2664f0c7ab0c181af0bea66098b1919439815ca8803ef136fc4e"}, - {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:4dd484681c15e6b9a977c785a345d3e378d72678fd5f1f3c0509608da24f2ac0"}, - {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:f6d6cff3538391e8486a431569b77921adfcdef14eb18fbf19b7c0a5294d4e6a"}, - {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:a6d511cc297ff0883bc3708b465ff82d7560193169a8b93260f74ecb0a5e08a7"}, - {file = "pydantic_core-2.20.1.tar.gz", hash = "sha256:26ca695eeee5f9f1aeeb211ffc12f10bcb6f71e2989988fda61dabd65db878d4"}, + {file = "pydantic_core-2.23.3-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:7f10a5d1b9281392f1bf507d16ac720e78285dfd635b05737c3911637601bae6"}, + {file = "pydantic_core-2.23.3-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:3c09a7885dd33ee8c65266e5aa7fb7e2f23d49d8043f089989726391dd7350c5"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6470b5a1ec4d1c2e9afe928c6cb37eb33381cab99292a708b8cb9aa89e62429b"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:9172d2088e27d9a185ea0a6c8cebe227a9139fd90295221d7d495944d2367700"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:86fc6c762ca7ac8fbbdff80d61b2c59fb6b7d144aa46e2d54d9e1b7b0e780e01"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f0cb80fd5c2df4898693aa841425ea1727b1b6d2167448253077d2a49003e0ed"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:03667cec5daf43ac4995cefa8aaf58f99de036204a37b889c24a80927b629cec"}, + {file = "pydantic_core-2.23.3-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:047531242f8e9c2db733599f1c612925de095e93c9cc0e599e96cf536aaf56ba"}, + {file = "pydantic_core-2.23.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:5499798317fff7f25dbef9347f4451b91ac2a4330c6669821c8202fd354c7bee"}, + {file = "pydantic_core-2.23.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:bbb5e45eab7624440516ee3722a3044b83fff4c0372efe183fd6ba678ff681fe"}, + {file = "pydantic_core-2.23.3-cp310-none-win32.whl", hash = "sha256:8b5b3ed73abb147704a6e9f556d8c5cb078f8c095be4588e669d315e0d11893b"}, + {file = "pydantic_core-2.23.3-cp310-none-win_amd64.whl", hash = "sha256:2b603cde285322758a0279995b5796d64b63060bfbe214b50a3ca23b5cee3e83"}, + {file = "pydantic_core-2.23.3-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:c889fd87e1f1bbeb877c2ee56b63bb297de4636661cc9bbfcf4b34e5e925bc27"}, + {file = "pydantic_core-2.23.3-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:ea85bda3189fb27503af4c45273735bcde3dd31c1ab17d11f37b04877859ef45"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a7f7f72f721223f33d3dc98a791666ebc6a91fa023ce63733709f4894a7dc611"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:2b2b55b0448e9da68f56b696f313949cda1039e8ec7b5d294285335b53104b61"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c24574c7e92e2c56379706b9a3f07c1e0c7f2f87a41b6ee86653100c4ce343e5"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f2b05e6ccbee333a8f4b8f4d7c244fdb7a979e90977ad9c51ea31261e2085ce0"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2c409ce1c219c091e47cb03feb3c4ed8c2b8e004efc940da0166aaee8f9d6c8"}, + {file = "pydantic_core-2.23.3-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:d965e8b325f443ed3196db890d85dfebbb09f7384486a77461347f4adb1fa7f8"}, + {file = "pydantic_core-2.23.3-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:f56af3a420fb1ffaf43ece3ea09c2d27c444e7c40dcb7c6e7cf57aae764f2b48"}, + {file = "pydantic_core-2.23.3-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:5b01a078dd4f9a52494370af21aa52964e0a96d4862ac64ff7cea06e0f12d2c5"}, + {file = "pydantic_core-2.23.3-cp311-none-win32.whl", hash = "sha256:560e32f0df04ac69b3dd818f71339983f6d1f70eb99d4d1f8e9705fb6c34a5c1"}, + {file = "pydantic_core-2.23.3-cp311-none-win_amd64.whl", hash = "sha256:c744fa100fdea0d000d8bcddee95213d2de2e95b9c12be083370b2072333a0fa"}, + {file = "pydantic_core-2.23.3-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:e0ec50663feedf64d21bad0809f5857bac1ce91deded203efc4a84b31b2e4305"}, + {file = "pydantic_core-2.23.3-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:db6e6afcb95edbe6b357786684b71008499836e91f2a4a1e55b840955b341dbb"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:98ccd69edcf49f0875d86942f4418a4e83eb3047f20eb897bffa62a5d419c8fa"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:a678c1ac5c5ec5685af0133262103defb427114e62eafeda12f1357a12140162"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:01491d8b4d8db9f3391d93b0df60701e644ff0894352947f31fff3e52bd5c801"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:fcf31facf2796a2d3b7fe338fe8640aa0166e4e55b4cb108dbfd1058049bf4cb"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7200fd561fb3be06827340da066df4311d0b6b8eb0c2116a110be5245dceb326"}, + {file = "pydantic_core-2.23.3-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:dc1636770a809dee2bd44dd74b89cc80eb41172bcad8af75dd0bc182c2666d4c"}, + {file = "pydantic_core-2.23.3-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:67a5def279309f2e23014b608c4150b0c2d323bd7bccd27ff07b001c12c2415c"}, + {file = "pydantic_core-2.23.3-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:748bdf985014c6dd3e1e4cc3db90f1c3ecc7246ff5a3cd4ddab20c768b2f1dab"}, + {file = "pydantic_core-2.23.3-cp312-none-win32.whl", hash = "sha256:255ec6dcb899c115f1e2a64bc9ebc24cc0e3ab097775755244f77360d1f3c06c"}, + {file = "pydantic_core-2.23.3-cp312-none-win_amd64.whl", hash = "sha256:40b8441be16c1e940abebed83cd006ddb9e3737a279e339dbd6d31578b802f7b"}, + {file = "pydantic_core-2.23.3-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:6daaf5b1ba1369a22c8b050b643250e3e5efc6a78366d323294aee54953a4d5f"}, + {file = "pydantic_core-2.23.3-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:d015e63b985a78a3d4ccffd3bdf22b7c20b3bbd4b8227809b3e8e75bc37f9cb2"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a3fc572d9b5b5cfe13f8e8a6e26271d5d13f80173724b738557a8c7f3a8a3791"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:f6bd91345b5163ee7448bee201ed7dd601ca24f43f439109b0212e296eb5b423"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:fc379c73fd66606628b866f661e8785088afe2adaba78e6bbe80796baf708a63"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:fbdce4b47592f9e296e19ac31667daed8753c8367ebb34b9a9bd89dacaa299c9"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fc3cf31edf405a161a0adad83246568647c54404739b614b1ff43dad2b02e6d5"}, + {file = "pydantic_core-2.23.3-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:8e22b477bf90db71c156f89a55bfe4d25177b81fce4aa09294d9e805eec13855"}, + {file = "pydantic_core-2.23.3-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:0a0137ddf462575d9bce863c4c95bac3493ba8e22f8c28ca94634b4a1d3e2bb4"}, + {file = "pydantic_core-2.23.3-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:203171e48946c3164fe7691fc349c79241ff8f28306abd4cad5f4f75ed80bc8d"}, + {file = "pydantic_core-2.23.3-cp313-none-win32.whl", hash = "sha256:76bdab0de4acb3f119c2a4bff740e0c7dc2e6de7692774620f7452ce11ca76c8"}, + {file = "pydantic_core-2.23.3-cp313-none-win_amd64.whl", hash = "sha256:37ba321ac2a46100c578a92e9a6aa33afe9ec99ffa084424291d84e456f490c1"}, + {file = "pydantic_core-2.23.3-cp38-cp38-macosx_10_12_x86_64.whl", hash = "sha256:d063c6b9fed7d992bcbebfc9133f4c24b7a7f215d6b102f3e082b1117cddb72c"}, + {file = "pydantic_core-2.23.3-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:6cb968da9a0746a0cf521b2b5ef25fc5a0bee9b9a1a8214e0a1cfaea5be7e8a4"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:edbefe079a520c5984e30e1f1f29325054b59534729c25b874a16a5048028d16"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:cbaaf2ef20d282659093913da9d402108203f7cb5955020bd8d1ae5a2325d1c4"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:fb539d7e5dc4aac345846f290cf504d2fd3c1be26ac4e8b5e4c2b688069ff4cf"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:7e6f33503c5495059148cc486867e1d24ca35df5fc064686e631e314d959ad5b"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:04b07490bc2f6f2717b10c3969e1b830f5720b632f8ae2f3b8b1542394c47a8e"}, + {file = "pydantic_core-2.23.3-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:03795b9e8a5d7fda05f3873efc3f59105e2dcff14231680296b87b80bb327295"}, + {file = "pydantic_core-2.23.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:c483dab0f14b8d3f0df0c6c18d70b21b086f74c87ab03c59250dbf6d3c89baba"}, + {file = "pydantic_core-2.23.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8b2682038e255e94baf2c473dca914a7460069171ff5cdd4080be18ab8a7fd6e"}, + {file = "pydantic_core-2.23.3-cp38-none-win32.whl", hash = "sha256:f4a57db8966b3a1d1a350012839c6a0099f0898c56512dfade8a1fe5fb278710"}, + {file = "pydantic_core-2.23.3-cp38-none-win_amd64.whl", hash = "sha256:13dd45ba2561603681a2676ca56006d6dee94493f03d5cadc055d2055615c3ea"}, + {file = "pydantic_core-2.23.3-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:82da2f4703894134a9f000e24965df73cc103e31e8c31906cc1ee89fde72cbd8"}, + {file = "pydantic_core-2.23.3-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:dd9be0a42de08f4b58a3cc73a123f124f65c24698b95a54c1543065baca8cf0e"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:89b731f25c80830c76fdb13705c68fef6a2b6dc494402987c7ea9584fe189f5d"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:c6de1ec30c4bb94f3a69c9f5f2182baeda5b809f806676675e9ef6b8dc936f28"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:bb68b41c3fa64587412b104294b9cbb027509dc2f6958446c502638d481525ef"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1c3980f2843de5184656aab58698011b42763ccba11c4a8c35936c8dd6c7068c"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:94f85614f2cba13f62c3c6481716e4adeae48e1eaa7e8bac379b9d177d93947a"}, + {file = "pydantic_core-2.23.3-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:510b7fb0a86dc8f10a8bb43bd2f97beb63cffad1203071dc434dac26453955cd"}, + {file = "pydantic_core-2.23.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:1eba2f7ce3e30ee2170410e2171867ea73dbd692433b81a93758ab2de6c64835"}, + {file = "pydantic_core-2.23.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:4b259fd8409ab84b4041b7b3f24dcc41e4696f180b775961ca8142b5b21d0e70"}, + {file = "pydantic_core-2.23.3-cp39-none-win32.whl", hash = "sha256:40d9bd259538dba2f40963286009bf7caf18b5112b19d2b55b09c14dde6db6a7"}, + {file = "pydantic_core-2.23.3-cp39-none-win_amd64.whl", hash = "sha256:5a8cd3074a98ee70173a8633ad3c10e00dcb991ecec57263aacb4095c5efb958"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:f399e8657c67313476a121a6944311fab377085ca7f490648c9af97fc732732d"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:6b5547d098c76e1694ba85f05b595720d7c60d342f24d5aad32c3049131fa5c4"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0dda0290a6f608504882d9f7650975b4651ff91c85673341789a476b1159f211"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:65b6e5da855e9c55a0c67f4db8a492bf13d8d3316a59999cfbaf98cc6e401961"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:09e926397f392059ce0afdcac920df29d9c833256354d0c55f1584b0b70cf07e"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:87cfa0ed6b8c5bd6ae8b66de941cece179281239d482f363814d2b986b79cedc"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:e61328920154b6a44d98cabcb709f10e8b74276bc709c9a513a8c37a18786cc4"}, + {file = "pydantic_core-2.23.3-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:ce3317d155628301d649fe5e16a99528d5680af4ec7aa70b90b8dacd2d725c9b"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:e89513f014c6be0d17b00a9a7c81b1c426f4eb9224b15433f3d98c1a071f8433"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:4f62c1c953d7ee375df5eb2e44ad50ce2f5aff931723b398b8bc6f0ac159791a"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2718443bc671c7ac331de4eef9b673063b10af32a0bb385019ad61dcf2cc8f6c"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a0d90e08b2727c5d01af1b5ef4121d2f0c99fbee692c762f4d9d0409c9da6541"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:2b676583fc459c64146debea14ba3af54e540b61762dfc0613dc4e98c3f66eeb"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:50e4661f3337977740fdbfbae084ae5693e505ca2b3130a6d4eb0f2281dc43b8"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:68f4cf373f0de6abfe599a38307f4417c1c867ca381c03df27c873a9069cda25"}, + {file = "pydantic_core-2.23.3-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:59d52cf01854cb26c46958552a21acb10dd78a52aa34c86f284e66b209db8cab"}, + {file = "pydantic_core-2.23.3.tar.gz", hash = "sha256:3cb0f65d8b4121c1b015c60104a685feb929a29d7cf204387c7f2688c7974690"}, ] [package.dependencies] @@ -1048,27 +1287,25 @@ files = [ [[package]] name = "pytest" -version = "6.2.5" +version = "7.4.4" description = "pytest: simple powerful testing with Python" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" files = [ - {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, - {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, + {file = "pytest-7.4.4-py3-none-any.whl", hash = "sha256:b090cdf5ed60bf4c45261be03239c2c1c22df034fbffe691abe93cd80cea01d8"}, + {file = "pytest-7.4.4.tar.gz", hash = "sha256:2cf0005922c6ace4a3e2ec8b4080eb0d9753fdc93107415332f50ce9e7994280"}, ] [package.dependencies] -atomicwrites = {version = ">=1.0", markers = "sys_platform == \"win32\""} -attrs = ">=19.2.0" colorama = {version = "*", markers = "sys_platform == \"win32\""} +exceptiongroup = {version = ">=1.0.0rc8", markers = "python_version < \"3.11\""} iniconfig = "*" packaging = "*" pluggy = ">=0.12,<2.0" -py = ">=1.8.2" -toml = "*" +tomli = {version = ">=1.0.0", markers = "python_version < \"3.11\""} [package.extras] -testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] +testing = ["argcomplete", "attrs (>=19.2.0)", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "setuptools", "xmlschema"] [[package]] name = "pytest-mock" @@ -1185,6 +1422,94 @@ files = [ {file = "pyyaml-6.0.2.tar.gz", hash = "sha256:d584d9ec91ad65861cc08d42e834324ef890a082e591037abe114850ff7bbc3e"}, ] +[[package]] +name = "regex" +version = "2024.7.24" +description = "Alternative regular expression module, to replace re." +optional = false +python-versions = ">=3.8" +files = [ + {file = "regex-2024.7.24-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:228b0d3f567fafa0633aee87f08b9276c7062da9616931382993c03808bb68ce"}, + {file = "regex-2024.7.24-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:3426de3b91d1bc73249042742f45c2148803c111d1175b283270177fdf669024"}, + {file = "regex-2024.7.24-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:f273674b445bcb6e4409bf8d1be67bc4b58e8b46fd0d560055d515b8830063cd"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:23acc72f0f4e1a9e6e9843d6328177ae3074b4182167e34119ec7233dfeccf53"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:65fd3d2e228cae024c411c5ccdffae4c315271eee4a8b839291f84f796b34eca"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c414cbda77dbf13c3bc88b073a1a9f375c7b0cb5e115e15d4b73ec3a2fbc6f59"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bf7a89eef64b5455835f5ed30254ec19bf41f7541cd94f266ab7cbd463f00c41"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:19c65b00d42804e3fbea9708f0937d157e53429a39b7c61253ff15670ff62cb5"}, + {file = "regex-2024.7.24-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7a5486ca56c8869070a966321d5ab416ff0f83f30e0e2da1ab48815c8d165d46"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:6f51f9556785e5a203713f5efd9c085b4a45aecd2a42573e2b5041881b588d1f"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_i686.whl", hash = "sha256:a4997716674d36a82eab3e86f8fa77080a5d8d96a389a61ea1d0e3a94a582cf7"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_ppc64le.whl", hash = "sha256:c0abb5e4e8ce71a61d9446040c1e86d4e6d23f9097275c5bd49ed978755ff0fe"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_s390x.whl", hash = "sha256:18300a1d78cf1290fa583cd8b7cde26ecb73e9f5916690cf9d42de569c89b1ce"}, + {file = "regex-2024.7.24-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:416c0e4f56308f34cdb18c3f59849479dde5b19febdcd6e6fa4d04b6c31c9faa"}, + {file = "regex-2024.7.24-cp310-cp310-win32.whl", hash = "sha256:fb168b5924bef397b5ba13aabd8cf5df7d3d93f10218d7b925e360d436863f66"}, + {file = "regex-2024.7.24-cp310-cp310-win_amd64.whl", hash = "sha256:6b9fc7e9cc983e75e2518496ba1afc524227c163e43d706688a6bb9eca41617e"}, + {file = "regex-2024.7.24-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:382281306e3adaaa7b8b9ebbb3ffb43358a7bbf585fa93821300a418bb975281"}, + {file = "regex-2024.7.24-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:4fdd1384619f406ad9037fe6b6eaa3de2749e2e12084abc80169e8e075377d3b"}, + {file = "regex-2024.7.24-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:3d974d24edb231446f708c455fd08f94c41c1ff4f04bcf06e5f36df5ef50b95a"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a2ec4419a3fe6cf8a4795752596dfe0adb4aea40d3683a132bae9c30b81e8d73"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:eb563dd3aea54c797adf513eeec819c4213d7dbfc311874eb4fd28d10f2ff0f2"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:45104baae8b9f67569f0f1dca5e1f1ed77a54ae1cd8b0b07aba89272710db61e"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:994448ee01864501912abf2bad9203bffc34158e80fe8bfb5b031f4f8e16da51"}, + {file = "regex-2024.7.24-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3fac296f99283ac232d8125be932c5cd7644084a30748fda013028c815ba3364"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:7e37e809b9303ec3a179085415cb5f418ecf65ec98cdfe34f6a078b46ef823ee"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_i686.whl", hash = "sha256:01b689e887f612610c869421241e075c02f2e3d1ae93a037cb14f88ab6a8934c"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_ppc64le.whl", hash = "sha256:f6442f0f0ff81775eaa5b05af8a0ffa1dda36e9cf6ec1e0d3d245e8564b684ce"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_s390x.whl", hash = "sha256:871e3ab2838fbcb4e0865a6e01233975df3a15e6fce93b6f99d75cacbd9862d1"}, + {file = "regex-2024.7.24-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:c918b7a1e26b4ab40409820ddccc5d49871a82329640f5005f73572d5eaa9b5e"}, + {file = "regex-2024.7.24-cp311-cp311-win32.whl", hash = "sha256:2dfbb8baf8ba2c2b9aa2807f44ed272f0913eeeba002478c4577b8d29cde215c"}, + {file = "regex-2024.7.24-cp311-cp311-win_amd64.whl", hash = "sha256:538d30cd96ed7d1416d3956f94d54e426a8daf7c14527f6e0d6d425fcb4cca52"}, + {file = "regex-2024.7.24-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:fe4ebef608553aff8deb845c7f4f1d0740ff76fa672c011cc0bacb2a00fbde86"}, + {file = "regex-2024.7.24-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:74007a5b25b7a678459f06559504f1eec2f0f17bca218c9d56f6a0a12bfffdad"}, + {file = "regex-2024.7.24-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:7df9ea48641da022c2a3c9c641650cd09f0cd15e8908bf931ad538f5ca7919c9"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6a1141a1dcc32904c47f6846b040275c6e5de0bf73f17d7a409035d55b76f289"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:80c811cfcb5c331237d9bad3bea2c391114588cf4131707e84d9493064d267f9"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:7214477bf9bd195894cf24005b1e7b496f46833337b5dedb7b2a6e33f66d962c"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d55588cba7553f0b6ec33130bc3e114b355570b45785cebdc9daed8c637dd440"}, + {file = "regex-2024.7.24-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:558a57cfc32adcf19d3f791f62b5ff564922942e389e3cfdb538a23d65a6b610"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:a512eed9dfd4117110b1881ba9a59b31433caed0c4101b361f768e7bcbaf93c5"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:86b17ba823ea76256b1885652e3a141a99a5c4422f4a869189db328321b73799"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:5eefee9bfe23f6df09ffb6dfb23809f4d74a78acef004aa904dc7c88b9944b05"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:731fcd76bbdbf225e2eb85b7c38da9633ad3073822f5ab32379381e8c3c12e94"}, + {file = "regex-2024.7.24-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:eaef80eac3b4cfbdd6de53c6e108b4c534c21ae055d1dbea2de6b3b8ff3def38"}, + {file = "regex-2024.7.24-cp312-cp312-win32.whl", hash = "sha256:185e029368d6f89f36e526764cf12bf8d6f0e3a2a7737da625a76f594bdfcbfc"}, + {file = "regex-2024.7.24-cp312-cp312-win_amd64.whl", hash = "sha256:2f1baff13cc2521bea83ab2528e7a80cbe0ebb2c6f0bfad15be7da3aed443908"}, + {file = "regex-2024.7.24-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:66b4c0731a5c81921e938dcf1a88e978264e26e6ac4ec96a4d21ae0354581ae0"}, + {file = "regex-2024.7.24-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:88ecc3afd7e776967fa16c80f974cb79399ee8dc6c96423321d6f7d4b881c92b"}, + {file = "regex-2024.7.24-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:64bd50cf16bcc54b274e20235bf8edbb64184a30e1e53873ff8d444e7ac656b2"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:eb462f0e346fcf41a901a126b50f8781e9a474d3927930f3490f38a6e73b6950"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a82465ebbc9b1c5c50738536fdfa7cab639a261a99b469c9d4c7dcbb2b3f1e57"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:68a8f8c046c6466ac61a36b65bb2395c74451df2ffb8458492ef49900efed293"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dac8e84fff5d27420f3c1e879ce9929108e873667ec87e0c8eeb413a5311adfe"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:ba2537ef2163db9e6ccdbeb6f6424282ae4dea43177402152c67ef869cf3978b"}, + {file = "regex-2024.7.24-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:43affe33137fcd679bdae93fb25924979517e011f9dea99163f80b82eadc7e53"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_aarch64.whl", hash = "sha256:c9bb87fdf2ab2370f21e4d5636e5317775e5d51ff32ebff2cf389f71b9b13750"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_i686.whl", hash = "sha256:945352286a541406f99b2655c973852da7911b3f4264e010218bbc1cc73168f2"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_ppc64le.whl", hash = "sha256:8bc593dcce679206b60a538c302d03c29b18e3d862609317cb560e18b66d10cf"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_s390x.whl", hash = "sha256:3f3b6ca8eae6d6c75a6cff525c8530c60e909a71a15e1b731723233331de4169"}, + {file = "regex-2024.7.24-cp38-cp38-musllinux_1_2_x86_64.whl", hash = "sha256:c51edc3541e11fbe83f0c4d9412ef6c79f664a3745fab261457e84465ec9d5a8"}, + {file = "regex-2024.7.24-cp38-cp38-win32.whl", hash = "sha256:d0a07763776188b4db4c9c7fb1b8c494049f84659bb387b71c73bbc07f189e96"}, + {file = "regex-2024.7.24-cp38-cp38-win_amd64.whl", hash = "sha256:8fd5afd101dcf86a270d254364e0e8dddedebe6bd1ab9d5f732f274fa00499a5"}, + {file = "regex-2024.7.24-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:0ffe3f9d430cd37d8fa5632ff6fb36d5b24818c5c986893063b4e5bdb84cdf24"}, + {file = "regex-2024.7.24-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:25419b70ba00a16abc90ee5fce061228206173231f004437730b67ac77323f0d"}, + {file = "regex-2024.7.24-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:33e2614a7ce627f0cdf2ad104797d1f68342d967de3695678c0cb84f530709f8"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d33a0021893ede5969876052796165bab6006559ab845fd7b515a30abdd990dc"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:04ce29e2c5fedf296b1a1b0acc1724ba93a36fb14031f3abfb7abda2806c1535"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b16582783f44fbca6fcf46f61347340c787d7530d88b4d590a397a47583f31dd"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:836d3cc225b3e8a943d0b02633fb2f28a66e281290302a79df0e1eaa984ff7c1"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:438d9f0f4bc64e8dea78274caa5af971ceff0f8771e1a2333620969936ba10be"}, + {file = "regex-2024.7.24-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:973335b1624859cb0e52f96062a28aa18f3a5fc77a96e4a3d6d76e29811a0e6e"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:c5e69fd3eb0b409432b537fe3c6f44ac089c458ab6b78dcec14478422879ec5f"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_i686.whl", hash = "sha256:fbf8c2f00904eaf63ff37718eb13acf8e178cb940520e47b2f05027f5bb34ce3"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_ppc64le.whl", hash = "sha256:ae2757ace61bc4061b69af19e4689fa4416e1a04840f33b441034202b5cd02d4"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_s390x.whl", hash = "sha256:44fc61b99035fd9b3b9453f1713234e5a7c92a04f3577252b45feefe1b327759"}, + {file = "regex-2024.7.24-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:84c312cdf839e8b579f504afcd7b65f35d60b6285d892b19adea16355e8343c9"}, + {file = "regex-2024.7.24-cp39-cp39-win32.whl", hash = "sha256:ca5b2028c2f7af4e13fb9fc29b28d0ce767c38c7facdf64f6c2cd040413055f1"}, + {file = "regex-2024.7.24-cp39-cp39-win_amd64.whl", hash = "sha256:7c479f5ae937ec9985ecaf42e2e10631551d909f203e31308c12d703922742f9"}, + {file = "regex-2024.7.24.tar.gz", hash = "sha256:9cfd009eed1a46b27c14039ad5bbc5e71b6367c5b2e6d5f5da0ea91600817506"}, +] + [[package]] name = "requests" version = "2.32.3" @@ -1253,21 +1578,79 @@ requests = ">=2.22,<3" [package.extras] fixture = ["fixtures"] +[[package]] +name = "serpyco-rs" +version = "1.11.0" +description = "" +optional = false +python-versions = ">=3.9" +files = [ + {file = "serpyco_rs-1.11.0-cp310-cp310-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:4b2bd933539bd8c84315e2fb5ae52ef7a58ace5a6dfe3f8b73f74dc71216779e"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:627f957889ff73c4d2269fc7b6bba93212381befe03633e7cb5495de66ba9a33"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:b0933620abc01434023e0e3e22255b7e4ab9b427b5a9a5ee00834656d792377a"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:9ce46683d92e34abb20304817fc5ac6cb141a06fc7468dedb1d8865a8a9682f6"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:bda437d86e8859bf91c189c1f4650899822f6d6d7b02b48f5729da904eb7bb7d"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5a72bfbd282af17ebe76d122639013e802c09902543fdbbd828fb2159ec9755e"}, + {file = "serpyco_rs-1.11.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4d4808df5384e3e8581e31a90ba7a1fa501c0837b1f174284bb8a4555b6864ea"}, + {file = "serpyco_rs-1.11.0-cp310-none-win_amd64.whl", hash = "sha256:c7b60aef4c16d68efb0d6241f05d0a434d873d98449cbb4366b0d385f0a7172b"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:8d47ee577cf4d69b53917615cb031ad8708eb2f59fe78194b1968c13130fc2f7"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6090d9a1487237cdd4e9362a823eede23249602019b917e7bd57846179286e79"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7192eb3df576386fefd595ea31ae25c62522841ffec7e7aeb37a80b55bdc3213"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:b52ef8affb7e71b9b98a7d5216d6a7ad03b04e990acb147cd9211c8b931c5487"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3480e09e473560c60e74aaa789e6b4d079637371aae0a98235440111464bbba7"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5c92e36b0ab6fe866601c2331f7e99c809a126d21963c03d8a5c29331526deed"}, + {file = "serpyco_rs-1.11.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:84f497361952d4566bc1f77e9e15a84a2614f593cc671fbf0a0fa80046f9c3d7"}, + {file = "serpyco_rs-1.11.0-cp311-none-win_amd64.whl", hash = "sha256:37fc1cf192bef9784fbf1f4e03cec21750b9e704bef55cc0442f71a715eee920"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:3ea93d485f03dc8b0cfb0d477f0ad2e86e78f0461b53010656ab5b4db1b41fb0"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7772410d15694b03f9c5500a2c47d62eed76e191bea4087ad042250346b1a38e"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:42118463c1679846cffd2f06f47744c9b9eb33c5d0448afd88ea19e1a81a8ddd"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:79481a455b76cc56021dc55bb6d5bdda1b2b32bcb6a1ee711b597140d112e9b1"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c8fd79051f9af9591fc03cf7d3033ff180416301f6a4fd3d1e3d92ebd2d68697"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:d29c8f9aeed734a3b51f7349d04ec9063516ffa4e10b632d75e9b1309e4930e4"}, + {file = "serpyco_rs-1.11.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:15609158b0d9591ffa118302cd9d0039970cb3faf91dce32975f7d276e7411d5"}, + {file = "serpyco_rs-1.11.0-cp312-none-win_amd64.whl", hash = "sha256:00081eae77fbf4c5d88371c5586317ab02ccb293a330b460869a283edf2b7b69"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:3028893366a1985adcedb13fa8f6f98c087c185efc427f94c2ccdafa40f45832"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3c18bf511316f3abf648a68ee62ef88617bec57d3fcde69466b4361102715ae5"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:e7dde9ef09cdfaf7c62378186b9e29f54ec76114be4c347be6a06dd559c5681e"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:18500ebc5e75285841e35585a238629a990b709e14f68933233640d15ca17d5f"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f47c23132d4e03982703a7630aa09877b41e499722142f76b6153f6619b612f3"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5f8e6ba499f6a0825bee0d8f8764569d367af871b563fc6512c171474e8e5383"}, + {file = "serpyco_rs-1.11.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:15438a076047c34cff6601a977df54948e8d39d1a86f89d05c48bc60f4c12a61"}, + {file = "serpyco_rs-1.11.0-cp313-none-win_amd64.whl", hash = "sha256:84ee2c109415bd81904fc9abb9aec86a5dd13166808c21142cf23ec639f683bd"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl", hash = "sha256:5c97c16c865261577fac4effeccc7ef5e0a1e8e35e7a3ee6c90c77c3a4cd7ff9"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:47825e70f86fd6ef7c4a835dea3d6e8eef4fee354ed7b39ced99f31aba74a86e"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:24d220220365110edba2f778f41ab3cf396883da0f26e1361a3ada9bd0227f73"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:3a46f334af5a9d77acc6e1e58f355ae497900a2798929371f0545e274f6e6166"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:29d72b748acce4b4e3c7c9724e1eb33d033a1c26b08a698b393e0288060e0901"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e2b8b6f205e8cc038d4d30dd0e70eece7bbecc816eb2f3787c330dc2218e232d"}, + {file = "serpyco_rs-1.11.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:038d748bfff31f150f0c3edab2766b8843edb952cb1bd3bf547886beb0912dae"}, + {file = "serpyco_rs-1.11.0-cp39-none-win_amd64.whl", hash = "sha256:0fee1c89ec2cb013dc232e4ebef88e2844357ce8631063b56639dbfb83762f20"}, + {file = "serpyco_rs-1.11.0.tar.gz", hash = "sha256:70a844615ffb229e6e89c204b3ab7404aacaf2838911814c7d847969b8da2e3a"}, +] + +[package.dependencies] +attributes-doc = "*" +typing-extensions = "*" + [[package]] name = "setuptools" -version = "72.1.0" +version = "74.1.2" description = "Easily download, build, install, upgrade, and uninstall Python packages" optional = false python-versions = ">=3.8" files = [ - {file = "setuptools-72.1.0-py3-none-any.whl", hash = "sha256:5a03e1860cf56bb6ef48ce186b0e557fdba433237481a9a625176c2831be15d1"}, - {file = "setuptools-72.1.0.tar.gz", hash = "sha256:8d243eff56d095e5817f796ede6ae32941278f542e0f941867cc05ae52b162ec"}, + {file = "setuptools-74.1.2-py3-none-any.whl", hash = "sha256:5f4c08aa4d3ebcb57a50c33b1b07e94315d7fc7230f7115e47fc99776c8ce308"}, + {file = "setuptools-74.1.2.tar.gz", hash = "sha256:95b40ed940a1c67eb70fc099094bd6e99c6ee7c23aa2306f4d2697ba7916f9c6"}, ] [package.extras] -core = ["importlib-metadata (>=6)", "importlib-resources (>=5.10.2)", "jaraco.text (>=3.7)", "more-itertools (>=8.8)", "ordered-set (>=3.1.1)", "packaging (>=24)", "platformdirs (>=2.6.2)", "tomli (>=2.0.1)", "wheel (>=0.43.0)"] -doc = ["furo", "jaraco.packaging (>=9.3)", "jaraco.tidelift (>=1.4)", "pygments-github-lexers (==0.0.5)", "pyproject-hooks (!=1.1)", "rst.linker (>=1.9)", "sphinx (>=3.5)", "sphinx-favicon", "sphinx-inline-tabs", "sphinx-lint", "sphinx-notfound-page (>=1,<2)", "sphinx-reredirects", "sphinxcontrib-towncrier"] -test = ["build[virtualenv] (>=1.0.3)", "filelock (>=3.4.0)", "importlib-metadata", "ini2toml[lite] (>=0.14)", "jaraco.develop (>=7.21)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "jaraco.test", "mypy (==1.11.*)", "packaging (>=23.2)", "pip (>=19.1)", "pyproject-hooks (!=1.1)", "pytest (>=6,!=8.1.*)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=2.2)", "pytest-home (>=0.5)", "pytest-mypy", "pytest-perf", "pytest-ruff (<0.4)", "pytest-ruff (>=0.2.1)", "pytest-ruff (>=0.3.2)", "pytest-subprocess", "pytest-timeout", "pytest-xdist (>=3)", "tomli", "tomli-w (>=1.0.0)", "virtualenv (>=13.0.0)", "wheel"] +check = ["pytest-checkdocs (>=2.4)", "pytest-ruff (>=0.2.1)", "ruff (>=0.5.2)"] +core = ["importlib-metadata (>=6)", "importlib-resources (>=5.10.2)", "jaraco.text (>=3.7)", "more-itertools (>=8.8)", "packaging (>=24)", "platformdirs (>=2.6.2)", "tomli (>=2.0.1)", "wheel (>=0.43.0)"] +cover = ["pytest-cov"] +doc = ["furo", "jaraco.packaging (>=9.3)", "jaraco.tidelift (>=1.4)", "pygments-github-lexers (==0.0.5)", "pyproject-hooks (!=1.1)", "rst.linker (>=1.9)", "sphinx (>=3.5)", "sphinx-favicon", "sphinx-inline-tabs", "sphinx-lint", "sphinx-notfound-page (>=1,<2)", "sphinx-reredirects", "sphinxcontrib-towncrier", "towncrier (<24.7)"] +enabler = ["pytest-enabler (>=2.2)"] +test = ["build[virtualenv] (>=1.0.3)", "filelock (>=3.4.0)", "ini2toml[lite] (>=0.14)", "jaraco.develop (>=7.21)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "jaraco.test", "packaging (>=23.2)", "pip (>=19.1)", "pyproject-hooks (!=1.1)", "pytest (>=6,!=8.1.*)", "pytest-home (>=0.5)", "pytest-perf", "pytest-subprocess", "pytest-timeout", "pytest-xdist (>=3)", "tomli-w (>=1.0.0)", "virtualenv (>=13.0.0)", "wheel (>=0.44.0)"] +type = ["importlib-metadata (>=7.0.2)", "jaraco.develop (>=7.21)", "mypy (==1.11.*)", "pytest-mypy"] [[package]] name = "six" @@ -1281,19 +1664,16 @@ files = [ ] [[package]] -name = "stripe" -version = "2.56.0" -description = "Python bindings for the Stripe API" +name = "sniffio" +version = "1.3.1" +description = "Sniff out which async library your code is running under" optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" +python-versions = ">=3.7" files = [ - {file = "stripe-2.56.0-py2.py3-none-any.whl", hash = "sha256:6c685eeadf9e3608315b6d84b4f5f2da2909179b65633ce20f296be22ed21a98"}, - {file = "stripe-2.56.0.tar.gz", hash = "sha256:2ff904fb8dee0d25f135059468a876852d24dc8cbe0b45d7aff56a028045777c"}, + {file = "sniffio-1.3.1-py3-none-any.whl", hash = "sha256:2f6da418d1f1e0fddd844478f41680e794e6051915791a034ff65e5f100525a2"}, + {file = "sniffio-1.3.1.tar.gz", hash = "sha256:f4324edc670a0f49750a81b895f35c3adb843cca46f0530f79fc1babb23789dc"}, ] -[package.dependencies] -requests = {version = ">=2.20", markers = "python_version >= \"3.0\""} - [[package]] name = "tenacity" version = "8.5.0" @@ -1310,16 +1690,36 @@ doc = ["reno", "sphinx"] test = ["pytest", "tornado (>=4.5)", "typeguard"] [[package]] -name = "toml" -version = "0.10.2" -description = "Python Library for Tom's Obvious, Minimal Language" +name = "tomli" +version = "2.0.1" +description = "A lil' TOML parser" +optional = false +python-versions = ">=3.7" +files = [ + {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, + {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, +] + +[[package]] +name = "tqdm" +version = "4.66.5" +description = "Fast, Extensible Progress Meter" optional = false -python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" +python-versions = ">=3.7" files = [ - {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, - {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, + {file = "tqdm-4.66.5-py3-none-any.whl", hash = "sha256:90279a3770753eafc9194a0364852159802111925aa30eb3f9d85b0e805ac7cd"}, + {file = "tqdm-4.66.5.tar.gz", hash = "sha256:e1020aef2e5096702d8a025ac7d16b1577279c9d63f8375b63083e9a5f0fcbad"}, ] +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + +[package.extras] +dev = ["pytest (>=6)", "pytest-cov", "pytest-timeout", "pytest-xdist"] +notebook = ["ipywidgets (>=6)"] +slack = ["slack-sdk"] +telegram = ["requests"] + [[package]] name = "typing-extensions" version = "4.12.2" @@ -1331,6 +1731,17 @@ files = [ {file = "typing_extensions-4.12.2.tar.gz", hash = "sha256:1a7ead55c7e559dd4dee8856e3a88b41225abfe1ce8df57b7c13915fe121ffb8"}, ] +[[package]] +name = "tzdata" +version = "2024.1" +description = "Provider of IANA time zone data" +optional = false +python-versions = ">=2" +files = [ + {file = "tzdata-2024.1-py2.py3-none-any.whl", hash = "sha256:9068bc196136463f5245e51efda838afa15aaeca9903f49050dfa2679db4d252"}, + {file = "tzdata-2024.1.tar.gz", hash = "sha256:2674120f8d891909751c38abcdfd386ac0a5a1127954fbc332af6b5ceae07efd"}, +] + [[package]] name = "url-normalize" version = "1.4.3" @@ -1458,4 +1869,4 @@ files = [ [metadata] lock-version = "2.0" python-versions = "^3.10,<3.12" -content-hash = "8962d733e3e6727e34c89168bdda605394383945fe8ecf98310e64277df9fcc3" +content-hash = "334a517f73db4aea4c610cffcedf31351f20bed130d8e0cbe0c6d1e43d160dae" diff --git a/airbyte-integrations/connectors/source-stripe/pyproject.toml b/airbyte-integrations/connectors/source-stripe/pyproject.toml index 117551f89db3f..87aafe1298f19 100644 --- a/airbyte-integrations/connectors/source-stripe/pyproject.toml +++ b/airbyte-integrations/connectors/source-stripe/pyproject.toml @@ -3,7 +3,7 @@ requires = [ "poetry-core>=1.0.0",] build-backend = "poetry.core.masonry.api" [tool.poetry] -version = "5.5.3" +version = "5.6.0" name = "source-stripe" description = "Source implementation for Stripe." authors = [ "Airbyte ",] @@ -17,15 +17,14 @@ include = "source_stripe" [tool.poetry.dependencies] python = "^3.10,<3.12" -stripe = "==2.56.0" pendulum = "==2.1.2" -airbyte-cdk = "^4" +airbyte-cdk = "^5" [tool.poetry.scripts] source-stripe = "source_stripe.run:run" [tool.poetry.group.dev.dependencies] requests-mock = "^1.11.0" -pytest = "^6.1" freezegun = "==1.2.2" pytest-mock = "^3.6.1" +pytest = "^7" diff --git a/airbyte-integrations/connectors/source-stripe/source_stripe/run.py b/airbyte-integrations/connectors/source-stripe/source_stripe/run.py index b5a3219863590..37263eabb998d 100644 --- a/airbyte-integrations/connectors/source-stripe/source_stripe/run.py +++ b/airbyte-integrations/connectors/source-stripe/source_stripe/run.py @@ -9,7 +9,8 @@ from typing import List from airbyte_cdk.entrypoint import AirbyteEntrypoint, launch -from airbyte_cdk.models import AirbyteErrorTraceMessage, AirbyteMessage, AirbyteTraceMessage, TraceType, Type +from airbyte_cdk.models import AirbyteErrorTraceMessage, AirbyteMessage, AirbyteMessageSerializer, AirbyteTraceMessage, TraceType, Type +from orjson import orjson from source_stripe import SourceStripe @@ -25,17 +26,21 @@ def _get_source(args: List[str]): ) except Exception as error: print( - AirbyteMessage( - type=Type.TRACE, - trace=AirbyteTraceMessage( - type=TraceType.ERROR, - emitted_at=int(datetime.now().timestamp() * 1000), - error=AirbyteErrorTraceMessage( - message=f"Error starting the sync. This could be due to an invalid configuration or catalog. Please contact Support for assistance. Error: {error}", - stack_trace=traceback.format_exc(), - ), - ), - ).json() + orjson.dumps( + AirbyteMessageSerializer.dump( + AirbyteMessage( + type=Type.TRACE, + trace=AirbyteTraceMessage( + type=TraceType.ERROR, + emitted_at=int(datetime.now().timestamp() * 1000), + error=AirbyteErrorTraceMessage( + message=f"Error starting the sync. This could be due to an invalid configuration or catalog. Please contact Support for assistance. Error: {error}", + stack_trace=traceback.format_exc(), + ), + ), + ) + ) + ).decode() ) return None diff --git a/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/openapi_spec.json b/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/openapi_spec.json index b8e90f1cf347d..1b4057c6c3faa 100644 --- a/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/openapi_spec.json +++ b/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/openapi_spec.json @@ -2,7 +2,7 @@ "components": { "schemas": { "account": { - "description": "This is an object representing a Stripe account. You can retrieve it to see\nproperties on the account like its current e-mail address or if the account is\nenabled yet to make live charges.\n\nSome properties, marked below, are available only to platforms that want to\n[create and manage Express or Custom accounts](https://stripe.com/docs/connect/accounts).", + "description": "This is an object representing a Stripe account. You can retrieve it to see\nproperties on the account like its current requirements or if the account is\nenabled to make live charges or receive payouts.\n\nFor accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection)\nis `application`, which includes Custom accounts, the properties below are always\nreturned.\n\nFor accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection)\nis `stripe`, which includes Standard and Express accounts, some properties are only returned\nuntil you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions)\nto start Connect Onboarding. Learn about the [differences between accounts](/connect/accounts).", "properties": { "business_profile": { "anyOf": [ @@ -14,7 +14,7 @@ "nullable": true }, "business_type": { - "description": "The business type.", + "description": "The business type. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property is only returned for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "enum": [ "company", "government_entity", @@ -35,13 +35,16 @@ "company": { "$ref": "#/components/schemas/legal_entity_company" }, + "controller": { + "$ref": "#/components/schemas/account_unification_account_controller" + }, "country": { "description": "The account's country.", "maxLength": 5000, "type": "string" }, "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "description": "Time at which the account was connected. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, @@ -51,17 +54,17 @@ "type": "string" }, "details_submitted": { - "description": "Whether account details have been submitted. Standard accounts cannot receive payouts before this is true.", + "description": "Whether account details have been submitted. Accounts with Stripe Dashboard access, which includes Standard accounts, cannot receive payouts before this is true. Accounts where this is false should be directed to [an onboarding flow](/connect/onboarding) to finish submitting account details.", "type": "boolean" }, "email": { - "description": "An email address associated with the account. You can treat this as metadata: it is not used for authentication or messaging account holders.", + "description": "An email address associated with the account. It's not used for authentication and Stripe doesn't market to this field without explicit approval from the platform.", "maxLength": 5000, "nullable": true, "type": "string" }, "external_accounts": { - "description": "External accounts (bank accounts and debit cards) currently attached to this account", + "description": "External accounts (bank accounts and debit cards) currently attached to this account. External accounts are only returned for requests where `controller[is_controller]` is true.", "properties": { "data": { "description": "The list contains all external accounts that have been attached to the Stripe account. These may be bank accounts or cards.", @@ -74,7 +77,8 @@ "$ref": "#/components/schemas/card" } ], - "title": "Polymorphic" + "title": "Polymorphic", + "x-stripeBypassValidation": true }, "type": "array" }, @@ -98,6 +102,9 @@ "type": "object", "x-expandableFields": ["data"] }, + "future_requirements": { + "$ref": "#/components/schemas/account_future_requirements" + }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, @@ -139,8 +146,8 @@ "$ref": "#/components/schemas/account_tos_acceptance" }, "type": { - "description": "The Stripe account type. Can be `standard`, `express`, or `custom`.", - "enum": ["custom", "express", "standard"], + "description": "The Stripe account type. Can be `standard`, `express`, `custom`, or `none`.", + "enum": ["custom", "express", "none", "standard"], "type": "string" } }, @@ -151,7 +158,9 @@ "business_profile", "capabilities", "company", + "controller", "external_accounts", + "future_requirements", "individual", "requirements", "settings", @@ -159,12 +168,43 @@ ], "x-resourceId": "account" }, + "account_annual_revenue": { + "description": "", + "properties": { + "amount": { + "description": "A non-negative integer representing the amount in the [smallest currency unit](/currencies#zero-decimal).", + "nullable": true, + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "nullable": true, + "type": "string" + }, + "fiscal_year_end": { + "description": "The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "AccountAnnualRevenue", + "type": "object", + "x-expandableFields": [] + }, "account_bacs_debit_payments_settings": { "description": "", "properties": { "display_name": { - "description": "The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this will appear on the mandate, and as the statement descriptor.", + "description": "The Bacs Direct Debit display name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. The fee appears 5 business days after requesting Bacs. If you don't set the display name before requesting Bacs capability, it's automatically set as \"Stripe\" and the account is onboarded to Stripe branding, which is free.", "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "service_user_number": { + "description": "The Bacs Direct Debit Service user number for this account. For payments made with Bacs Direct Debit, this number is a unique identifier of the account with our banking partners.", + "maxLength": 5000, + "nullable": true, "type": "string" } }, @@ -235,12 +275,29 @@ "account_business_profile": { "description": "", "properties": { + "annual_revenue": { + "anyOf": [ + { + "$ref": "#/components/schemas/account_annual_revenue" + } + ], + "description": "The applicant's gross annual revenue for its preceding fiscal year.", + "nullable": true + }, + "estimated_worker_count": { + "description": "An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.", + "nullable": true, + "type": "integer" + }, "mcc": { - "description": "[The merchant category code for the account](https://stripe.com/docs/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.", + "description": "[The merchant category code for the account](/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.", "maxLength": 5000, "nullable": true, "type": "string" }, + "monthly_estimated_revenue": { + "$ref": "#/components/schemas/account_monthly_estimated_revenue" + }, "name": { "description": "The customer-facing business name.", "maxLength": 5000, @@ -289,16 +346,35 @@ }, "title": "AccountBusinessProfile", "type": "object", - "x-expandableFields": ["support_address"] + "x-expandableFields": [ + "annual_revenue", + "monthly_estimated_revenue", + "support_address" + ] }, "account_capabilities": { "description": "", "properties": { + "acss_debit_payments": { + "description": "The status of the Canadian pre-authorized debits payments capability of the account, or whether the account can directly process Canadian pre-authorized debits charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "affirm_payments": { + "description": "The status of the Affirm capability of the account, or whether the account can directly process Affirm charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "afterpay_clearpay_payments": { "description": "The status of the Afterpay Clearpay capability of the account, or whether the account can directly process Afterpay Clearpay charges.", "enum": ["active", "inactive", "pending"], "type": "string" }, + "amazon_pay_payments": { + "description": "The status of the AmazonPay capability of the account, or whether the account can directly process AmazonPay payments.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "au_becs_debit_payments": { "description": "The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges.", "enum": ["active", "inactive", "pending"], @@ -314,6 +390,21 @@ "enum": ["active", "inactive", "pending"], "type": "string" }, + "bank_transfer_payments": { + "description": "The status of the customer_balance payments capability of the account, or whether the account can directly process customer_balance charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "blik_payments": { + "description": "The status of the blik payments capability of the account, or whether the account can directly process blik charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "boleto_payments": { + "description": "The status of the boleto payments capability of the account, or whether the account can directly process boleto charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "card_issuing": { "description": "The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards", "enum": ["active", "inactive", "pending"], @@ -329,6 +420,11 @@ "enum": ["active", "inactive", "pending"], "type": "string" }, + "cashapp_payments": { + "description": "The status of the Cash App Pay capability of the account, or whether the account can directly process Cash App Pay payments.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "eps_payments": { "description": "The status of the EPS payments capability of the account, or whether the account can directly process EPS charges.", "enum": ["active", "inactive", "pending"], @@ -339,6 +435,11 @@ "enum": ["active", "inactive", "pending"], "type": "string" }, + "gb_bank_transfer_payments": { + "description": "The status of the GB customer_balance payments (GBP currency) capability of the account, or whether the account can directly process GB customer_balance charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "giropay_payments": { "description": "The status of the giropay payments capability of the account, or whether the account can directly process giropay charges.", "enum": ["active", "inactive", "pending"], @@ -354,16 +455,56 @@ "enum": ["active", "inactive", "pending"], "type": "string" }, + "india_international_payments": { + "description": "The status of the india_international_payments capability of the account, or whether the account can process international charges (non INR) in India.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "jcb_payments": { "description": "The status of the JCB payments capability of the account, or whether the account (Japan only) can directly process JCB credit card charges in JPY currency.", "enum": ["active", "inactive", "pending"], "type": "string" }, + "jp_bank_transfer_payments": { + "description": "The status of the Japanese customer_balance payments (JPY currency) capability of the account, or whether the account can directly process Japanese customer_balance charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "klarna_payments": { + "description": "The status of the Klarna payments capability of the account, or whether the account can directly process Klarna charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "konbini_payments": { + "description": "The status of the konbini payments capability of the account, or whether the account can directly process konbini charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "legacy_payments": { "description": "The status of the legacy payments capability of the account.", "enum": ["active", "inactive", "pending"], "type": "string" }, + "link_payments": { + "description": "The status of the link_payments capability of the account, or whether the account can directly process Link charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "mobilepay_payments": { + "description": "The status of the MobilePay capability of the account, or whether the account can directly process MobilePay charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "multibanco_payments": { + "description": "The status of the Multibanco payments capability of the account, or whether the account can directly process Multibanco charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "mx_bank_transfer_payments": { + "description": "The status of the Mexican customer_balance payments (MXN currency) capability of the account, or whether the account can directly process Mexican customer_balance charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "oxxo_payments": { "description": "The status of the OXXO payments capability of the account, or whether the account can directly process OXXO charges.", "enum": ["active", "inactive", "pending"], @@ -374,6 +515,26 @@ "enum": ["active", "inactive", "pending"], "type": "string" }, + "paynow_payments": { + "description": "The status of the paynow payments capability of the account, or whether the account can directly process paynow charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "promptpay_payments": { + "description": "The status of the promptpay payments capability of the account, or whether the account can directly process promptpay charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "revolut_pay_payments": { + "description": "The status of the RevolutPay capability of the account, or whether the account can directly process RevolutPay payments.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "sepa_bank_transfer_payments": { + "description": "The status of the SEPA customer_balance payments (EUR currency) capability of the account, or whether the account can directly process SEPA customer_balance charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "sepa_debit_payments": { "description": "The status of the SEPA Direct Debits payments capability of the account, or whether the account can directly process SEPA Direct Debits charges.", "enum": ["active", "inactive", "pending"], @@ -384,6 +545,11 @@ "enum": ["active", "inactive", "pending"], "type": "string" }, + "swish_payments": { + "description": "The status of the Swish capability of the account, or whether the account can directly process Swish payments.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, "tax_reporting_us_1099_k": { "description": "The status of the tax reporting 1099-K (US) capability of the account.", "enum": ["active", "inactive", "pending"], @@ -398,23 +564,141 @@ "description": "The status of the transfers capability of the account, or whether your platform can transfer funds to the account.", "enum": ["active", "inactive", "pending"], "type": "string" + }, + "treasury": { + "description": "The status of the banking capability, or whether the account can have bank accounts.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "twint_payments": { + "description": "The status of the TWINT capability of the account, or whether the account can directly process TWINT charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "us_bank_account_ach_payments": { + "description": "The status of the US bank account ACH payments capability of the account, or whether the account can directly process US bank account charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "us_bank_transfer_payments": { + "description": "The status of the US customer_balance payments (USD currency) capability of the account, or whether the account can directly process US customer_balance charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" + }, + "zip_payments": { + "description": "The status of the Zip capability of the account, or whether the account can directly process Zip charges.", + "enum": ["active", "inactive", "pending"], + "type": "string" } }, "title": "AccountCapabilities", "type": "object", "x-expandableFields": [] }, + "account_capability_future_requirements": { + "description": "", + "properties": { + "alternatives": { + "description": "Fields that are due and can be satisfied by providing the corresponding alternative fields instead.", + "items": { + "$ref": "#/components/schemas/account_requirements_alternative" + }, + "nullable": true, + "type": "array" + }, + "current_deadline": { + "description": "Date on which `future_requirements` merges with the main `requirements` hash and `future_requirements` becomes empty. After the transition, `currently_due` requirements may immediately become `past_due`, but the account may also be given a grace period depending on the capability's enablement state prior to transitioning.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "currently_due": { + "description": "Fields that need to be collected to keep the capability enabled. If not collected by `future_requirements[current_deadline]`, these fields will transition to the main `requirements` hash.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "disabled_reason": { + "description": "This is typed as an enum for consistency with `requirements.disabled_reason`, but it safe to assume `future_requirements.disabled_reason` is null because fields in `future_requirements` will never disable the account.", + "enum": [ + "other", + "paused.inactivity", + "pending.onboarding", + "pending.review", + "platform_disabled", + "platform_paused", + "rejected.inactivity", + "rejected.other", + "rejected.unsupported_business", + "requirements.fields_needed" + ], + "nullable": true, + "type": "string" + }, + "errors": { + "description": "Fields that are `currently_due` and need to be collected again because validation or verification failed.", + "items": { + "$ref": "#/components/schemas/account_requirements_error" + }, + "type": "array" + }, + "eventually_due": { + "description": "Fields that need to be collected assuming all volume thresholds are reached. As they become required, they appear in `currently_due` as well.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "past_due": { + "description": "Fields that weren't collected by `requirements.current_deadline`. These fields need to be collected to enable the capability on the account. New fields will never appear here; `future_requirements.past_due` will always be a subset of `requirements.past_due`.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "pending_verification": { + "description": "Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`. Fields might appear in `eventually_due` or `currently_due` and in `pending_verification` if verification fails but another verification is still pending.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "currently_due", + "errors", + "eventually_due", + "past_due", + "pending_verification" + ], + "title": "AccountCapabilityFutureRequirements", + "type": "object", + "x-expandableFields": ["alternatives", "errors"] + }, "account_capability_requirements": { "description": "", "properties": { + "alternatives": { + "description": "Fields that are due and can be satisfied by providing the corresponding alternative fields instead.", + "items": { + "$ref": "#/components/schemas/account_requirements_alternative" + }, + "nullable": true, + "type": "array" + }, "current_deadline": { - "description": "The date the fields in `currently_due` must be collected by to keep the capability enabled for the account.", + "description": "Date by which the fields in `currently_due` must be collected to keep the capability enabled for the account. These fields may disable the capability sooner if the next threshold is reached before they are collected.", "format": "unix-time", "nullable": true, "type": "integer" }, "currently_due": { - "description": "The fields that need to be collected to keep the capability enabled. If not collected by the `current_deadline`, these fields appear in `past_due` as well, and the capability is disabled.", + "description": "Fields that need to be collected to keep the capability enabled. If not collected by `current_deadline`, these fields appear in `past_due` as well, and the capability is disabled.", "items": { "maxLength": 5000, "type": "string" @@ -422,20 +706,31 @@ "type": "array" }, "disabled_reason": { - "description": "If the capability is disabled, this string describes why. Possible values are `requirement.fields_needed`, `pending.onboarding`, `pending.review`, `rejected_fraud`, `rejected.unsupported_business` or `rejected.other`.\n\n`rejected.unsupported_business` means that the account's business is not supported by the capability. For example, payment methods may restrict the businesses they support in their terms of service:\n\n- [Afterpay Clearpay's terms of service](/afterpay-clearpay/legal#restricted-businesses)\n\nIf you believe that the rejection is in error, please contact support@stripe.com for assistance.", - "maxLength": 5000, + "description": "Description of why the capability is disabled. [Learn more about handling verification issues](https://stripe.com/docs/connect/handling-api-verification).", + "enum": [ + "other", + "paused.inactivity", + "pending.onboarding", + "pending.review", + "platform_disabled", + "platform_paused", + "rejected.inactivity", + "rejected.other", + "rejected.unsupported_business", + "requirements.fields_needed" + ], "nullable": true, "type": "string" }, "errors": { - "description": "The fields that are `currently_due` and need to be collected again because validation or verification failed for some reason.", + "description": "Fields that are `currently_due` and need to be collected again because validation or verification failed.", "items": { "$ref": "#/components/schemas/account_requirements_error" }, "type": "array" }, "eventually_due": { - "description": "The fields that need to be collected assuming all volume thresholds are reached. As they become required, these fields appear in `currently_due` as well, and the `current_deadline` is set.", + "description": "Fields that need to be collected assuming all volume thresholds are reached. As they become required, they appear in `currently_due` as well, and `current_deadline` becomes set.", "items": { "maxLength": 5000, "type": "string" @@ -443,7 +738,7 @@ "type": "array" }, "past_due": { - "description": "The fields that weren't collected by the `current_deadline`. These fields need to be collected to enable the capability for the account.", + "description": "Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the capability on the account.", "items": { "maxLength": 5000, "type": "string" @@ -451,7 +746,7 @@ "type": "array" }, "pending_verification": { - "description": "Fields that may become required depending on the results of verification or review. An empty array unless an asynchronous verification is pending. If verification fails, the fields in this array become required and move to `currently_due` or `past_due`.", + "description": "Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.", "items": { "maxLength": 5000, "type": "string" @@ -468,7 +763,18 @@ ], "title": "AccountCapabilityRequirements", "type": "object", - "x-expandableFields": ["errors"] + "x-expandableFields": ["alternatives", "errors"] + }, + "account_card_issuing_settings": { + "description": "", + "properties": { + "tos_acceptance": { + "$ref": "#/components/schemas/card_issuing_account_terms_of_service" + } + }, + "title": "AccountCardIssuingSettings", + "type": "object", + "x-expandableFields": ["tos_acceptance"] }, "account_card_payments_settings": { "description": "", @@ -481,6 +787,18 @@ "maxLength": 5000, "nullable": true, "type": "string" + }, + "statement_descriptor_prefix_kana": { + "description": "The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "statement_descriptor_prefix_kanji": { + "description": "The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, "title": "AccountCardPaymentsSettings", @@ -524,95 +842,25 @@ "type": "object", "x-expandableFields": [] }, - "account_link": { - "description": "Account Links are the means by which a Connect platform grants a connected account permission to access\nStripe-hosted applications, such as Connect Onboarding.\n\nRelated guide: [Connect Onboarding](https://stripe.com/docs/connect/connect-onboarding).", - "properties": { - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "expires_at": { - "description": "The timestamp at which this account link will expire.", - "format": "unix-time", - "type": "integer" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["account_link"], - "type": "string" - }, - "url": { - "description": "The URL for the account link.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["created", "expires_at", "object", "url"], - "title": "AccountLink", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "account_link" - }, - "account_payments_settings": { + "account_future_requirements": { "description": "", "properties": { - "statement_descriptor": { - "description": "The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "statement_descriptor_kana": { - "description": "The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only)", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "statement_descriptor_kanji": { - "description": "The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only)", - "maxLength": 5000, + "alternatives": { + "description": "Fields that are due and can be satisfied by providing the corresponding alternative fields instead.", + "items": { + "$ref": "#/components/schemas/account_requirements_alternative" + }, "nullable": true, - "type": "string" - } - }, - "title": "AccountPaymentsSettings", - "type": "object", - "x-expandableFields": [] - }, - "account_payout_settings": { - "description": "", - "properties": { - "debit_negative_balances": { - "description": "A Boolean indicating if Stripe should try to reclaim negative balances from an attached bank account. See our [Understanding Connect Account Balances](https://stripe.com/docs/connect/account-balances) documentation for details. Default value is `true` for Express accounts and `false` for Custom accounts.", - "type": "boolean" - }, - "schedule": { - "$ref": "#/components/schemas/transfer_schedule" + "type": "array" }, - "statement_descriptor": { - "description": "The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "required": ["debit_negative_balances", "schedule"], - "title": "AccountPayoutSettings", - "type": "object", - "x-expandableFields": ["schedule"] - }, - "account_requirements": { - "description": "", - "properties": { "current_deadline": { - "description": "The date the fields in `currently_due` must be collected by to keep payouts enabled for the account. These fields might block payouts sooner if the next threshold is reached before these fields are collected.", + "description": "Date on which `future_requirements` merges with the main `requirements` hash and `future_requirements` becomes empty. After the transition, `currently_due` requirements may immediately become `past_due`, but the account may also be given a grace period depending on its enablement state prior to transitioning.", "format": "unix-time", "nullable": true, "type": "integer" }, "currently_due": { - "description": "The fields that need to be collected to keep the account enabled. If not collected by the `current_deadline`, these fields appear in `past_due` as well, and the account is disabled.", + "description": "Fields that need to be collected to keep the account enabled. If not collected by `future_requirements[current_deadline]`, these fields will transition to the main `requirements` hash.", "items": { "maxLength": 5000, "type": "string" @@ -621,13 +869,13 @@ "type": "array" }, "disabled_reason": { - "description": "If the account is disabled, this string describes why the account can’t create charges or receive payouts. Can be `requirements.past_due`, `requirements.pending_verification`, `rejected.fraud`, `rejected.terms_of_service`, `rejected.listed`, `rejected.other`, `listed`, `under_review`, or `other`.", + "description": "This is typed as a string for consistency with `requirements.disabled_reason`.", "maxLength": 5000, "nullable": true, "type": "string" }, "errors": { - "description": "The fields that are `currently_due` and need to be collected again because validation or verification failed for some reason.", + "description": "Fields that are `currently_due` and need to be collected again because validation or verification failed.", "items": { "$ref": "#/components/schemas/account_requirements_error" }, @@ -635,7 +883,7 @@ "type": "array" }, "eventually_due": { - "description": "The fields that need to be collected assuming all volume thresholds are reached. As they become required, these fields appear in `currently_due` as well, and the `current_deadline` is set.", + "description": "Fields that need to be collected assuming all volume thresholds are reached. As they become required, they appear in `currently_due` as well.", "items": { "maxLength": 5000, "type": "string" @@ -644,7 +892,7 @@ "type": "array" }, "past_due": { - "description": "The fields that weren't collected by the `current_deadline`. These fields need to be collected to re-enable the account.", + "description": "Fields that weren't collected by `requirements.current_deadline`. These fields need to be collected to enable the capability on the account. New fields will never appear here; `future_requirements.past_due` will always be a subset of `requirements.past_due`.", "items": { "maxLength": 5000, "type": "string" @@ -653,7 +901,217 @@ "type": "array" }, "pending_verification": { - "description": "Fields that may become required depending on the results of verification or review. An empty array unless an asynchronous verification is pending. If verification fails, the fields in this array become required and move to `currently_due` or `past_due`.", + "description": "Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`. Fields might appear in `eventually_due` or `currently_due` and in `pending_verification` if verification fails but another verification is still pending.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + } + }, + "title": "AccountFutureRequirements", + "type": "object", + "x-expandableFields": ["alternatives", "errors"] + }, + "account_invoices_settings": { + "description": "", + "properties": { + "default_account_tax_ids": { + "description": "The list of default Account Tax IDs to automatically include on invoices. Account Tax IDs get added when an invoice is finalized.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_id" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_id" + } + ] + } + }, + "nullable": true, + "type": "array" + } + }, + "title": "AccountInvoicesSettings", + "type": "object", + "x-expandableFields": ["default_account_tax_ids"] + }, + "account_link": { + "description": "Account Links are the means by which a Connect platform grants a connected account permission to access\nStripe-hosted applications, such as Connect Onboarding.\n\nRelated guide: [Connect Onboarding](https://stripe.com/docs/connect/custom/hosted-onboarding)", + "properties": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "expires_at": { + "description": "The timestamp at which this account link will expire.", + "format": "unix-time", + "type": "integer" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["account_link"], + "type": "string" + }, + "url": { + "description": "The URL for the account link.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["created", "expires_at", "object", "url"], + "title": "AccountLink", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "account_link" + }, + "account_monthly_estimated_revenue": { + "description": "", + "properties": { + "amount": { + "description": "A non-negative integer representing how much to charge in the [smallest currency unit](/currencies#zero-decimal).", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + } + }, + "required": ["amount", "currency"], + "title": "AccountMonthlyEstimatedRevenue", + "type": "object", + "x-expandableFields": [] + }, + "account_payments_settings": { + "description": "", + "properties": { + "statement_descriptor": { + "description": "The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "statement_descriptor_kana": { + "description": "The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "statement_descriptor_kanji": { + "description": "The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "statement_descriptor_prefix_kana": { + "description": "The Kana variation of `statement_descriptor_prefix` used for card charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "statement_descriptor_prefix_kanji": { + "description": "The Kanji variation of `statement_descriptor_prefix` used for card charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "AccountPaymentsSettings", + "type": "object", + "x-expandableFields": [] + }, + "account_payout_settings": { + "description": "", + "properties": { + "debit_negative_balances": { + "description": "A Boolean indicating if Stripe should try to reclaim negative balances from an attached bank account. See [Understanding Connect account balances](/connect/account-balances) for details. The default value is `false` when [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, otherwise `true`.", + "type": "boolean" + }, + "schedule": { + "$ref": "#/components/schemas/transfer_schedule" + }, + "statement_descriptor": { + "description": "The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["debit_negative_balances", "schedule"], + "title": "AccountPayoutSettings", + "type": "object", + "x-expandableFields": ["schedule"] + }, + "account_requirements": { + "description": "", + "properties": { + "alternatives": { + "description": "Fields that are due and can be satisfied by providing the corresponding alternative fields instead.", + "items": { + "$ref": "#/components/schemas/account_requirements_alternative" + }, + "nullable": true, + "type": "array" + }, + "current_deadline": { + "description": "Date by which the fields in `currently_due` must be collected to keep the account enabled. These fields may disable the account sooner if the next threshold is reached before they are collected.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "currently_due": { + "description": "Fields that need to be collected to keep the account enabled. If not collected by `current_deadline`, these fields appear in `past_due` as well, and the account is disabled.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "disabled_reason": { + "description": "If the account is disabled, this string describes why. [Learn more about handling verification issues](https://stripe.com/docs/connect/handling-api-verification). Can be `action_required.requested_capabilities`, `requirements.past_due`, `requirements.pending_verification`, `listed`, `platform_paused`, `rejected.fraud`, `rejected.incomplete_verification`, `rejected.listed`, `rejected.other`, `rejected.terms_of_service`, `under_review`, or `other`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "errors": { + "description": "Fields that are `currently_due` and need to be collected again because validation or verification failed.", + "items": { + "$ref": "#/components/schemas/account_requirements_error" + }, + "nullable": true, + "type": "array" + }, + "eventually_due": { + "description": "Fields that need to be collected assuming all volume thresholds are reached. As they become required, they appear in `currently_due` as well, and `current_deadline` becomes set.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "past_due": { + "description": "Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the account.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "pending_verification": { + "description": "Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.", "items": { "maxLength": 5000, "type": "string" @@ -664,7 +1122,32 @@ }, "title": "AccountRequirements", "type": "object", - "x-expandableFields": ["errors"] + "x-expandableFields": ["alternatives", "errors"] + }, + "account_requirements_alternative": { + "description": "", + "properties": { + "alternative_fields_due": { + "description": "Fields that can be provided to satisfy all fields in `original_fields_due`.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "original_fields_due": { + "description": "Fields that are due and can be satisfied by providing all fields in `alternative_fields_due`.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "required": ["alternative_fields_due", "original_fields_due"], + "title": "AccountRequirementsAlternative", + "type": "object", + "x-expandableFields": [] }, "account_requirements_error": { "description": "", @@ -673,12 +1156,50 @@ "description": "The code for the type of error.", "enum": [ "invalid_address_city_state_postal_code", + "invalid_address_highway_contract_box", + "invalid_address_private_mailbox", + "invalid_business_profile_name", + "invalid_business_profile_name_denylisted", + "invalid_company_name_denylisted", + "invalid_dob_age_over_maximum", + "invalid_dob_age_under_18", + "invalid_dob_age_under_minimum", + "invalid_product_description_length", + "invalid_product_description_url_match", + "invalid_representative_country", + "invalid_statement_descriptor_business_mismatch", + "invalid_statement_descriptor_denylisted", + "invalid_statement_descriptor_length", + "invalid_statement_descriptor_prefix_denylisted", + "invalid_statement_descriptor_prefix_mismatch", "invalid_street_address", + "invalid_tax_id", + "invalid_tax_id_format", + "invalid_tos_acceptance", + "invalid_url_denylisted", + "invalid_url_format", + "invalid_url_web_presence_detected", + "invalid_url_website_business_information_mismatch", + "invalid_url_website_empty", + "invalid_url_website_inaccessible", + "invalid_url_website_inaccessible_geoblocked", + "invalid_url_website_inaccessible_password_protected", + "invalid_url_website_incomplete", + "invalid_url_website_incomplete_cancellation_policy", + "invalid_url_website_incomplete_customer_service_details", + "invalid_url_website_incomplete_legal_restrictions", + "invalid_url_website_incomplete_refund_policy", + "invalid_url_website_incomplete_return_policy", + "invalid_url_website_incomplete_terms_and_conditions", + "invalid_url_website_incomplete_under_construction", + "invalid_url_website_other", "invalid_value_other", + "verification_directors_mismatch", "verification_document_address_mismatch", "verification_document_address_missing", "verification_document_corrupt", "verification_document_country_not_supported", + "verification_document_directors_mismatch", "verification_document_dob_mismatch", "verification_document_duplicate_type", "verification_document_expired", @@ -704,6 +1225,7 @@ "verification_document_photo_mismatch", "verification_document_too_large", "verification_document_type_not_supported", + "verification_extraneous_directors", "verification_failed_address_match", "verification_failed_business_iec_number", "verification_failed_document_match", @@ -712,8 +1234,15 @@ "verification_failed_keyed_match", "verification_failed_name_match", "verification_failed_other", + "verification_failed_representative_authority", + "verification_failed_residential_address", "verification_failed_tax_id_match", - "verification_failed_tax_id_not_issued" + "verification_failed_tax_id_not_issued", + "verification_missing_directors", + "verification_missing_executives", + "verification_missing_owners", + "verification_requires_additional_memorandum_of_associations", + "verification_requires_additional_proof_of_registration" ], "type": "string", "x-stripeBypassValidation": true @@ -747,6 +1276,50 @@ "type": "object", "x-expandableFields": [] }, + "account_session": { + "description": "An AccountSession allows a Connect platform to grant access to a connected account in Connect embedded components.\n\nWe recommend that you create an AccountSession each time you need to display an embedded component\nto your user. Do not save AccountSessions to your database as they expire relatively\nquickly, and cannot be used more than once.\n\nRelated guide: [Connect embedded components](https://stripe.com/docs/connect/get-started-connect-embedded-components)", + "properties": { + "account": { + "description": "The ID of the account the AccountSession was created for", + "maxLength": 5000, + "type": "string" + }, + "client_secret": { + "description": "The client secret of this AccountSession. Used on the client to set up secure access to the given `account`.\n\nThe client secret can be used to provide access to `account` from your frontend. It should not be stored, logged, or exposed to anyone other than the connected account. Make sure that you have TLS enabled on any page that includes the client secret.\n\nRefer to our docs to [setup Connect embedded components](https://stripe.com/docs/connect/get-started-connect-embedded-components) and learn about how `client_secret` should be handled.", + "maxLength": 5000, + "type": "string" + }, + "components": { + "$ref": "#/components/schemas/connect_embedded_account_session_create_components" + }, + "expires_at": { + "description": "The timestamp at which this AccountSession will expire.", + "format": "unix-time", + "type": "integer" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["account_session"], + "type": "string" + } + }, + "required": [ + "account", + "client_secret", + "components", + "expires_at", + "livemode", + "object" + ], + "title": "ConnectEmbeddedMethodAccountSessionCreateMethodAccountSession", + "type": "object", + "x-expandableFields": ["components"], + "x-resourceId": "account_session" + }, "account_settings": { "description": "", "properties": { @@ -756,12 +1329,18 @@ "branding": { "$ref": "#/components/schemas/account_branding_settings" }, + "card_issuing": { + "$ref": "#/components/schemas/account_card_issuing_settings" + }, "card_payments": { "$ref": "#/components/schemas/account_card_payments_settings" }, "dashboard": { "$ref": "#/components/schemas/account_dashboard_settings" }, + "invoices": { + "$ref": "#/components/schemas/account_invoices_settings" + }, "payments": { "$ref": "#/components/schemas/account_payments_settings" }, @@ -770,6 +1349,9 @@ }, "sepa_debit_payments": { "$ref": "#/components/schemas/account_sepa_debit_payments_settings" + }, + "treasury": { + "$ref": "#/components/schemas/account_treasury_settings" } }, "required": ["branding", "card_payments", "dashboard", "payments"], @@ -778,13 +1360,40 @@ "x-expandableFields": [ "bacs_debit_payments", "branding", + "card_issuing", "card_payments", "dashboard", + "invoices", "payments", "payouts", - "sepa_debit_payments" + "sepa_debit_payments", + "treasury" ] }, + "account_terms_of_service": { + "description": "", + "properties": { + "date": { + "description": "The Unix timestamp marking when the account representative accepted the service agreement.", + "nullable": true, + "type": "integer" + }, + "ip": { + "description": "The IP address from which the account representative accepted the service agreement.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "user_agent": { + "description": "The user agent of the browser from which the account representative accepted the service agreement.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "AccountTermsOfService", + "type": "object", + "x-expandableFields": [] + }, "account_tos_acceptance": { "description": "", "properties": { @@ -816,6 +1425,97 @@ "type": "object", "x-expandableFields": [] }, + "account_treasury_settings": { + "description": "", + "properties": { + "tos_acceptance": { + "$ref": "#/components/schemas/account_terms_of_service" + } + }, + "title": "AccountTreasurySettings", + "type": "object", + "x-expandableFields": ["tos_acceptance"] + }, + "account_unification_account_controller": { + "description": "", + "properties": { + "fees": { + "$ref": "#/components/schemas/account_unification_account_controller_fees" + }, + "is_controller": { + "description": "`true` if the Connect application retrieving the resource controls the account and can therefore exercise [platform controls](https://stripe.com/docs/connect/platform-controls-for-standard-accounts). Otherwise, this field is null.", + "type": "boolean" + }, + "losses": { + "$ref": "#/components/schemas/account_unification_account_controller_losses" + }, + "requirement_collection": { + "description": "A value indicating responsibility for collecting requirements on this account. Only returned when the Connect application retrieving the resource controls the account.", + "enum": ["application", "stripe"], + "type": "string" + }, + "stripe_dashboard": { + "$ref": "#/components/schemas/account_unification_account_controller_stripe_dashboard" + }, + "type": { + "description": "The controller type. Can be `application`, if a Connect application controls the account, or `account`, if the account controls itself.", + "enum": ["account", "application"], + "type": "string" + } + }, + "required": ["type"], + "title": "AccountUnificationAccountController", + "type": "object", + "x-expandableFields": ["fees", "losses", "stripe_dashboard"] + }, + "account_unification_account_controller_fees": { + "description": "", + "properties": { + "payer": { + "description": "A value indicating the responsible payer of a bundle of Stripe fees for pricing-control eligible products on this account. Learn more about [fee behavior on connected accounts](https://docs.stripe.com/connect/direct-charges-fee-payer-behavior).", + "enum": [ + "account", + "application", + "application_custom", + "application_express" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["payer"], + "title": "AccountUnificationAccountControllerFees", + "type": "object", + "x-expandableFields": [] + }, + "account_unification_account_controller_losses": { + "description": "", + "properties": { + "payments": { + "description": "A value indicating who is liable when this account can't pay back negative balances from payments.", + "enum": ["application", "stripe"], + "type": "string" + } + }, + "required": ["payments"], + "title": "AccountUnificationAccountControllerLosses", + "type": "object", + "x-expandableFields": [] + }, + "account_unification_account_controller_stripe_dashboard": { + "description": "", + "properties": { + "type": { + "description": "A value indicating the Stripe dashboard this account has access to independent of the Connect application.", + "enum": ["express", "full", "none"], + "type": "string" + } + }, + "required": ["type"], + "title": "AccountUnificationAccountControllerStripeDashboard", + "type": "object", + "x-expandableFields": [] + }, "address": { "description": "", "properties": { @@ -860,106 +1560,6 @@ "type": "object", "x-expandableFields": [] }, - "alipay_account": { - "description": "", - "properties": { - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "customer": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ], - "description": "The ID of the customer associated with this Alipay Account.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ] - } - }, - "fingerprint": { - "description": "Uniquely identifies the account and will be the same across all Alipay account objects that are linked to the same Alipay account.", - "maxLength": 5000, - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["alipay_account"], - "type": "string" - }, - "payment_amount": { - "description": "If the Alipay account object is not reusable, the exact amount that you can create a charge for.", - "nullable": true, - "type": "integer" - }, - "payment_currency": { - "description": "If the Alipay account object is not reusable, the exact currency that you can create a charge for.", - "nullable": true, - "type": "string" - }, - "reusable": { - "description": "True if you can create multiple payments using this account. If the account is reusable, then you can freely choose the amount of each payment.", - "type": "boolean" - }, - "used": { - "description": "Whether this Alipay account object has ever been used for a payment.", - "type": "boolean" - }, - "username": { - "description": "The username for the Alipay account.", - "maxLength": 5000, - "type": "string" - } - }, - "required": [ - "created", - "fingerprint", - "id", - "livemode", - "object", - "reusable", - "used", - "username" - ], - "title": "AlipayAccount", - "type": "object", - "x-expandableFields": ["customer"], - "x-resourceId": "alipay_account" - }, "api_errors": { "description": "", "properties": { @@ -1004,6 +1604,11 @@ "maxLength": 5000, "type": "string" }, + "request_log_url": { + "description": "A URL to the request log entry in your dashboard.", + "maxLength": 5000, + "type": "string" + }, "setup_intent": { "$ref": "#/components/schemas/setup_intent" }, @@ -1019,18 +1624,16 @@ "$ref": "#/components/schemas/source" } ], - "description": "The source object for errors returned on a request involving a source." + "description": "The [source object](https://stripe.com/docs/api/sources/object) for errors returned on a request involving a source.", + "x-stripeBypassValidation": true }, "type": { - "description": "The type of error returned. One of `api_connection_error`, `api_error`, `authentication_error`, `card_error`, `idempotency_error`, `invalid_request_error`, or `rate_limit_error`", + "description": "The type of error returned. One of `api_error`, `card_error`, `idempotency_error`, or `invalid_request_error`", "enum": [ - "api_connection_error", "api_error", - "authentication_error", "card_error", "idempotency_error", - "invalid_request_error", - "rate_limit_error" + "invalid_request_error" ], "type": "string" } @@ -1126,11 +1729,11 @@ } }, "amount": { - "description": "Amount earned, in %s.", + "description": "Amount earned, in cents (or local equivalent).", "type": "integer" }, "amount_refunded": { - "description": "Amount in %s refunded (can be less than the amount attribute on the fee if a partial refund was issued)", + "description": "Amount in cents (or local equivalent) refunded (can be less than the amount attribute on the fee if a partial refund was issued)", "type": "integer" }, "application": { @@ -1200,6 +1803,15 @@ "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, + "fee_source": { + "anyOf": [ + { + "$ref": "#/components/schemas/platform_earning_fee_source" + } + ], + "description": "Polymorphic source of the application fee. Includes the ID of the object the application fee was created from.", + "nullable": true + }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, @@ -1290,32 +1902,114 @@ "application", "balance_transaction", "charge", + "fee_source", "originating_transaction", "refunds" ], "x-resourceId": "application_fee" }, + "apps.secret": { + "description": "Secret Store is an API that allows Stripe Apps developers to securely persist secrets for use by UI Extensions and app backends.\n\nThe primary resource in Secret Store is a `secret`. Other apps can't view secrets created by an app. Additionally, secrets are scoped to provide further permission control.\n\nAll Dashboard users and the app backend share `account` scoped secrets. Use the `account` scope for secrets that don't change per-user, like a third-party API key.\n\nA `user` scoped secret is accessible by the app backend and one specific Dashboard user. Use the `user` scope for per-user secrets like per-user OAuth tokens, where different users might have different permissions.\n\nRelated guide: [Store data between page reloads](https://stripe.com/docs/stripe-apps/store-auth-data-custom-objects)", + "properties": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "deleted": { + "description": "If true, indicates that this secret has been deleted", + "type": "boolean" + }, + "expires_at": { + "description": "The Unix timestamp for the expiry time of the secret, after which the secret deletes.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "name": { + "description": "A name for the secret that's unique within the scope.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["apps.secret"], + "type": "string" + }, + "payload": { + "description": "The plaintext secret value to be stored.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "scope": { + "$ref": "#/components/schemas/secret_service_resource_scope" + } + }, + "required": ["created", "id", "livemode", "name", "object", "scope"], + "title": "SecretServiceResourceSecret", + "type": "object", + "x-expandableFields": ["scope"], + "x-resourceId": "apps.secret" + }, + "automatic_tax": { + "description": "", + "properties": { + "enabled": { + "description": "Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.", + "type": "boolean" + }, + "liability": { + "anyOf": [ + { + "$ref": "#/components/schemas/connect_account_reference" + } + ], + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "nullable": true + }, + "status": { + "description": "The status of the most recent automated tax calculation for this invoice.", + "enum": ["complete", "failed", "requires_location_inputs"], + "nullable": true, + "type": "string" + } + }, + "required": ["enabled"], + "title": "AutomaticTax", + "type": "object", + "x-expandableFields": ["liability"] + }, "balance": { - "description": "This is an object representing your Stripe balance. You can retrieve it to see\nthe balance currently on your Stripe account.\n\nYou can also retrieve the balance history, which contains a list of\n[transactions](https://stripe.com/docs/reporting/balance-transaction-types) that contributed to the balance\n(charges, payouts, and so forth).\n\nThe available and pending amounts for each currency are broken down further by\npayment source types.\n\nRelated guide: [Understanding Connect Account Balances](https://stripe.com/docs/connect/account-balances).", + "description": "This is an object representing your Stripe balance. You can retrieve it to see\nthe balance currently on your Stripe account.\n\nYou can also retrieve the balance history, which contains a list of\n[transactions](https://stripe.com/docs/reporting/balance-transaction-types) that contributed to the balance\n(charges, payouts, and so forth).\n\nThe available and pending amounts for each currency are broken down further by\npayment source types.\n\nRelated guide: [Understanding Connect account balances](https://stripe.com/docs/connect/account-balances)", "properties": { "available": { - "description": "Funds that are available to be transferred or paid out, whether automatically by Stripe or explicitly via the [Transfers API](https://stripe.com/docs/api#transfers) or [Payouts API](https://stripe.com/docs/api#payouts). The available balance for each currency and payment type can be found in the `source_types` property.", + "description": "Available funds that you can transfer or pay out automatically by Stripe or explicitly through the [Transfers API](https://stripe.com/docs/api#transfers) or [Payouts API](https://stripe.com/docs/api#payouts). You can find the available balance for each currency and payment type in the `source_types` property.", "items": { "$ref": "#/components/schemas/balance_amount" }, "type": "array" }, "connect_reserved": { - "description": "Funds held due to negative balances on connected Custom accounts. The connect reserve balance for each currency and payment type can be found in the `source_types` property.", + "description": "Funds held due to negative balances on connected accounts where [account.controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. You can find the connect reserve balance for each currency and payment type in the `source_types` property.", "items": { "$ref": "#/components/schemas/balance_amount" }, "type": "array" }, "instant_available": { - "description": "Funds that can be paid out using Instant Payouts.", + "description": "Funds that you can pay out using Instant Payouts.", "items": { - "$ref": "#/components/schemas/balance_amount" + "$ref": "#/components/schemas/balance_amount_net" }, "type": "array" }, @@ -1332,7 +2026,7 @@ "type": "string" }, "pending": { - "description": "Funds that are not yet available in the balance, due to the 7-day rolling pay cycle. The pending balance for each currency, and for each payment type, can be found in the `source_types` property.", + "description": "Funds that aren't available in the balance yet. You can find the pending balance for each currency and each payment type in the `source_types` property.", "items": { "$ref": "#/components/schemas/balance_amount" }, @@ -1391,6 +2085,33 @@ "type": "object", "x-expandableFields": [] }, + "balance_amount_net": { + "description": "", + "properties": { + "amount": { + "description": "Balance amount.", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "net_available": { + "description": "Breakdown of balance by destination.", + "items": { + "$ref": "#/components/schemas/balance_net_available" + }, + "type": "array" + }, + "source_types": { + "$ref": "#/components/schemas/balance_amount_by_source_type" + } + }, + "required": ["amount", "currency"], + "title": "BalanceAmountNet", + "type": "object", + "x-expandableFields": ["net_available", "source_types"] + }, "balance_detail": { "description": "", "properties": { @@ -1407,15 +2128,36 @@ "type": "object", "x-expandableFields": ["available"] }, + "balance_net_available": { + "description": "", + "properties": { + "amount": { + "description": "Net balance amount, subtracting fees from platform-set pricing.", + "type": "integer" + }, + "destination": { + "description": "ID of the external account for this net balance (not expandable).", + "maxLength": 5000, + "type": "string" + }, + "source_types": { + "$ref": "#/components/schemas/balance_amount_by_source_type" + } + }, + "required": ["amount", "destination"], + "title": "BalanceNetAvailable", + "type": "object", + "x-expandableFields": ["source_types"] + }, "balance_transaction": { - "description": "Balance transactions represent funds moving through your Stripe account.\nThey're created for every type of transaction that comes into or flows out of your Stripe account balance.\n\nRelated guide: [Balance Transaction Types](https://stripe.com/docs/reports/balance-transaction-types).", + "description": "Balance transactions represent funds moving through your Stripe account.\nStripe creates them for every type of transaction that enters or leaves your Stripe account balance.\n\nRelated guide: [Balance transaction types](https://stripe.com/docs/reports/balance-transaction-types)", "properties": { "amount": { - "description": "Gross amount of the transaction, in %s.", + "description": "Gross amount of this transaction (in cents (or local equivalent)). A positive value represents funds charged to another party, and a negative value represents funds sent to another party.", "type": "integer" }, "available_on": { - "description": "The date the transaction's net funds will become available in the Stripe balance.", + "description": "The date that the transaction's net funds become available in the Stripe balance.", "format": "unix-time", "type": "integer" }, @@ -1435,16 +2177,16 @@ "type": "string" }, "exchange_rate": { - "description": "The exchange rate used, if applicable, for this transaction. Specifically, if money was converted from currency A to currency B, then the `amount` in currency A, times `exchange_rate`, would be the `amount` in currency B. For example, suppose you charged a customer 10.00 EUR. Then the PaymentIntent's `amount` would be `1000` and `currency` would be `eur`. Suppose this was converted into 12.34 USD in your Stripe account. Then the BalanceTransaction's `amount` would be `1234`, `currency` would be `usd`, and `exchange_rate` would be `1.234`.", + "description": "If applicable, this transaction uses an exchange rate. If money converts from currency A to currency B, then the `amount` in currency A, multipled by the `exchange_rate`, equals the `amount` in currency B. For example, if you charge a customer 10.00 EUR, the PaymentIntent's `amount` is `1000` and `currency` is `eur`. If this converts to 12.34 USD in your Stripe account, the BalanceTransaction's `amount` is `1234`, its `currency` is `usd`, and the `exchange_rate` is `1.234`.", "nullable": true, "type": "number" }, "fee": { - "description": "Fees (in %s) paid for this transaction.", + "description": "Fees (in cents (or local equivalent)) paid for this transaction. Represented as a positive integer when assessed.", "type": "integer" }, "fee_details": { - "description": "Detailed breakdown of fees (in %s) paid for this transaction.", + "description": "Detailed breakdown of fees (in cents (or local equivalent)) paid for this transaction.", "items": { "$ref": "#/components/schemas/fee" }, @@ -1456,7 +2198,7 @@ "type": "string" }, "net": { - "description": "Net amount of the transaction, in %s.", + "description": "Net impact to a Stripe balance (in cents (or local equivalent)). A positive value represents incrementing a Stripe balance, and a negative value decrementing a Stripe balance. You can calculate the net impact of a transaction on a balance by `amount` - `fee`", "type": "integer" }, "object": { @@ -1465,7 +2207,7 @@ "type": "string" }, "reporting_category": { - "description": "[Learn more](https://stripe.com/docs/reports/reporting-categories) about how reporting categories can help you understand balance transactions from an accounting perspective.", + "description": "Learn more about how [reporting categories](https://stripe.com/docs/reports/reporting-categories) can help you understand balance transactions from an accounting perspective.", "maxLength": 5000, "type": "string" }, @@ -1484,6 +2226,9 @@ { "$ref": "#/components/schemas/connect_collection_transfer" }, + { + "$ref": "#/components/schemas/customer_cash_balance_transaction" + }, { "$ref": "#/components/schemas/dispute" }, @@ -1502,9 +2247,6 @@ { "$ref": "#/components/schemas/payout" }, - { - "$ref": "#/components/schemas/platform_tax_fee" - }, { "$ref": "#/components/schemas/refund" }, @@ -1524,7 +2266,7 @@ "$ref": "#/components/schemas/transfer_reversal" } ], - "description": "The Stripe object to which this transaction is related.", + "description": "This transaction relates to the Stripe object.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -1537,6 +2279,9 @@ { "$ref": "#/components/schemas/connect_collection_transfer" }, + { + "$ref": "#/components/schemas/customer_cash_balance_transaction" + }, { "$ref": "#/components/schemas/dispute" }, @@ -1555,9 +2300,6 @@ { "$ref": "#/components/schemas/payout" }, - { - "$ref": "#/components/schemas/platform_tax_fee" - }, { "$ref": "#/components/schemas/refund" }, @@ -1577,15 +2319,16 @@ "$ref": "#/components/schemas/transfer_reversal" } ] - } + }, + "x-stripeBypassValidation": true }, "status": { - "description": "If the transaction's net funds are available in the Stripe balance yet. Either `available` or `pending`.", + "description": "The transaction's net funds status in the Stripe balance, which are either `available` or `pending`.", "maxLength": 5000, "type": "string" }, "type": { - "description": "Transaction type: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead.", + "description": "Transaction type: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `climate_order_purchase`, `climate_order_refund`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_outbound`, `obligation_reversal_inbound`, `payment`, `payment_failure_refund`, `payment_network_reserve_hold`, `payment_network_reserve_release`, `payment_refund`, `payment_reversal`, `payment_unreconciled`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. Learn more about [balance transaction types and what they represent](https://stripe.com/docs/reports/balance-transaction-types). To classify transactions for accounting purposes, consider `reporting_category` instead.", "enum": [ "adjustment", "advance", @@ -1594,15 +2337,23 @@ "application_fee", "application_fee_refund", "charge", + "climate_order_purchase", + "climate_order_refund", "connect_collection_transfer", "contribution", "issuing_authorization_hold", "issuing_authorization_release", "issuing_dispute", "issuing_transaction", + "obligation_outbound", + "obligation_reversal_inbound", "payment", "payment_failure_refund", + "payment_network_reserve_hold", + "payment_network_reserve_release", "payment_refund", + "payment_reversal", + "payment_unreconciled", "payout", "payout_cancel", "payout_failure", @@ -1643,7 +2394,7 @@ "x-resourceId": "balance_transaction" }, "bank_account": { - "description": "These bank accounts are payment methods on `Customer` objects.\n\nOn the other hand [External Accounts](https://stripe.com/docs/api#external_accounts) are transfer\ndestinations on `Account` objects for [Custom accounts](https://stripe.com/docs/connect/custom-accounts).\nThey can be bank accounts or debit cards as well, and are documented in the links above.\n\nRelated guide: [Bank Debits and Transfers](https://stripe.com/docs/payments/bank-debits-transfers).", + "description": "These bank accounts are payment methods on `Customer` objects.\n\nOn the other hand [External Accounts](/api#external_accounts) are transfer\ndestinations on `Account` objects for connected accounts.\nThey can be bank accounts or debit cards as well, and are documented in the links above.\n\nRelated guide: [Bank debits and transfers](/payments/bank-debits-transfers)", "properties": { "account": { "anyOf": [ @@ -1677,6 +2428,12 @@ "nullable": true, "type": "string" }, + "account_type": { + "description": "The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, "available_payout_methods": { "description": "A set of available payout methods for this bank account. Only values from this set should be passed as the `method` when creating a payout.", "items": { @@ -1738,6 +2495,15 @@ "nullable": true, "type": "string" }, + "future_requirements": { + "anyOf": [ + { + "$ref": "#/components/schemas/external_account_requirements" + } + ], + "description": "Information about the [upcoming new requirements for the bank account](https://stripe.com/docs/connect/custom-accounts/future-requirements), including what information needs to be collected, and by when.", + "nullable": true + }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, @@ -1762,6 +2528,15 @@ "enum": ["bank_account"], "type": "string" }, + "requirements": { + "anyOf": [ + { + "$ref": "#/components/schemas/external_account_requirements" + } + ], + "description": "Information about the requirements for the bank account, including what information needs to be collected.", + "nullable": true + }, "routing_number": { "description": "The routing transit number for the bank account.", "maxLength": 5000, @@ -1769,7 +2544,7 @@ "type": "string" }, "status": { - "description": "For bank accounts, possible values are `new`, `validated`, `verified`, `verification_failed`, or `errored`. A bank account that hasn't had any activity or validation performed is `new`. If Stripe can determine that the bank account exists, its status will be `validated`. Note that there often isn’t enough information to know (e.g., for smaller credit unions), and the validation is not always run. If customer bank account verification has succeeded, the bank account status will be `verified`. If the verification failed for any reason, such as microdeposit failure, the status will be `verification_failed`. If a transfer sent to this bank account fails, we'll set the status to `errored` and will not continue to send transfers until the bank details are updated.\n\nFor external accounts, possible values are `new` and `errored`. Validations aren't run against external accounts because they're only used for payouts. This means the other statuses don't apply. If a transfer fails, the status is set to `errored` and transfers are stopped until account details are updated.", + "description": "For bank accounts, possible values are `new`, `validated`, `verified`, `verification_failed`, or `errored`. A bank account that hasn't had any activity or validation performed is `new`. If Stripe can determine that the bank account exists, its status will be `validated`. Note that there often isn’t enough information to know (e.g., for smaller credit unions), and the validation is not always run. If customer bank account verification has succeeded, the bank account status will be `verified`. If the verification failed for any reason, such as microdeposit failure, the status will be `verification_failed`. If a payout sent to this bank account fails, we'll set the status to `errored` and will not continue to send [scheduled payouts](https://stripe.com/docs/payouts#payout-schedule) until the bank details are updated.\n\nFor external accounts, possible values are `new`, `errored` and `verification_failed`. If a payout fails, the status is set to `errored` and scheduled payouts are stopped until account details are updated. In the US and India, if we can't [verify the owner of the bank account](https://support.stripe.com/questions/bank-account-ownership-verification), we'll set the status to `verification_failed`. Other validations aren't run against external accounts because they're only used for payouts. This means the other statuses don't apply.", "maxLength": 5000, "type": "string" } @@ -1777,145 +2552,278 @@ "required": ["country", "currency", "id", "last4", "object", "status"], "title": "BankAccount", "type": "object", - "x-expandableFields": ["account", "customer"], + "x-expandableFields": [ + "account", + "customer", + "future_requirements", + "requirements" + ], "x-resourceId": "bank_account" }, - "billing_details": { + "bank_connections_resource_accountholder": { "description": "", "properties": { - "address": { + "account": { "anyOf": [ { - "$ref": "#/components/schemas/address" + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" } ], - "description": "Billing address.", - "nullable": true + "description": "The ID of the Stripe account this account belongs to. Should only be present if `account_holder.type` is `account`.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } }, - "email": { - "description": "Email address.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + } + ], + "description": "ID of the Stripe customer this account belongs to. Present if and only if `account_holder.type` is `customer`.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + } + ] + } }, - "name": { - "description": "Full name.", - "maxLength": 5000, - "nullable": true, + "type": { + "description": "Type of account holder that this account belongs to.", + "enum": ["account", "customer"], "type": "string" + } + }, + "required": ["type"], + "title": "BankConnectionsResourceAccountholder", + "type": "object", + "x-expandableFields": ["account", "customer"] + }, + "bank_connections_resource_balance": { + "description": "", + "properties": { + "as_of": { + "description": "The time that the external institution calculated this balance. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" }, - "phone": { - "description": "Billing phone number (including extension).", - "maxLength": 5000, - "nullable": true, + "cash": { + "$ref": "#/components/schemas/bank_connections_resource_balance_api_resource_cash_balance" + }, + "credit": { + "$ref": "#/components/schemas/bank_connections_resource_balance_api_resource_credit_balance" + }, + "current": { + "additionalProperties": { + "type": "integer" + }, + "description": "The balances owed to (or by) the account holder, before subtracting any outbound pending transactions or adding any inbound pending transactions.\n\nEach key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.\n\nEach value is a integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder.", + "type": "object" + }, + "type": { + "description": "The `type` of the balance. An additional hash is included on the balance with a name matching this value.", + "enum": ["cash", "credit"], "type": "string" } }, - "title": "billing_details", + "required": ["as_of", "current", "type"], + "title": "BankConnectionsResourceBalance", "type": "object", - "x-expandableFields": ["address"] + "x-expandableFields": ["cash", "credit"] }, - "billing_portal.configuration": { - "description": "A portal configuration describes the functionality and behavior of a portal session.", + "bank_connections_resource_balance_api_resource_cash_balance": { + "description": "", "properties": { - "active": { - "description": "Whether the configuration is active and can be used to create portal sessions.", - "type": "boolean" + "available": { + "additionalProperties": { + "type": "integer" + }, + "description": "The funds available to the account holder. Typically this is the current balance after subtracting any outbound pending transactions and adding any inbound pending transactions.\n\nEach key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.\n\nEach value is a integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder.", + "nullable": true, + "type": "object" + } + }, + "title": "BankConnectionsResourceBalanceAPIResourceCashBalance", + "type": "object", + "x-expandableFields": [] + }, + "bank_connections_resource_balance_api_resource_credit_balance": { + "description": "", + "properties": { + "used": { + "additionalProperties": { + "type": "integer" + }, + "description": "The credit that has been used by the account holder.\n\nEach key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.\n\nEach value is a integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder.", + "nullable": true, + "type": "object" + } + }, + "title": "BankConnectionsResourceBalanceAPIResourceCreditBalance", + "type": "object", + "x-expandableFields": [] + }, + "bank_connections_resource_balance_refresh": { + "description": "", + "properties": { + "last_attempted_at": { + "description": "The time at which the last refresh attempt was initiated. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" }, - "application": { - "description": "ID of the Connect Application that created the configuration.", - "maxLength": 5000, + "next_refresh_available_at": { + "description": "Time at which the next balance refresh can be initiated. This value will be `null` when `status` is `pending`. Measured in seconds since the Unix epoch.", + "format": "unix-time", "nullable": true, - "type": "string" + "type": "integer" }, - "business_profile": { - "$ref": "#/components/schemas/portal_business_profile" + "status": { + "description": "The status of the last refresh attempt.", + "enum": ["failed", "pending", "succeeded"], + "type": "string" + } + }, + "required": ["last_attempted_at", "status"], + "title": "BankConnectionsResourceBalanceRefresh", + "type": "object", + "x-expandableFields": [] + }, + "bank_connections_resource_link_account_session_filters": { + "description": "", + "properties": { + "account_subcategories": { + "description": "Restricts the Session to subcategories of accounts that can be linked. Valid subcategories are: `checking`, `savings`, `mortgage`, `line_of_credit`, `credit_card`.", + "items": { + "enum": [ + "checking", + "credit_card", + "line_of_credit", + "mortgage", + "savings" + ], + "type": "string" + }, + "nullable": true, + "type": "array" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "countries": { + "description": "List of countries from which to filter accounts.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + } + }, + "title": "BankConnectionsResourceLinkAccountSessionFilters", + "type": "object", + "x-expandableFields": [] + }, + "bank_connections_resource_ownership_refresh": { + "description": "", + "properties": { + "last_attempted_at": { + "description": "The time at which the last refresh attempt was initiated. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, - "default_return_url": { - "description": "The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.", - "maxLength": 5000, + "next_refresh_available_at": { + "description": "Time at which the next ownership refresh can be initiated. This value will be `null` when `status` is `pending`. Measured in seconds since the Unix epoch.", + "format": "unix-time", "nullable": true, - "type": "string" - }, - "features": { - "$ref": "#/components/schemas/portal_features" + "type": "integer" }, + "status": { + "description": "The status of the last refresh attempt.", + "enum": ["failed", "pending", "succeeded"], + "type": "string" + } + }, + "required": ["last_attempted_at", "status"], + "title": "BankConnectionsResourceOwnershipRefresh", + "type": "object", + "x-expandableFields": [] + }, + "bank_connections_resource_transaction_refresh": { + "description": "", + "properties": { "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "is_default": { - "description": "Whether the configuration is the default. If `true`, this configuration can be managed in the Dashboard and portal sessions will use this configuration unless it is overriden when creating the session.", - "type": "boolean" + "last_attempted_at": { + "description": "The time at which the last refresh attempt was initiated. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "next_refresh_available_at": { + "description": "Time at which the next transaction refresh can be initiated. This value will be `null` when `status` is `pending`. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["billing_portal.configuration"], + "status": { + "description": "The status of the last refresh attempt.", + "enum": ["failed", "pending", "succeeded"], "type": "string" + } + }, + "required": ["id", "last_attempted_at", "status"], + "title": "BankConnectionsResourceTransactionRefresh", + "type": "object", + "x-expandableFields": [] + }, + "bank_connections_resource_transaction_resource_status_transitions": { + "description": "", + "properties": { + "posted_at": { + "description": "Time at which this transaction posted. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" }, - "updated": { - "description": "Time at which the object was last updated. Measured in seconds since the Unix epoch.", + "void_at": { + "description": "Time at which this transaction was voided. Measured in seconds since the Unix epoch.", "format": "unix-time", + "nullable": true, "type": "integer" } }, - "required": [ - "active", - "business_profile", - "created", - "features", - "id", - "is_default", - "livemode", - "object", - "updated" - ], - "title": "PortalConfiguration", + "title": "BankConnectionsResourceTransactionResourceStatusTransitions", "type": "object", - "x-expandableFields": ["business_profile", "features"], - "x-resourceId": "billing_portal.configuration" + "x-expandableFields": [] }, - "billing_portal.session": { - "description": "The Billing customer portal is a Stripe-hosted UI for subscription and\nbilling management.\n\nA portal configuration describes the functionality and features that you\nwant to provide to your customers through the portal.\n\nA portal session describes the instantiation of the customer portal for\na particular customer. By visiting the session's URL, the customer\ncan manage their subscriptions and billing details. For security reasons,\nsessions are short-lived and will expire if the customer does not visit the URL.\nCreate sessions on-demand when customers intend to manage their subscriptions\nand billing details.\n\nLearn more in the [product overview](https://stripe.com/docs/billing/subscriptions/customer-portal)\nand [integration guide](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal).", + "billing.alert": { + "description": "A billing alert is a resource that notifies you when a certain usage threshold on a meter is crossed. For example, you might create a billing alert to notify you when a certain user made 100 API requests.", "properties": { - "configuration": { + "alert_type": { + "description": "Defines the type of the alert.", + "enum": ["usage_threshold"], + "type": "string" + }, + "filter": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/billing_portal.configuration" + "$ref": "#/components/schemas/thresholds_resource_alert_filter" } ], - "description": "The configuration used by this session, describing the features available.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/billing_portal.configuration" - } - ] - } - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "customer": { - "description": "The ID of the customer for this session.", - "maxLength": 5000, - "type": "string" + "description": "Limits the scope of the alert to a specific [customer](https://stripe.com/docs/api/customers).", + "nullable": true }, "id": { "description": "Unique identifier for the object.", @@ -1928,481 +2836,470 @@ }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["billing_portal.session"], + "enum": ["billing.alert"], "type": "string" }, - "on_behalf_of": { - "description": "The account for which the session was created on behalf of. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/charges-transfers#on-behalf-of). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.", - "maxLength": 5000, + "status": { + "description": "Status of the alert. This can be active, inactive or archived.", + "enum": ["active", "archived", "inactive"], "nullable": true, "type": "string" }, - "return_url": { - "description": "The URL to redirect customers to when they click on the portal's link to return to your website.", + "title": { + "description": "Title of the alert.", "maxLength": 5000, "type": "string" }, - "url": { - "description": "The short-lived URL of the session that gives customers access to the customer portal.", - "maxLength": 5000, - "type": "string" + "usage_threshold_config": { + "anyOf": [ + { + "$ref": "#/components/schemas/thresholds_resource_usage_threshold_config" + } + ], + "description": "Encapsulates configuration of the alert to monitor usage on a specific [Billing Meter](https://stripe.com/docs/api/billing/meter).", + "nullable": true } }, - "required": [ - "configuration", - "created", - "customer", - "id", - "livemode", - "object", - "return_url", - "url" - ], - "title": "PortalSession", + "required": ["alert_type", "id", "livemode", "object", "title"], + "title": "ThresholdsResourceAlert", "type": "object", - "x-expandableFields": ["configuration"], - "x-resourceId": "billing_portal.session" + "x-expandableFields": ["filter", "usage_threshold_config"], + "x-resourceId": "billing.alert" }, - "bitcoin_receiver": { - "description": "", + "billing.meter": { + "description": "A billing meter is a resource that allows you to track usage of a particular event. For example, you might create a billing meter to track the number of API calls made by a particular user. You can then attach the billing meter to a price and attach the price to a subscription to charge the user for the number of API calls they make.", "properties": { - "active": { - "description": "True when this bitcoin receiver has received a non-zero amount of bitcoin.", - "type": "boolean" - }, - "amount": { - "description": "The amount of `currency` that you are collecting as payment.", - "type": "integer" - }, - "amount_received": { - "description": "The amount of `currency` to which `bitcoin_amount_received` has been converted.", - "type": "integer" - }, - "bitcoin_amount": { - "description": "The amount of bitcoin that the customer should send to fill the receiver. The `bitcoin_amount` is denominated in Satoshi: there are 10^8 Satoshi in one bitcoin.", - "type": "integer" - }, - "bitcoin_amount_received": { - "description": "The amount of bitcoin that has been sent by the customer to this receiver.", - "type": "integer" - }, - "bitcoin_uri": { - "description": "This URI can be displayed to the customer as a clickable link (to activate their bitcoin client) or as a QR code (for mobile wallets).", - "maxLength": 5000, - "type": "string" - }, "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) to which the bitcoin will be converted.", - "type": "string" + "customer_mapping": { + "$ref": "#/components/schemas/billing_meter_resource_customer_mapping_settings" }, - "customer": { - "description": "The customer ID of the bitcoin receiver.", + "default_aggregation": { + "$ref": "#/components/schemas/billing_meter_resource_aggregation_settings" + }, + "display_name": { + "description": "The meter's name.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "event_name": { + "description": "The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "email": { - "description": "The customer's email address, set by the API call that creates the receiver.", - "maxLength": 5000, + "event_time_window": { + "description": "The time window to pre-aggregate meter events for, if any.", + "enum": ["day", "hour"], "nullable": true, "type": "string" }, - "filled": { - "description": "This flag is initially false and updates to true when the customer sends the `bitcoin_amount` to this receiver.", - "type": "boolean" - }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "inbound_address": { - "description": "A bitcoin address that is specific to this receiver. The customer can send bitcoin to this address to fill the receiver.", - "maxLength": 5000, - "type": "string" - }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, - "type": "object" - }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["bitcoin_receiver"], - "type": "string" - }, - "payment": { - "description": "The ID of the payment created from the receiver, if any. Hidden when viewing the receiver with a publishable key.", - "maxLength": 5000, - "nullable": true, + "enum": ["billing.meter"], "type": "string" }, - "refund_address": { - "description": "The refund address of this bitcoin receiver.", - "maxLength": 5000, - "nullable": true, + "status": { + "description": "The meter's status.", + "enum": ["active", "inactive"], "type": "string" }, - "transactions": { - "description": "A list with one entry for each time that the customer sent bitcoin to the receiver. Hidden when viewing the receiver with a publishable key.", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/bitcoin_transaction" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "BitcoinTransactionList", - "type": "object", - "x-expandableFields": ["data"] + "status_transitions": { + "$ref": "#/components/schemas/billing_meter_resource_billing_meter_status_transitions" }, - "uncaptured_funds": { - "description": "This receiver contains uncaptured funds that can be used for a payment or refunded.", - "type": "boolean" + "updated": { + "description": "Time at which the object was last updated. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" }, - "used_for_payment": { - "description": "Indicate if this source is used for payment.", - "nullable": true, - "type": "boolean" + "value_settings": { + "$ref": "#/components/schemas/billing_meter_resource_billing_meter_value" } }, "required": [ - "active", - "amount", - "amount_received", - "bitcoin_amount", - "bitcoin_amount_received", - "bitcoin_uri", "created", - "currency", - "filled", + "customer_mapping", + "default_aggregation", + "display_name", + "event_name", "id", - "inbound_address", "livemode", "object", - "uncaptured_funds" + "status", + "status_transitions", + "updated", + "value_settings" ], - "title": "BitcoinReceiver", + "title": "BillingMeter", "type": "object", - "x-expandableFields": ["transactions"], - "x-resourceId": "bitcoin_receiver" + "x-expandableFields": [ + "customer_mapping", + "default_aggregation", + "status_transitions", + "value_settings" + ], + "x-resourceId": "billing.meter" }, - "bitcoin_transaction": { - "description": "", + "billing.meter_event": { + "description": "A billing meter event represents a customer's usage of a product. Meter events are used to bill a customer based on their usage.\nMeter events are associated with billing meters, which define the shape of the event's payload and how those events are aggregated for billing.", "properties": { - "amount": { - "description": "The amount of `currency` that the transaction was converted to in real-time.", - "type": "integer" - }, - "bitcoin_amount": { - "description": "The amount of bitcoin contained in the transaction.", - "type": "integer" - }, "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) to which this transaction was converted.", + "event_name": { + "description": "The name of the meter event. Corresponds with the `event_name` field on a meter.", + "maxLength": 100, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "identifier": { + "description": "A unique identifier for the event.", "maxLength": 5000, "type": "string" }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["bitcoin_transaction"], + "enum": ["billing.meter_event"], "type": "string" }, - "receiver": { - "description": "The receiver to which this transaction was sent.", - "maxLength": 5000, - "type": "string" + "payload": { + "additionalProperties": { + "maxLength": 100, + "type": "string" + }, + "description": "The payload of the event. This contains the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://stripe.com/docs/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).", + "type": "object" + }, + "timestamp": { + "description": "The timestamp passed in when creating the event. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" } }, "required": [ - "amount", - "bitcoin_amount", "created", - "currency", - "id", + "event_name", + "identifier", + "livemode", "object", - "receiver" + "payload", + "timestamp" ], - "title": "BitcoinTransaction", + "title": "BillingMeterEvent", "type": "object", "x-expandableFields": [], - "x-resourceId": "bitcoin_transaction" + "x-resourceId": "billing.meter_event" }, - "capability": { - "description": "This is an object representing a capability for a Stripe account.\n\nRelated guide: [Account capabilities](https://stripe.com/docs/connect/account-capabilities).", + "billing.meter_event_adjustment": { + "description": "A billing meter event adjustment is a resource that allows you to cancel a meter event. For example, you might create a billing meter event adjustment to cancel a meter event that was created in error or attached to the wrong customer.", "properties": { - "account": { + "cancel": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/billing_meter_resource_billing_meter_event_adjustment_cancel" } ], - "description": "The account for which the capability enables functionality.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/account" - } - ] - } + "description": "Specifies which event to cancel.", + "nullable": true }, - "id": { - "description": "The identifier for the capability.", - "maxLength": 5000, + "event_name": { + "description": "The name of the meter event. Corresponds with the `event_name` field on a meter.", + "maxLength": 100, "type": "string" }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["capability"], + "enum": ["billing.meter_event_adjustment"], "type": "string" }, - "requested": { - "description": "Whether the capability has been requested.", - "type": "boolean" - }, - "requested_at": { - "description": "Time at which the capability was requested. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "requirements": { - "$ref": "#/components/schemas/account_capability_requirements" - }, "status": { - "description": "The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`.", - "enum": [ - "active", - "disabled", - "inactive", - "pending", - "unrequested" - ], + "description": "The meter event adjustment's status.", + "enum": ["complete", "pending"], + "type": "string" + }, + "type": { + "description": "Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.", + "enum": ["cancel"], "type": "string" } }, - "required": ["account", "id", "object", "requested", "status"], - "title": "AccountCapability", + "required": ["event_name", "livemode", "object", "status", "type"], + "title": "BillingMeterEventAdjustment", "type": "object", - "x-expandableFields": ["account", "requirements"], - "x-resourceId": "capability" + "x-expandableFields": ["cancel"], + "x-resourceId": "billing.meter_event_adjustment" }, - "card": { - "description": "You can store multiple cards on a customer in order to charge the customer\nlater. You can also store multiple debit cards on a recipient in order to\ntransfer to those cards later.\n\nRelated guide: [Card Payments with Sources](https://stripe.com/docs/sources/cards).", + "billing.meter_event_summary": { + "description": "A billing meter event summary represents an aggregated view of a customer's billing meter events within a specified timeframe. It indicates how much\nusage was accrued by a customer for that period.", "properties": { - "account": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/account" - } - ], - "description": "The account this card belongs to. This attribute will not be in the card object if the card belongs to a customer or recipient instead.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/account" - } - ] - } - }, - "address_city": { - "description": "City/District/Suburb/Town/Village.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "address_country": { - "description": "Billing address country, if provided when creating card.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "aggregated_value": { + "description": "Aggregated value of all the events within `start_time` (inclusive) and `end_time` (inclusive). The aggregation strategy is defined on meter via `default_aggregation`.", + "type": "number" }, - "address_line1": { - "description": "Address line 1 (Street address/PO Box/Company name).", - "maxLength": 5000, - "nullable": true, - "type": "string" + "end_time": { + "description": "End timestamp for this event summary (exclusive). Must be aligned with minute boundaries.", + "format": "unix-time", + "type": "integer" }, - "address_line1_check": { - "description": "If `address_line1` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "address_line2": { - "description": "Address line 2 (Apartment/Suite/Unit/Building).", - "maxLength": 5000, - "nullable": true, - "type": "string" + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" }, - "address_state": { - "description": "State/County/Province/Region.", + "meter": { + "description": "The meter associated with this event summary.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "address_zip": { - "description": "ZIP or postal code.", - "maxLength": 5000, - "nullable": true, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["billing.meter_event_summary"], "type": "string" }, - "address_zip_check": { - "description": "If `address_zip` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "start_time": { + "description": "Start timestamp for this event summary (inclusive). Must be aligned with minute boundaries.", + "format": "unix-time", + "type": "integer" + } + }, + "required": [ + "aggregated_value", + "end_time", + "id", + "livemode", + "meter", + "object", + "start_time" + ], + "title": "BillingMeterEventSummary", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "billing.meter_event_summary" + }, + "billing_clocks_resource_status_details_advancing_status_details": { + "description": "", + "properties": { + "target_frozen_time": { + "description": "The `frozen_time` that the Test Clock is advancing towards.", + "format": "unix-time", + "type": "integer" + } + }, + "required": ["target_frozen_time"], + "title": "BillingClocksResourceStatusDetailsAdvancingStatusDetails", + "type": "object", + "x-expandableFields": [] + }, + "billing_clocks_resource_status_details_status_details": { + "description": "", + "properties": { + "advancing": { + "$ref": "#/components/schemas/billing_clocks_resource_status_details_advancing_status_details" + } + }, + "title": "BillingClocksResourceStatusDetailsStatusDetails", + "type": "object", + "x-expandableFields": ["advancing"] + }, + "billing_details": { + "description": "", + "properties": { + "address": { + "anyOf": [ + { + "$ref": "#/components/schemas/address" + } + ], + "description": "Billing address.", + "nullable": true }, - "available_payout_methods": { - "description": "A set of available payout methods for this card. Only values from this set should be passed as the `method` when creating a payout.", - "items": { - "enum": ["instant", "standard"], - "type": "string" - }, + "email": { + "description": "Email address.", + "maxLength": 5000, "nullable": true, - "type": "array" + "type": "string" }, - "brand": { - "description": "Card brand. Can be `American Express`, `Diners Club`, `Discover`, `JCB`, `MasterCard`, `UnionPay`, `Visa`, or `Unknown`.", + "name": { + "description": "Full name.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "country": { - "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", + "phone": { + "description": "Billing phone number (including extension).", "maxLength": 5000, "nullable": true, "type": "string" - }, - "currency": { - "description": "Three-letter [ISO code for currency](https://stripe.com/docs/payouts). Only applicable on accounts (not customers or recipients). The card can be used as a transfer destination for funds in this currency.", + } + }, + "title": "billing_details", + "type": "object", + "x-expandableFields": ["address"] + }, + "billing_meter_resource_aggregation_settings": { + "description": "", + "properties": { + "formula": { + "description": "Specifies how events are aggregated.", + "enum": ["count", "sum"], + "type": "string" + } + }, + "required": ["formula"], + "title": "BillingMeterResourceAggregationSettings", + "type": "object", + "x-expandableFields": [] + }, + "billing_meter_resource_billing_meter_event_adjustment_cancel": { + "description": "", + "properties": { + "identifier": { + "description": "Unique identifier for the event.", + "maxLength": 100, + "nullable": true, + "type": "string" + } + }, + "title": "BillingMeterResourceBillingMeterEventAdjustmentCancel", + "type": "object", + "x-expandableFields": [] + }, + "billing_meter_resource_billing_meter_status_transitions": { + "description": "", + "properties": { + "deactivated_at": { + "description": "The time the meter was deactivated, if any. Measured in seconds since Unix epoch.", + "format": "unix-time", "nullable": true, + "type": "integer" + } + }, + "title": "BillingMeterResourceBillingMeterStatusTransitions", + "type": "object", + "x-expandableFields": [] + }, + "billing_meter_resource_billing_meter_value": { + "description": "", + "properties": { + "event_payload_key": { + "description": "The key in the meter event payload to use as the value for this meter.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["event_payload_key"], + "title": "BillingMeterResourceBillingMeterValue", + "type": "object", + "x-expandableFields": [] + }, + "billing_meter_resource_customer_mapping_settings": { + "description": "", + "properties": { + "event_payload_key": { + "description": "The key in the meter event payload to use for mapping the event to a customer.", + "maxLength": 5000, "type": "string" }, - "customer": { + "type": { + "description": "The method for mapping a meter event to a customer.", + "enum": ["by_id"], + "type": "string" + } + }, + "required": ["event_payload_key", "type"], + "title": "BillingMeterResourceCustomerMappingSettings", + "type": "object", + "x-expandableFields": [] + }, + "billing_portal.configuration": { + "description": "A portal configuration describes the functionality and behavior of a portal session.", + "properties": { + "active": { + "description": "Whether the configuration is active and can be used to create portal sessions.", + "type": "boolean" + }, + "application": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/application" }, { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/deleted_application" } ], - "description": "The customer that this card belongs to. This attribute will not be in the card object if the card belongs to an account or recipient instead.", + "description": "ID of the Connect Application that created the configuration.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/application" }, { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/deleted_application" } ] } }, - "cvc_check": { - "description": "If a CVC was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`. A result of unchecked indicates that CVC was provided but hasn't been checked yet. Checks are typically performed when attaching a card to a Customer object, or when creating a charge. For more details, see [Check if a card is valid without a charge](https://support.stripe.com/questions/check-if-a-card-is-valid-without-a-charge).", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "default_for_currency": { - "description": "Whether this card is the default external account for its currency.", - "nullable": true, - "type": "boolean" - }, - "dynamic_last4": { - "description": "(For tokenized numbers only.) The last four digits of the device account number.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "exp_month": { - "description": "Two-digit number representing the card's expiration month.", - "type": "integer" + "business_profile": { + "$ref": "#/components/schemas/portal_business_profile" }, - "exp_year": { - "description": "Four-digit number representing the card's expiration year.", + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", "type": "integer" }, - "fingerprint": { - "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.", + "default_return_url": { + "description": "The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.", "maxLength": 5000, "nullable": true, "type": "string" }, - "funding": { - "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", - "maxLength": 5000, - "type": "string" + "features": { + "$ref": "#/components/schemas/portal_features" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "last4": { - "description": "The last four digits of the card.", - "maxLength": 5000, - "type": "string" + "is_default": { + "description": "Whether the configuration is the default. If `true`, this configuration can be managed in the Dashboard and portal sessions will use this configuration unless it is overriden when creating the session.", + "type": "boolean" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "login_page": { + "$ref": "#/components/schemas/portal_login_page" }, "metadata": { "additionalProperties": { @@ -2413,182 +3310,383 @@ "nullable": true, "type": "object" }, - "name": { - "description": "Cardholder name.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["card"], + "enum": ["billing_portal.configuration"], "type": "string" }, - "recipient": { + "updated": { + "description": "Time at which the object was last updated. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + } + }, + "required": [ + "active", + "business_profile", + "created", + "features", + "id", + "is_default", + "livemode", + "login_page", + "object", + "updated" + ], + "title": "PortalConfiguration", + "type": "object", + "x-expandableFields": [ + "application", + "business_profile", + "features", + "login_page" + ], + "x-resourceId": "billing_portal.configuration" + }, + "billing_portal.session": { + "description": "The Billing customer portal is a Stripe-hosted UI for subscription and\nbilling management.\n\nA portal configuration describes the functionality and features that you\nwant to provide to your customers through the portal.\n\nA portal session describes the instantiation of the customer portal for\na particular customer. By visiting the session's URL, the customer\ncan manage their subscriptions and billing details. For security reasons,\nsessions are short-lived and will expire if the customer does not visit the URL.\nCreate sessions on-demand when customers intend to manage their subscriptions\nand billing details.\n\nRelated guide: [Customer management](/customer-management)", + "properties": { + "configuration": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/recipient" + "$ref": "#/components/schemas/billing_portal.configuration" } ], - "description": "The recipient that this card belongs to. This attribute will not be in the card object if the card belongs to a customer or account instead.", - "nullable": true, + "description": "The configuration used by this session, describing the features available.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/recipient" + "$ref": "#/components/schemas/billing_portal.configuration" } ] } }, - "tokenization_method": { - "description": "If the card number is tokenized, this is the method that was used. Can be `android_pay` (includes Google Pay), `apple_pay`, `masterpass`, `visa_checkout`, or null.", + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "customer": { + "description": "The ID of the customer for this session.", + "maxLength": 5000, + "type": "string" + }, + "flow": { + "anyOf": [ + { + "$ref": "#/components/schemas/portal_flows_flow" + } + ], + "description": "Information about a specific flow for the customer to go through. See the [docs](https://stripe.com/docs/customer-management/portal-deep-links) to learn more about using customer portal deep links and flows.", + "nullable": true + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "locale": { + "description": "The IETF language tag of the locale Customer Portal is displayed in. If blank or auto, the customer’s `preferred_locales` or browser’s locale is used.", + "enum": [ + "auto", + "bg", + "cs", + "da", + "de", + "el", + "en", + "en-AU", + "en-CA", + "en-GB", + "en-IE", + "en-IN", + "en-NZ", + "en-SG", + "es", + "es-419", + "et", + "fi", + "fil", + "fr", + "fr-CA", + "hr", + "hu", + "id", + "it", + "ja", + "ko", + "lt", + "lv", + "ms", + "mt", + "nb", + "nl", + "pl", + "pt", + "pt-BR", + "ro", + "ru", + "sk", + "sl", + "sv", + "th", + "tr", + "vi", + "zh", + "zh-HK", + "zh-TW" + ], + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["billing_portal.session"], + "type": "string" + }, + "on_behalf_of": { + "description": "The account for which the session was created on behalf of. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "return_url": { + "description": "The URL to redirect customers to when they click on the portal's link to return to your website.", "maxLength": 5000, "nullable": true, "type": "string" + }, + "url": { + "description": "The short-lived URL of the session that gives customers access to the customer portal.", + "maxLength": 5000, + "type": "string" } }, "required": [ - "brand", - "exp_month", - "exp_year", - "funding", + "configuration", + "created", + "customer", "id", - "last4", - "object" + "livemode", + "object", + "url" ], - "title": "Card", + "title": "PortalSession", "type": "object", - "x-expandableFields": ["account", "customer", "recipient"], - "x-resourceId": "card" + "x-expandableFields": ["configuration", "flow"], + "x-resourceId": "billing_portal.session" }, - "card_generated_from_payment_method_details": { + "cancellation_details": { "description": "", "properties": { - "card_present": { - "$ref": "#/components/schemas/payment_method_details_card_present" - }, - "type": { - "description": "The type of payment method transaction-specific details from the transaction that generated this `card` payment method. Always `card_present`.", + "comment": { + "description": "Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.", "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "feedback": { + "description": "The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.", + "enum": [ + "customer_service", + "low_quality", + "missing_features", + "other", + "switched_service", + "too_complex", + "too_expensive", + "unused" + ], + "nullable": true, + "type": "string" + }, + "reason": { + "description": "Why this subscription was canceled.", + "enum": [ + "cancellation_requested", + "payment_disputed", + "payment_failed" + ], + "nullable": true, "type": "string" } }, - "required": ["type"], - "title": "card_generated_from_payment_method_details", - "type": "object", - "x-expandableFields": ["card_present"] - }, - "card_mandate_payment_method_details": { - "description": "", - "properties": {}, - "title": "card_mandate_payment_method_details", + "title": "CancellationDetails", "type": "object", "x-expandableFields": [] }, - "charge": { - "description": "To charge a credit or a debit card, you create a `Charge` object. You can\nretrieve and refund individual charges as well as list all charges. Charges\nare identified by a unique, random ID.\n\nRelated guide: [Accept a payment with the Charges API](https://stripe.com/docs/payments/accept-a-payment-charges).", + "capability": { + "description": "This is an object representing a capability for a Stripe account.\n\nRelated guide: [Account capabilities](https://stripe.com/docs/connect/account-capabilities)", "properties": { - "amount": { - "description": "Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", - "type": "integer" - }, - "amount_captured": { - "description": "Amount in %s captured (can be less than the amount attribute on the charge if a partial capture was made).", - "type": "integer" - }, - "amount_refunded": { - "description": "Amount in %s refunded (can be less than the amount attribute on the charge if a partial refund was issued).", - "type": "integer" - }, - "application": { + "account": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/application" + "$ref": "#/components/schemas/account" } ], - "description": "ID of the Connect application that created the charge.", - "nullable": true, + "description": "The account for which the capability enables functionality.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/application" + "$ref": "#/components/schemas/account" } ] } }, - "application_fee": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/application_fee" - } - ], - "description": "The application fee (if any) for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collecting-fees) for details.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/application_fee" - } - ] - } + "future_requirements": { + "$ref": "#/components/schemas/account_capability_future_requirements" }, - "application_fee_amount": { - "description": "The amount of the application fee (if any) requested for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collecting-fees) for details.", + "id": { + "description": "The identifier for the capability.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["capability"], + "type": "string" + }, + "requested": { + "description": "Whether the capability has been requested.", + "type": "boolean" + }, + "requested_at": { + "description": "Time at which the capability was requested. Measured in seconds since the Unix epoch.", + "format": "unix-time", "nullable": true, "type": "integer" }, - "balance_transaction": { + "requirements": { + "$ref": "#/components/schemas/account_capability_requirements" + }, + "status": { + "description": "The status of the capability. Can be `active`, `inactive`, `pending`, or `unrequested`.", + "enum": [ + "active", + "disabled", + "inactive", + "pending", + "unrequested" + ], + "type": "string" + } + }, + "required": ["account", "id", "object", "requested", "status"], + "title": "AccountCapability", + "type": "object", + "x-expandableFields": [ + "account", + "future_requirements", + "requirements" + ], + "x-resourceId": "capability" + }, + "card": { + "description": "You can store multiple cards on a customer in order to charge the customer\nlater. You can also store multiple debit cards on a recipient in order to\ntransfer to those cards later.\n\nRelated guide: [Card payments with Sources](https://stripe.com/docs/sources/cards)", + "properties": { + "account": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/account" } ], - "description": "ID of the balance transaction that describes the impact of this charge on your account balance (not including refunds or disputes).", + "description": "The account this card belongs to. This attribute will not be in the card object if the card belongs to a customer or recipient instead. This property is only available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/account" } ] } }, - "billing_details": { - "$ref": "#/components/schemas/billing_details" + "address_city": { + "description": "City/District/Suburb/Town/Village.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "calculated_statement_descriptor": { - "description": "The full statement descriptor that is passed to card networks, and that is displayed on your customers' credit card and bank statements. Allows you to see what the statement descriptor looks like after the static and dynamic portions are combined.", + "address_country": { + "description": "Billing address country, if provided when creating card.", "maxLength": 5000, "nullable": true, "type": "string" }, - "captured": { - "description": "If the charge was created without capturing, this Boolean represents whether it is still uncaptured or has since been captured.", - "type": "boolean" + "address_line1": { + "description": "Address line 1 (Street address/PO Box/Company name).", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "address_line1_check": { + "description": "If `address_line1` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "address_line2": { + "description": "Address line 2 (Apartment/Suite/Unit/Building).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "address_state": { + "description": "State/County/Province/Region.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "address_zip": { + "description": "ZIP or postal code.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "address_zip_check": { + "description": "If `address_zip` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "available_payout_methods": { + "description": "A set of available payout methods for this card. Only values from this set should be passed as the `method` when creating a payout.", + "items": { + "enum": ["instant", "standard"], + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "brand": { + "description": "Card brand. Can be `American Express`, `Diners Club`, `Discover`, `Eftpos Australia`, `Girocard`, `JCB`, `MasterCard`, `UnionPay`, `Visa`, or `Unknown`.", + "maxLength": 5000, + "type": "string" + }, + "country": { + "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "description": "Three-letter [ISO code for currency](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. Must be a [supported currency](https://docs.stripe.com/currencies). Only applicable on accounts (not customers or recipients). The card can be used as a transfer destination for funds in this currency. This property is only available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "nullable": true, "type": "string" }, "customer": { @@ -2604,7 +3702,7 @@ "$ref": "#/components/schemas/deleted_customer" } ], - "description": "ID of the customer this charge is for if one exists.", + "description": "The customer that this card belongs to. This attribute will not be in the card object if the card belongs to an account or recipient instead.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -2617,7 +3715,314 @@ ] } }, - "description": { + "cvc_check": { + "description": "If a CVC was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`. A result of unchecked indicates that CVC was provided but hasn't been checked yet. Checks are typically performed when attaching a card to a Customer object, or when creating a charge. For more details, see [Check if a card is valid without a charge](https://support.stripe.com/questions/check-if-a-card-is-valid-without-a-charge).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "default_for_currency": { + "description": "Whether this card is the default external account for its currency. This property is only available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "nullable": true, + "type": "boolean" + }, + "dynamic_last4": { + "description": "(For tokenized numbers only.) The last four digits of the device account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "exp_month": { + "description": "Two-digit number representing the card's expiration month.", + "type": "integer" + }, + "exp_year": { + "description": "Four-digit number representing the card's expiration year.", + "type": "integer" + }, + "fingerprint": { + "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.\n\n*As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "funding": { + "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", + "maxLength": 5000, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "last4": { + "description": "The last four digits of the card.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "name": { + "description": "Cardholder name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "networks": { + "$ref": "#/components/schemas/token_card_networks" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["card"], + "type": "string" + }, + "status": { + "description": "For external accounts that are cards, possible values are `new` and `errored`. If a payout fails, the status is set to `errored` and [scheduled payouts](https://stripe.com/docs/payouts#payout-schedule) are stopped until account details are updated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "tokenization_method": { + "description": "If the card number is tokenized, this is the method that was used. Can be `android_pay` (includes Google Pay), `apple_pay`, `masterpass`, `visa_checkout`, or null.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": [ + "brand", + "exp_month", + "exp_year", + "funding", + "id", + "last4", + "object" + ], + "title": "Card", + "type": "object", + "x-expandableFields": ["account", "customer", "networks"], + "x-resourceId": "card" + }, + "card_generated_from_payment_method_details": { + "description": "", + "properties": { + "card_present": { + "$ref": "#/components/schemas/payment_method_details_card_present" + }, + "type": { + "description": "The type of payment method transaction-specific details from the transaction that generated this `card` payment method. Always `card_present`.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "card_generated_from_payment_method_details", + "type": "object", + "x-expandableFields": ["card_present"] + }, + "card_issuing_account_terms_of_service": { + "description": "", + "properties": { + "date": { + "description": "The Unix timestamp marking when the account representative accepted the service agreement.", + "nullable": true, + "type": "integer" + }, + "ip": { + "description": "The IP address from which the account representative accepted the service agreement.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "user_agent": { + "description": "The user agent of the browser from which the account representative accepted the service agreement.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "CardIssuingAccountTermsOfService", + "type": "object", + "x-expandableFields": [] + }, + "card_mandate_payment_method_details": { + "description": "", + "properties": {}, + "title": "card_mandate_payment_method_details", + "type": "object", + "x-expandableFields": [] + }, + "cash_balance": { + "description": "A customer's `Cash balance` represents real funds. Customers can add funds to their cash balance by sending a bank transfer. These funds can be used for payment and can eventually be paid out to your bank account.", + "properties": { + "available": { + "additionalProperties": { + "type": "integer" + }, + "description": "A hash of all cash balances available to this customer. You cannot delete a customer with any cash balances, even if the balance is 0. Amounts are represented in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "nullable": true, + "type": "object" + }, + "customer": { + "description": "The ID of the customer whose cash balance this object represents.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["cash_balance"], + "type": "string" + }, + "settings": { + "$ref": "#/components/schemas/customer_balance_customer_balance_settings" + } + }, + "required": ["customer", "livemode", "object", "settings"], + "title": "cash_balance", + "type": "object", + "x-expandableFields": ["settings"], + "x-resourceId": "cash_balance" + }, + "charge": { + "description": "The `Charge` object represents a single attempt to move money into your Stripe account.\nPaymentIntent confirmation is the most common way to create Charges, but transferring\nmoney to a different Stripe account through Connect also creates Charges.\nSome legacy payment flows create Charges directly, which is not recommended for new integrations.", + "properties": { + "amount": { + "description": "Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", + "type": "integer" + }, + "amount_captured": { + "description": "Amount in cents (or local equivalent) captured (can be less than the amount attribute on the charge if a partial capture was made).", + "type": "integer" + }, + "amount_refunded": { + "description": "Amount in cents (or local equivalent) refunded (can be less than the amount attribute on the charge if a partial refund was issued).", + "type": "integer" + }, + "application": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application" + } + ], + "description": "ID of the Connect application that created the charge.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application" + } + ] + } + }, + "application_fee": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application_fee" + } + ], + "description": "The application fee (if any) for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collect-fees) for details.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application_fee" + } + ] + } + }, + "application_fee_amount": { + "description": "The amount of the application fee (if any) requested for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collect-fees) for details.", + "nullable": true, + "type": "integer" + }, + "balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "ID of the balance transaction that describes the impact of this charge on your account balance (not including refunds or disputes).", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } + }, + "billing_details": { + "$ref": "#/components/schemas/billing_details" + }, + "calculated_statement_descriptor": { + "description": "The full statement descriptor that is passed to card networks, and that is displayed on your customers' credit card and bank statements. Allows you to see what the statement descriptor looks like after the static and dynamic portions are combined. This value only exists for card payments.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "captured": { + "description": "If the charge was created without capturing, this Boolean represents whether it is still uncaptured or has since been captured.", + "type": "boolean" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ], + "description": "ID of the customer this charge is for if one exists.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ] + } + }, + "description": { "description": "An arbitrary string attached to the object. Often useful for displaying to users.", "maxLength": 40000, "nullable": true, @@ -2627,8 +4032,28 @@ "description": "Whether the charge has been disputed.", "type": "boolean" }, + "failure_balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "ID of the balance transaction that describes the reversal of the balance on your account due to payment failure.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } + }, "failure_code": { - "description": "Error code explaining reason for charge failure if available (see [the errors section](https://stripe.com/docs/api#errors) for a list of codes).", + "description": "Error code explaining reason for charge failure if available (see [the errors section](https://stripe.com/docs/error-codes) for a list of codes).", "maxLength": 5000, "nullable": true, "type": "string" @@ -2700,7 +4125,7 @@ "$ref": "#/components/schemas/account" } ], - "description": "The account (if any) the charge was made on behalf of without triggering an automatic transfer. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers) for details.", + "description": "The account (if any) the charge was made on behalf of without triggering an automatic transfer. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -2710,26 +4135,6 @@ ] } }, - "order": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/order" - } - ], - "description": "ID of the order this charge is for if one exists.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/order" - } - ] - } - }, "outcome": { "anyOf": [ { @@ -2778,6 +4183,9 @@ "description": "Details about the payment method at the time of the transaction.", "nullable": true }, + "radar_options": { + "$ref": "#/components/schemas/radar_radar_options" + }, "receipt_email": { "description": "This is the email address that the receipt for this charge was sent to.", "maxLength": 5000, @@ -2802,6 +4210,7 @@ }, "refunds": { "description": "A list of refunds that have been applied to the charge.", + "nullable": true, "properties": { "data": { "description": "Details about each object.", @@ -2869,7 +4278,7 @@ "$ref": "#/components/schemas/transfer" } ], - "description": "The transfer ID which created this charge. Only present if the charge came from another Stripe account. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.", + "description": "The transfer ID which created this charge. Only present if the charge came from another Stripe account. [See the Connect documentation](https://docs.stripe.com/connect/destination-charges) for details.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -2880,20 +4289,20 @@ } }, "statement_descriptor": { - "description": "For card charges, use `statement_descriptor_suffix` instead. Otherwise, you can use this value as the complete description of a charge on your customers’ statements. Must contain at least one letter, maximum 22 characters.", + "description": "For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).\n\nFor a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.", "maxLength": 5000, "nullable": true, "type": "string" }, "statement_descriptor_suffix": { - "description": "Provides information about the charge that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.", + "description": "Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.", "maxLength": 5000, "nullable": true, "type": "string" }, "status": { "description": "The status of the payment is either `succeeded`, `pending`, or `failed`.", - "maxLength": 5000, + "enum": ["failed", "pending", "succeeded"], "type": "string" }, "transfer": { @@ -2925,7 +4334,7 @@ "nullable": true }, "transfer_group": { - "description": "A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details.", + "description": "A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.", "maxLength": 5000, "nullable": true, "type": "string" @@ -2946,7 +4355,6 @@ "object", "paid", "refunded", - "refunds", "status" ], "title": "Charge", @@ -2957,13 +4365,14 @@ "balance_transaction", "billing_details", "customer", + "failure_balance_transaction", "fraud_details", "invoice", "on_behalf_of", - "order", "outcome", "payment_intent", "payment_method_details", + "radar_options", "refunds", "review", "shipping", @@ -3085,8 +4494,17 @@ "x-expandableFields": ["destination"] }, "checkout.session": { - "description": "A Checkout Session represents your customer's session as they pay for\none-time purchases or subscriptions through [Checkout](https://stripe.com/docs/payments/checkout).\nWe recommend creating a new Session each time your customer attempts to pay.\n\nOnce payment is successful, the Checkout Session will contain a reference\nto the [Customer](https://stripe.com/docs/api/customers), and either the successful\n[PaymentIntent](https://stripe.com/docs/api/payment_intents) or an active\n[Subscription](https://stripe.com/docs/api/subscriptions).\n\nYou can create a Checkout Session on your server and pass its ID to the\nclient to begin Checkout.\n\nRelated guide: [Checkout Server Quickstart](https://stripe.com/docs/payments/checkout/api).", + "description": "A Checkout Session represents your customer's session as they pay for\none-time purchases or subscriptions through [Checkout](https://stripe.com/docs/payments/checkout)\nor [Payment Links](https://stripe.com/docs/payments/payment-links). We recommend creating a\nnew Session each time your customer attempts to pay.\n\nOnce payment is successful, the Checkout Session will contain a reference\nto the [Customer](https://stripe.com/docs/api/customers), and either the successful\n[PaymentIntent](https://stripe.com/docs/api/payment_intents) or an active\n[Subscription](https://stripe.com/docs/api/subscriptions).\n\nYou can create a Checkout Session on your server and redirect to its URL\nto begin Checkout.\n\nRelated guide: [Checkout quickstart](https://stripe.com/docs/checkout/quickstart)", "properties": { + "after_expiration": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_after_expiration" + } + ], + "description": "When set, provides configuration for actions to take if this Checkout Session expires.", + "nullable": true + }, "allow_promotion_codes": { "description": "Enables user redeemable promotion codes.", "nullable": true, @@ -3102,15 +4520,19 @@ "nullable": true, "type": "integer" }, + "automatic_tax": { + "$ref": "#/components/schemas/payment_pages_checkout_session_automatic_tax" + }, "billing_address_collection": { - "description": "Describes whether Checkout should collect the customer's billing address.", + "description": "Describes whether Checkout should collect the customer's billing address. Defaults to `auto`.", "enum": ["auto", "required"], "nullable": true, "type": "string" }, "cancel_url": { - "description": "The URL the customer will be directed to if they decide to cancel payment and return to your website.", + "description": "If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website.", "maxLength": 5000, + "nullable": true, "type": "string" }, "client_reference_id": { @@ -3119,11 +4541,59 @@ "nullable": true, "type": "string" }, + "client_secret": { + "description": "Client secret to be used when initializing Stripe.js embedded checkout.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "consent": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_consent" + } + ], + "description": "Results of `consent_collection` for this session.", + "nullable": true + }, + "consent_collection": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_consent_collection" + } + ], + "description": "When set, provides configuration for the Checkout Session to gather active consent from customers.", + "nullable": true + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, "currency": { "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "nullable": true, "type": "string" }, + "currency_conversion": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_currency_conversion" + } + ], + "description": "Currency conversion details for [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing) sessions", + "nullable": true + }, + "custom_fields": { + "description": "Collect additional information from your customer using custom fields. Up to 3 fields are supported.", + "items": { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_fields" + }, + "type": "array" + }, + "custom_text": { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_text" + }, "customer": { "anyOf": [ { @@ -3137,7 +4607,7 @@ "$ref": "#/components/schemas/deleted_customer" } ], - "description": "The ID of the customer for this Session.\nFor Checkout Sessions in `payment` or `subscription` mode, Checkout\nwill create a new customer object based on information provided\nduring the payment flow unless an existing customer was provided when\nthe Session was created.", + "description": "The ID of the customer for this Session.\nFor Checkout Sessions in `subscription` mode or Checkout Sessions with `customer_creation` set as `always` in `payment` mode, Checkout\nwill create a new customer object based on information provided\nduring the payment flow unless an existing customer was provided when\nthe Session was created.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -3150,13 +4620,19 @@ ] } }, + "customer_creation": { + "description": "Configure whether a Checkout Session creates a Customer when the Checkout Session completes.", + "enum": ["always", "if_required"], + "nullable": true, + "type": "string" + }, "customer_details": { "anyOf": [ { "$ref": "#/components/schemas/payment_pages_checkout_session_customer_details" } ], - "description": "The customer details including the customer's tax exempt status and the customer's tax IDs.", + "description": "The customer details including the customer's tax exempt status and the customer's tax IDs. Customer's address details are not present on Sessions in `setup` mode.", "nullable": true }, "customer_email": { @@ -3165,11 +4641,45 @@ "nullable": true, "type": "string" }, + "expires_at": { + "description": "The timestamp at which the Checkout Session will expire.", + "format": "unix-time", + "type": "integer" + }, "id": { - "description": "Unique identifier for the object. Used to pass to `redirectToCheckout`\nin Stripe.js.", + "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, + "invoice": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/invoice" + } + ], + "description": "ID of the invoice created by the Checkout Session, if it exists.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/invoice" + } + ] + } + }, + "invoice_creation": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_invoice_creation" + } + ], + "description": "Details on the state of invoice creation for the Checkout Session.", + "nullable": true + }, "line_items": { "description": "The line items purchased by the customer.", "properties": { @@ -3219,12 +4729,15 @@ "es-419", "et", "fi", + "fil", "fr", "fr-CA", + "hr", "hu", "id", "it", "ja", + "ko", "lt", "lv", "ms", @@ -3239,7 +4752,9 @@ "sk", "sl", "sv", + "th", "tr", + "vi", "zh", "zh-HK", "zh-TW" @@ -3277,7 +4792,7 @@ "$ref": "#/components/schemas/payment_intent" } ], - "description": "The ID of the PaymentIntent for Checkout Sessions in `payment` mode.", + "description": "The ID of the PaymentIntent for Checkout Sessions in `payment` mode. You can't confirm or cancel the PaymentIntent for a Checkout Session. To cancel, [expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -3287,6 +4802,50 @@ ] } }, + "payment_link": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_link" + } + ], + "description": "The ID of the Payment Link that created this Session.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_link" + } + ] + } + }, + "payment_method_collection": { + "description": "Configure whether a Checkout Session should collect a payment method. Defaults to `always`.", + "enum": ["always", "if_required"], + "nullable": true, + "type": "string" + }, + "payment_method_configuration_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_config_biz_payment_method_configuration_details" + } + ], + "description": "Information about the payment method configuration used for this Checkout session if using dynamic payment methods.", + "nullable": true + }, + "payment_method_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/checkout_session_payment_method_options" + } + ], + "description": "Payment-method-specific configuration for the PaymentIntent or SetupIntent of this CheckoutSession.", + "nullable": true + }, "payment_method_types": { "description": "A list of the types of payment methods (e.g. card) this Checkout\nSession is allowed to accept.", "items": { @@ -3300,6 +4859,34 @@ "enum": ["no_payment_required", "paid", "unpaid"], "type": "string" }, + "phone_number_collection": { + "$ref": "#/components/schemas/payment_pages_checkout_session_phone_number_collection" + }, + "recovered_from": { + "description": "The ID of the original expired Checkout Session that triggered the recovery flow.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "redirect_on_completion": { + "description": "This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-redirect-behavior) of embedded sessions. Defaults to `always`.", + "enum": ["always", "if_required", "never"], + "type": "string" + }, + "return_url": { + "description": "Applies to Checkout Sessions with `ui_mode: embedded`. The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.", + "maxLength": 5000, + "type": "string" + }, + "saved_payment_method_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_saved_payment_method_options" + } + ], + "description": "Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.", + "nullable": true + }, "setup_intent": { "anyOf": [ { @@ -3310,7 +4897,7 @@ "$ref": "#/components/schemas/setup_intent" } ], - "description": "The ID of the SetupIntent for Checkout Sessions in `setup` mode.", + "description": "The ID of the SetupIntent for Checkout Sessions in `setup` mode. You can't confirm or cancel the SetupIntent for a Checkout Session. To cancel, [expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -3320,26 +4907,48 @@ ] } }, - "shipping": { + "shipping_address_collection": { "anyOf": [ { - "$ref": "#/components/schemas/shipping" + "$ref": "#/components/schemas/payment_pages_checkout_session_shipping_address_collection" } ], - "description": "Shipping information for this Checkout Session.", + "description": "When set, provides configuration for Checkout to collect a shipping address from a customer.", "nullable": true }, - "shipping_address_collection": { + "shipping_cost": { "anyOf": [ { - "$ref": "#/components/schemas/payment_pages_payment_page_resources_shipping_address_collection" + "$ref": "#/components/schemas/payment_pages_checkout_session_shipping_cost" } ], - "description": "When set, provides configuration for Checkout to collect a shipping address from a customer.", + "description": "The details of the customer cost of shipping, including the customer chosen ShippingRate.", + "nullable": true + }, + "shipping_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/shipping" + } + ], + "description": "Shipping information for this Checkout Session.", "nullable": true }, + "shipping_options": { + "description": "The shipping rate options applied to this Session.", + "items": { + "$ref": "#/components/schemas/payment_pages_checkout_session_shipping_option" + }, + "type": "array" + }, + "status": { + "description": "The status of the Checkout Session, one of `open`, `complete`, or `expired`.", + "enum": ["complete", "expired", "open"], + "nullable": true, + "type": "string" + }, "submit_type": { - "description": "Describes the type of transaction being performed by Checkout in order to customize\nrelevant text on the page, such as the submit button. `submit_type` can only be\nspecified on Checkout Sessions in `payment` mode, but not Checkout Sessions\nin `subscription` or `setup` mode.", + "description": "Describes the type of transaction being performed by Checkout in order to customize\nrelevant text on the page, such as the submit button. `submit_type` can only be\nspecified on Checkout Sessions in `payment` mode. If blank or `auto`, `pay` is used.", "enum": ["auto", "book", "donate", "pay"], "nullable": true, "type": "string" @@ -3367,8 +4976,12 @@ "success_url": { "description": "The URL the customer will be directed to after the payment or\nsubscription creation is successful.", "maxLength": 5000, + "nullable": true, "type": "string" }, + "tax_id_collection": { + "$ref": "#/components/schemas/payment_pages_checkout_session_tax_id_collection" + }, "total_details": { "anyOf": [ { @@ -3377,610 +4990,980 @@ ], "description": "Tax and discount details for the computed total amount.", "nullable": true + }, + "ui_mode": { + "description": "The UI mode of the Session. Defaults to `hosted`.", + "enum": ["embedded", "hosted"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "url": { + "description": "The URL to the Checkout Session. Redirect customers to this URL to take them to Checkout. If you’re using [Custom Domains](https://stripe.com/docs/payments/checkout/custom-domains), the URL will use your subdomain. Otherwise, it’ll use `checkout.stripe.com.`\nThis value is only present when the session is active.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, "required": [ - "cancel_url", + "automatic_tax", + "created", + "custom_fields", + "custom_text", + "expires_at", "id", "livemode", "mode", "object", "payment_method_types", "payment_status", - "success_url" + "shipping_options" ], "title": "Session", "type": "object", "x-expandableFields": [ + "after_expiration", + "automatic_tax", + "consent", + "consent_collection", + "currency_conversion", + "custom_fields", + "custom_text", "customer", "customer_details", + "invoice", + "invoice_creation", "line_items", "payment_intent", + "payment_link", + "payment_method_configuration_details", + "payment_method_options", + "phone_number_collection", + "saved_payment_method_options", "setup_intent", - "shipping", "shipping_address_collection", + "shipping_cost", + "shipping_details", + "shipping_options", "subscription", + "tax_id_collection", "total_details" ], "x-resourceId": "checkout.session" }, - "connect_collection_transfer": { + "checkout_acss_debit_mandate_options": { "description": "", "properties": { - "amount": { - "description": "Amount transferred, in %s.", - "type": "integer" + "custom_mandate_url": { + "description": "A URL for custom mandate text", + "maxLength": 5000, + "type": "string" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "default_for": { + "description": "List of Stripe products where this mandate can be selected automatically. Returned when the Session is in `setup` mode.", + "items": { + "enum": ["invoice", "subscription"], + "type": "string" + }, + "type": "array" + }, + "interval_description": { + "description": "Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "destination": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/account" - } - ], - "description": "ID of the account that funds are being collected for.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/account" - } - ] - } + "payment_schedule": { + "description": "Payment schedule for the mandate.", + "enum": ["combined", "interval", "sporadic"], + "nullable": true, + "type": "string" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "transaction_type": { + "description": "Transaction type of the mandate.", + "enum": ["business", "personal"], + "nullable": true, + "type": "string" + } + }, + "title": "CheckoutAcssDebitMandateOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_acss_debit_payment_method_options": { + "description": "", + "properties": { + "currency": { + "description": "Currency supported by the bank account. Returned when the Session is in `setup` mode.", + "enum": ["cad", "usd"], "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "mandate_options": { + "$ref": "#/components/schemas/checkout_acss_debit_mandate_options" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["connect_collection_transfer"], + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], + "type": "string" + }, + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "CheckoutAcssDebitPaymentMethodOptions", + "type": "object", + "x-expandableFields": ["mandate_options"] + }, + "checkout_affirm_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], "type": "string" } }, - "required": [ - "amount", - "currency", - "destination", - "id", - "livemode", - "object" - ], - "title": "ConnectCollectionTransfer", + "title": "CheckoutAffirmPaymentMethodOptions", "type": "object", - "x-expandableFields": ["destination"] + "x-expandableFields": [] }, - "country_spec": { - "description": "Stripe needs to collect certain pieces of information about each account\ncreated. These requirements can differ depending on the account's country. The\nCountry Specs API makes these rules available to your integration.\n\nYou can also view the information from this API call as [an online\nguide](/docs/connect/required-verification-information).", + "checkout_afterpay_clearpay_payment_method_options": { + "description": "", "properties": { - "default_currency": { - "description": "The default currency for this country. This applies to both payment methods and bank accounts.", - "maxLength": 5000, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], "type": "string" - }, - "id": { - "description": "Unique identifier for the object. Represented as the ISO country code for this country.", - "maxLength": 5000, + } + }, + "title": "CheckoutAfterpayClearpayPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_alipay_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutAlipayPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_amazon_pay_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "CheckoutAmazonPayPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_au_becs_debit_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutAuBecsDebitPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_bacs_debit_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], + "type": "string" + } + }, + "title": "CheckoutBacsDebitPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_bancontact_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], "type": "string" + } + }, + "title": "CheckoutBancontactPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_boleto_payment_method_options": { + "description": "", + "properties": { + "expires_after_days": { + "description": "The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto voucher will expire on Wednesday at 23:59 America/Sao_Paulo time.", + "type": "integer" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["country_spec"], + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], "type": "string" + } + }, + "required": ["expires_after_days"], + "title": "CheckoutBoletoPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_card_installments_options": { + "description": "", + "properties": { + "enabled": { + "description": "Indicates if installments are enabled", + "type": "boolean" + } + }, + "title": "CheckoutCardInstallmentsOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_card_payment_method_options": { + "description": "", + "properties": { + "installments": { + "$ref": "#/components/schemas/checkout_card_installments_options" }, - "supported_bank_account_currencies": { - "additionalProperties": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "description": "Currencies that can be accepted in the specific country (for transfers).", - "type": "object" + "request_three_d_secure": { + "description": "We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.", + "enum": ["any", "automatic", "challenge"], + "type": "string", + "x-stripeBypassValidation": true }, - "supported_payment_currencies": { - "description": "Currencies that can be accepted in the specified country (for payments).", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], + "type": "string" }, - "supported_payment_methods": { - "description": "Payment methods available in the specified country. You may need to enable some payment methods (e.g., [ACH](https://stripe.com/docs/ach)) on your account before they appear in this list. The `stripe` payment method refers to [charging through your platform](https://stripe.com/docs/connect/destination-charges).", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "statement_descriptor_suffix_kana": { + "description": "Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.", + "maxLength": 5000, + "type": "string" }, - "supported_transfer_countries": { - "description": "Countries that can accept transfers from the specified country.", + "statement_descriptor_suffix_kanji": { + "description": "Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["request_three_d_secure"], + "title": "CheckoutCardPaymentMethodOptions", + "type": "object", + "x-expandableFields": ["installments"] + }, + "checkout_cashapp_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutCashappPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_customer_balance_bank_transfer_payment_method_options": { + "description": "", + "properties": { + "eu_bank_transfer": { + "$ref": "#/components/schemas/payment_method_options_customer_balance_eu_bank_account" + }, + "requested_address_types": { + "description": "List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.\n\nPermitted values include: `sort_code`, `zengin`, `iban`, or `spei`.", "items": { - "maxLength": 5000, - "type": "string" + "enum": [ + "aba", + "iban", + "sepa", + "sort_code", + "spei", + "swift", + "zengin" + ], + "type": "string", + "x-stripeBypassValidation": true }, "type": "array" }, - "verification_fields": { - "$ref": "#/components/schemas/country_spec_verification_fields" + "type": { + "description": "The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.", + "enum": [ + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "mx_bank_transfer", + "us_bank_transfer" + ], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true } }, - "required": [ - "default_currency", - "id", - "object", - "supported_bank_account_currencies", - "supported_payment_currencies", - "supported_payment_methods", - "supported_transfer_countries", - "verification_fields" - ], - "title": "CountrySpec", + "title": "CheckoutCustomerBalanceBankTransferPaymentMethodOptions", "type": "object", - "x-expandableFields": ["verification_fields"], - "x-resourceId": "country_spec" + "x-expandableFields": ["eu_bank_transfer"] }, - "country_spec_verification_field_details": { + "checkout_customer_balance_payment_method_options": { "description": "", "properties": { - "additional": { - "description": "Additional fields which are only required for some users.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "bank_transfer": { + "$ref": "#/components/schemas/checkout_customer_balance_bank_transfer_payment_method_options" }, - "minimum": { - "description": "Fields which every account must eventually provide.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "funding_type": { + "description": "The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.", + "enum": ["bank_transfer"], + "nullable": true, + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" } }, - "required": ["additional", "minimum"], - "title": "CountrySpecVerificationFieldDetails", + "title": "CheckoutCustomerBalancePaymentMethodOptions", + "type": "object", + "x-expandableFields": ["bank_transfer"] + }, + "checkout_eps_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutEpsPaymentMethodOptions", "type": "object", "x-expandableFields": [] }, - "country_spec_verification_fields": { + "checkout_fpx_payment_method_options": { "description": "", "properties": { - "company": { - "$ref": "#/components/schemas/country_spec_verification_field_details" - }, - "individual": { - "$ref": "#/components/schemas/country_spec_verification_field_details" + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" } }, - "required": ["company", "individual"], - "title": "CountrySpecVerificationFields", + "title": "CheckoutFpxPaymentMethodOptions", "type": "object", - "x-expandableFields": ["company", "individual"] + "x-expandableFields": [] }, - "coupon": { - "description": "A coupon contains information about a percent-off or amount-off discount you\nmight want to apply to a customer. Coupons may be applied to [invoices](https://stripe.com/docs/api#invoices) or\n[orders](https://stripe.com/docs/api#create_order-coupon). Coupons do not work with conventional one-off [charges](https://stripe.com/docs/api#create_charge).", + "checkout_giropay_payment_method_options": { + "description": "", "properties": { - "amount_off": { - "description": "Amount (in the `currency` specified) that will be taken off the subtotal of any invoices for this customer.", + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutGiropayPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_grab_pay_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutGrabPayPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_ideal_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutIdealPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_klarna_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], + "type": "string" + } + }, + "title": "CheckoutKlarnaPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_konbini_payment_method_options": { + "description": "", + "properties": { + "expires_after_days": { + "description": "The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST.", "nullable": true, "type": "integer" }, - "applies_to": { - "$ref": "#/components/schemas/coupon_applies_to" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "currency": { - "description": "If `amount_off` has been set, the three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the amount to take off.", - "nullable": true, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], "type": "string" - }, - "duration": { - "description": "One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount.", - "enum": ["forever", "once", "repeating"], + } + }, + "title": "CheckoutKonbiniPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_link_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], "type": "string" - }, - "duration_in_months": { - "description": "If `duration` is `repeating`, the number of months the coupon applies. Null if coupon `duration` is `forever` or `once`.", - "nullable": true, + } + }, + "title": "CheckoutLinkPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_mobilepay_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutMobilepayPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_multibanco_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutMultibancoPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_oxxo_payment_method_options": { + "description": "", + "properties": { + "expires_after_days": { + "description": "The number of calendar days before an OXXO invoice expires. For example, if you create an OXXO invoice on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.", "type": "integer" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "required": ["expires_after_days"], + "title": "CheckoutOxxoPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_p24_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutP24PaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_paynow_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutPaynowPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_paypal_payment_method_options": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "max_redemptions": { - "description": "Maximum number of times this coupon can be redeemed, in total, across all customers, before it is no longer valid.", - "nullable": true, - "type": "integer" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "preferred_locale": { + "description": "Preferred locale of the PayPal checkout page that the customer is redirected to.", + "maxLength": 5000, "nullable": true, - "type": "object" + "type": "string" }, - "name": { - "description": "Name of the coupon displayed to customers on for instance invoices or receipts.", + "reference": { + "description": "A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.", "maxLength": 5000, "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["coupon"], + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], "type": "string" - }, - "percent_off": { - "description": "Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon. For example, a coupon with percent_off of 50 will make a %s100 invoice %s50 instead.", - "nullable": true, - "type": "number" - }, - "redeem_by": { - "description": "Date after which the coupon can no longer be redeemed.", - "format": "unix-time", + } + }, + "title": "CheckoutPaypalPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_pix_payment_method_options": { + "description": "", + "properties": { + "expires_after_seconds": { + "description": "The number of seconds after which Pix payment will expire.", "nullable": true, "type": "integer" - }, - "times_redeemed": { - "description": "Number of times this coupon has been applied to a customer.", - "type": "integer" - }, - "valid": { - "description": "Taking account of the above properties, whether this coupon can still be applied to a customer.", - "type": "boolean" } }, - "required": [ - "created", - "duration", - "id", - "livemode", - "object", - "times_redeemed", - "valid" - ], - "title": "Coupon", + "title": "CheckoutPixPaymentMethodOptions", "type": "object", - "x-expandableFields": ["applies_to"], - "x-resourceId": "coupon" + "x-expandableFields": [] }, - "coupon_applies_to": { + "checkout_revolut_pay_payment_method_options": { "description": "", "properties": { - "products": { - "description": "A list of product IDs this coupon applies to", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], + "type": "string" } }, - "required": ["products"], - "title": "CouponAppliesTo", + "title": "CheckoutRevolutPayPaymentMethodOptions", "type": "object", "x-expandableFields": [] }, - "credit_note": { - "description": "Issue a credit note to adjust an invoice's amount after the invoice is finalized.\n\nRelated guide: [Credit Notes](https://stripe.com/docs/billing/invoices/credit-notes).", + "checkout_sepa_debit_payment_method_options": { + "description": "", "properties": { - "amount": { - "description": "The integer amount in %s representing the total amount of the credit note, including tax.", - "type": "integer" + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], + "type": "string" + } + }, + "title": "CheckoutSepaDebitPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_session_payment_method_options": { + "description": "", + "properties": { + "acss_debit": { + "$ref": "#/components/schemas/checkout_acss_debit_payment_method_options" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "affirm": { + "$ref": "#/components/schemas/checkout_affirm_payment_method_options" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" + "afterpay_clearpay": { + "$ref": "#/components/schemas/checkout_afterpay_clearpay_payment_method_options" }, - "customer": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ], - "description": "ID of the customer.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ] - } + "alipay": { + "$ref": "#/components/schemas/checkout_alipay_payment_method_options" }, - "customer_balance_transaction": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/customer_balance_transaction" - } - ], - "description": "Customer balance transaction related to this credit note.", + "amazon_pay": { + "$ref": "#/components/schemas/checkout_amazon_pay_payment_method_options" + }, + "au_becs_debit": { + "$ref": "#/components/schemas/checkout_au_becs_debit_payment_method_options" + }, + "bacs_debit": { + "$ref": "#/components/schemas/checkout_bacs_debit_payment_method_options" + }, + "bancontact": { + "$ref": "#/components/schemas/checkout_bancontact_payment_method_options" + }, + "boleto": { + "$ref": "#/components/schemas/checkout_boleto_payment_method_options" + }, + "card": { + "$ref": "#/components/schemas/checkout_card_payment_method_options" + }, + "cashapp": { + "$ref": "#/components/schemas/checkout_cashapp_payment_method_options" + }, + "customer_balance": { + "$ref": "#/components/schemas/checkout_customer_balance_payment_method_options" + }, + "eps": { + "$ref": "#/components/schemas/checkout_eps_payment_method_options" + }, + "fpx": { + "$ref": "#/components/schemas/checkout_fpx_payment_method_options" + }, + "giropay": { + "$ref": "#/components/schemas/checkout_giropay_payment_method_options" + }, + "grabpay": { + "$ref": "#/components/schemas/checkout_grab_pay_payment_method_options" + }, + "ideal": { + "$ref": "#/components/schemas/checkout_ideal_payment_method_options" + }, + "klarna": { + "$ref": "#/components/schemas/checkout_klarna_payment_method_options" + }, + "konbini": { + "$ref": "#/components/schemas/checkout_konbini_payment_method_options" + }, + "link": { + "$ref": "#/components/schemas/checkout_link_payment_method_options" + }, + "mobilepay": { + "$ref": "#/components/schemas/checkout_mobilepay_payment_method_options" + }, + "multibanco": { + "$ref": "#/components/schemas/checkout_multibanco_payment_method_options" + }, + "oxxo": { + "$ref": "#/components/schemas/checkout_oxxo_payment_method_options" + }, + "p24": { + "$ref": "#/components/schemas/checkout_p24_payment_method_options" + }, + "paynow": { + "$ref": "#/components/schemas/checkout_paynow_payment_method_options" + }, + "paypal": { + "$ref": "#/components/schemas/checkout_paypal_payment_method_options" + }, + "pix": { + "$ref": "#/components/schemas/checkout_pix_payment_method_options" + }, + "revolut_pay": { + "$ref": "#/components/schemas/checkout_revolut_pay_payment_method_options" + }, + "sepa_debit": { + "$ref": "#/components/schemas/checkout_sepa_debit_payment_method_options" + }, + "sofort": { + "$ref": "#/components/schemas/checkout_sofort_payment_method_options" + }, + "swish": { + "$ref": "#/components/schemas/checkout_swish_payment_method_options" + }, + "us_bank_account": { + "$ref": "#/components/schemas/checkout_us_bank_account_payment_method_options" + } + }, + "title": "CheckoutSessionPaymentMethodOptions", + "type": "object", + "x-expandableFields": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "us_bank_account" + ] + }, + "checkout_sofort_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "CheckoutSofortPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_swish_payment_method_options": { + "description": "", + "properties": { + "reference": { + "description": "The order reference that will be displayed to customers in the Swish application. Defaults to the `id` of the Payment Intent.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/customer_balance_transaction" - } - ] - } + "type": "string" + } + }, + "title": "CheckoutSwishPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "checkout_us_bank_account_payment_method_options": { + "description": "", + "properties": { + "financial_connections": { + "$ref": "#/components/schemas/linked_account_options_us_bank_account" }, - "discount_amount": { - "description": "The integer amount in %s representing the total amount of discount that was credited.", + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], + "type": "string" + }, + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "CheckoutUsBankAccountPaymentMethodOptions", + "type": "object", + "x-expandableFields": ["financial_connections"] + }, + "climate.order": { + "description": "Orders represent your intent to purchase a particular Climate product. When you create an order, the\npayment is deducted from your merchant balance.", + "properties": { + "amount_fees": { + "description": "Total amount of [Frontier](https://frontierclimate.com/)'s service fees in the currency's smallest unit.", "type": "integer" }, - "discount_amounts": { - "description": "The aggregate amounts calculated per discount for all line items.", + "amount_subtotal": { + "description": "Total amount of the carbon removal in the currency's smallest unit.", + "type": "integer" + }, + "amount_total": { + "description": "Total amount of the order including fees in the currency's smallest unit.", + "type": "integer" + }, + "beneficiary": { + "$ref": "#/components/schemas/climate_removals_beneficiary" + }, + "canceled_at": { + "description": "Time at which the order was canceled. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "cancellation_reason": { + "description": "Reason for the cancellation of this order.", + "enum": ["expired", "product_unavailable", "requested"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "certificate": { + "description": "For delivered orders, a URL to a delivery certificate for the order.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "confirmed_at": { + "description": "Time at which the order was confirmed. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase, representing the currency for this order.", + "maxLength": 5000, + "type": "string" + }, + "delayed_at": { + "description": "Time at which the order's expected_delivery_year was delayed. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "delivered_at": { + "description": "Time at which the order was delivered. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "delivery_details": { + "description": "Details about the delivery of carbon removal for this order.", "items": { - "$ref": "#/components/schemas/discounts_resource_discount_amount" + "$ref": "#/components/schemas/climate_removals_order_deliveries" }, "type": "array" }, + "expected_delivery_year": { + "description": "The year this order is expected to be delivered.", + "type": "integer" + }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "invoice": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/invoice" - } - ], - "description": "ID of the invoice.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/invoice" - } - ] - } - }, - "lines": { - "description": "Line items that make up the credit note", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/credit_note_line_item" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "CreditNoteLinesList", - "type": "object", - "x-expandableFields": ["data"] - }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "memo": { - "description": "Customer-facing text that appears on the credit note PDF.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, "metadata": { "additionalProperties": { "maxLength": 500, "type": "string" }, "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, "type": "object" }, - "number": { - "description": "A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice.", - "maxLength": 5000, + "metric_tons": { + "description": "Quantity of carbon removal that is included in this order.", + "format": "decimal", "type": "string" }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["credit_note"], - "type": "string" - }, - "out_of_band_amount": { - "description": "Amount that was credited outside of Stripe.", - "nullable": true, - "type": "integer" - }, - "pdf": { - "description": "The link to download the PDF of the credit note.", - "maxLength": 5000, - "type": "string" - }, - "reason": { - "description": "Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`", - "enum": [ - "duplicate", - "fraudulent", - "order_change", - "product_unsatisfactory" - ], - "nullable": true, + "enum": ["climate.order"], "type": "string" }, - "refund": { + "product": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/refund" + "$ref": "#/components/schemas/climate.product" } ], - "description": "Refund related to this credit note.", - "nullable": true, + "description": "Unique ID for the Climate `Product` this order is purchasing.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/refund" + "$ref": "#/components/schemas/climate.product" } ] } }, - "status": { - "description": "Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding).", - "enum": ["issued", "void"], - "type": "string" - }, - "subtotal": { - "description": "The integer amount in %s representing the amount of the credit note, excluding tax and invoice level discounts.", - "type": "integer" - }, - "tax_amounts": { - "description": "The aggregate amounts calculated per tax rate for all line items.", - "items": { - "$ref": "#/components/schemas/credit_note_tax_amount" - }, - "type": "array" - }, - "total": { - "description": "The integer amount in %s representing the total amount of the credit note, including tax and all discount.", - "type": "integer" - }, - "type": { - "description": "Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid.", - "enum": ["post_payment", "pre_payment"], - "type": "string" - }, - "voided_at": { - "description": "The time that the credit note was voided.", + "product_substituted_at": { + "description": "Time at which the order's product was substituted for a different product. Measured in seconds since the Unix epoch.", "format": "unix-time", "nullable": true, "type": "integer" + }, + "status": { + "description": "The current status of this order.", + "enum": [ + "awaiting_funds", + "canceled", + "confirmed", + "delivered", + "open" + ], + "type": "string" } }, "required": [ - "amount", + "amount_fees", + "amount_subtotal", + "amount_total", "created", "currency", - "customer", - "discount_amount", - "discount_amounts", + "delivery_details", + "expected_delivery_year", "id", - "invoice", - "lines", "livemode", - "number", + "metadata", + "metric_tons", "object", - "pdf", - "status", - "subtotal", - "tax_amounts", - "total", - "type" + "product", + "status" ], - "title": "CreditNote", + "title": "ClimateRemovalsOrders", "type": "object", - "x-expandableFields": [ - "customer", - "customer_balance_transaction", - "discount_amounts", - "invoice", - "lines", - "refund", - "tax_amounts" - ], - "x-resourceId": "credit_note" + "x-expandableFields": ["beneficiary", "delivery_details", "product"], + "x-resourceId": "climate.order" }, - "credit_note_line_item": { - "description": "", + "climate.product": { + "description": "A Climate product represents a type of carbon removal unit available for reservation.\nYou can retrieve it to see the current price and availability.", "properties": { - "amount": { - "description": "The integer amount in %s representing the gross amount being credited for this line item, excluding (exclusive) tax and discounts.", + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", "type": "integer" }, - "description": { - "description": "Description of the item being credited.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "current_prices_per_metric_ton": { + "additionalProperties": { + "$ref": "#/components/schemas/climate_removals_products_price" + }, + "description": "Current prices for a metric ton of carbon removal in a currency's smallest unit.", + "type": "object" }, - "discount_amount": { - "description": "The integer amount in %s representing the discount being credited for this line item.", + "delivery_year": { + "description": "The year in which the carbon removal is expected to be delivered.", + "nullable": true, "type": "integer" }, - "discount_amounts": { - "description": "The amount of discount calculated per discount for this line item", - "items": { - "$ref": "#/components/schemas/discounts_resource_discount_amount" - }, - "type": "array" - }, "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "invoice_line_item": { - "description": "ID of the invoice line item being credited", + "description": "Unique identifier for the object. For convenience, Climate product IDs are human-readable strings\nthat start with `climsku_`. See [carbon removal inventory](https://stripe.com/docs/climate/orders/carbon-removal-inventory)\nfor a list of available carbon removal products.", "maxLength": 5000, "type": "string" }, @@ -3988,775 +5971,1233 @@ "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, + "metric_tons_available": { + "description": "The quantity of metric tons available for reservation.", + "format": "decimal", + "type": "string" + }, + "name": { + "description": "The Climate product's name.", + "maxLength": 5000, + "type": "string" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["credit_note_line_item"], + "enum": ["climate.product"], "type": "string" }, - "quantity": { - "description": "The number of units of product being credited.", - "nullable": true, - "type": "integer" - }, - "tax_amounts": { - "description": "The amount of tax calculated per tax rate for this line item", + "suppliers": { + "description": "The carbon removal suppliers that fulfill orders for this Climate product.", "items": { - "$ref": "#/components/schemas/credit_note_tax_amount" + "$ref": "#/components/schemas/climate.supplier" }, "type": "array" + } + }, + "required": [ + "created", + "current_prices_per_metric_ton", + "id", + "livemode", + "metric_tons_available", + "name", + "object", + "suppliers" + ], + "title": "ClimateRemovalsProducts", + "type": "object", + "x-expandableFields": ["current_prices_per_metric_ton", "suppliers"], + "x-resourceId": "climate.product" + }, + "climate.supplier": { + "description": "A supplier of carbon removal.", + "properties": { + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" }, - "tax_rates": { - "description": "The tax rates which apply to the line item.", + "info_url": { + "description": "Link to a webpage to learn more about the supplier.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "locations": { + "description": "The locations in which this supplier operates.", "items": { - "$ref": "#/components/schemas/tax_rate" + "$ref": "#/components/schemas/climate_removals_location" }, "type": "array" }, - "type": { - "description": "The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice.", - "enum": ["custom_line_item", "invoice_line_item"], + "name": { + "description": "Name of this carbon removal supplier.", + "maxLength": 5000, "type": "string" }, - "unit_amount": { - "description": "The cost of each unit of product being credited.", - "nullable": true, - "type": "integer" + "object": { + "description": "String representing the object’s type. Objects of the same type share the same value.", + "enum": ["climate.supplier"], + "type": "string" }, - "unit_amount_decimal": { - "description": "Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.", - "format": "decimal", - "nullable": true, + "removal_pathway": { + "description": "The scientific pathway used for carbon removal.", + "enum": [ + "biomass_carbon_removal_and_storage", + "direct_air_capture", + "enhanced_weathering" + ], "type": "string" } }, "required": [ - "amount", - "discount_amount", - "discount_amounts", "id", + "info_url", "livemode", + "locations", + "name", "object", - "tax_amounts", - "tax_rates", - "type" + "removal_pathway" ], - "title": "CreditNoteLineItem", + "title": "ClimateRemovalsSuppliers", "type": "object", - "x-expandableFields": ["discount_amounts", "tax_amounts", "tax_rates"], - "x-resourceId": "credit_note_line_item" + "x-expandableFields": ["locations"], + "x-resourceId": "climate.supplier" }, - "credit_note_tax_amount": { + "climate_removals_beneficiary": { "description": "", "properties": { - "amount": { - "description": "The amount, in %s, of the tax.", - "type": "integer" + "public_name": { + "description": "Publicly displayable name for the end beneficiary of carbon removal.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["public_name"], + "title": "ClimateRemovalsBeneficiary", + "type": "object", + "x-expandableFields": [] + }, + "climate_removals_location": { + "description": "", + "properties": { + "city": { + "description": "The city where the supplier is located.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "inclusive": { - "description": "Whether this tax amount is inclusive or exclusive.", - "type": "boolean" + "country": { + "description": "Two-letter ISO code representing the country where the supplier is located.", + "maxLength": 5000, + "type": "string" }, - "tax_rate": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/tax_rate" - } - ], - "description": "The tax rate that was applied to get this tax amount.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/tax_rate" - } - ] - } + "latitude": { + "description": "The geographic latitude where the supplier is located.", + "nullable": true, + "type": "number" + }, + "longitude": { + "description": "The geographic longitude where the supplier is located.", + "nullable": true, + "type": "number" + }, + "region": { + "description": "The state/county/province/region where the supplier is located.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "required": ["amount", "inclusive", "tax_rate"], - "title": "CreditNoteTaxAmount", + "required": ["country"], + "title": "ClimateRemovalsLocation", "type": "object", - "x-expandableFields": ["tax_rate"] + "x-expandableFields": [] }, - "customer": { - "description": "`Customer` objects allow you to perform recurring charges, and to track\nmultiple charges, that are associated with the same customer. The API allows\nyou to create, delete, and update your customers. You can retrieve individual\ncustomers as well as a list of all your customers.\n\nRelated guide: [Save a card during payment](https://stripe.com/docs/payments/save-during-payment).", + "climate_removals_order_deliveries": { + "description": "The delivery of a specified quantity of carbon for an order.", "properties": { - "address": { + "delivered_at": { + "description": "Time at which the delivery occurred. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "location": { "anyOf": [ { - "$ref": "#/components/schemas/address" + "$ref": "#/components/schemas/climate_removals_location" } ], - "description": "The customer's address.", + "description": "Specific location of this delivery.", "nullable": true }, - "balance": { - "description": "Current balance, if any, being stored on the customer. If negative, the customer has credit to apply to their next invoice. If positive, the customer has an amount owed that will be added to their next invoice. The balance does not refer to any unpaid invoices; it solely takes into account amounts that have yet to be successfully applied to any invoice. This balance is only taken into account as invoices are finalized.", + "metric_tons": { + "description": "Quantity of carbon removal supplied by this delivery.", + "maxLength": 5000, + "type": "string" + }, + "registry_url": { + "description": "Once retired, a URL to the registry entry for the tons from this delivery.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "supplier": { + "$ref": "#/components/schemas/climate.supplier" + } + }, + "required": ["delivered_at", "metric_tons", "supplier"], + "title": "ClimateRemovalsOrderDeliveries", + "type": "object", + "x-expandableFields": ["location", "supplier"] + }, + "climate_removals_products_price": { + "description": "", + "properties": { + "amount_fees": { + "description": "Fees for one metric ton of carbon removal in the currency's smallest unit.", + "type": "integer" + }, + "amount_subtotal": { + "description": "Subtotal for one metric ton of carbon removal (excluding fees) in the currency's smallest unit.", "type": "integer" }, + "amount_total": { + "description": "Total for one metric ton of carbon removal (including fees) in the currency's smallest unit.", + "type": "integer" + } + }, + "required": ["amount_fees", "amount_subtotal", "amount_total"], + "title": "ClimateRemovalsProductsPrice", + "type": "object", + "x-expandableFields": [] + }, + "confirmation_token": { + "description": "ConfirmationTokens help transport client side data collected by Stripe JS over\nto your server for confirming a PaymentIntent or SetupIntent. If the confirmation\nis successful, values present on the ConfirmationToken are written onto the Intent.\n\nTo learn more about how to use ConfirmationToken, visit the related guides:\n- [Finalize payments on the server](https://stripe.com/docs/payments/finalize-payments-on-the-server)\n- [Build two-step confirmation](https://stripe.com/docs/payments/build-a-two-step-confirmation).", + "properties": { "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) the customer can be charged in for recurring billing purposes.", - "maxLength": 5000, + "expires_at": { + "description": "Time at which this ConfirmationToken expires and can no longer be used to confirm a PaymentIntent or SetupIntent.", + "format": "unix-time", "nullable": true, + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, "type": "string" }, - "default_source": { + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "mandate_data": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/alipay_account" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/source" + "$ref": "#/components/schemas/confirmation_tokens_resource_mandate_data" } ], - "description": "ID of the default payment source for the customer.\n\nIf you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) field instead.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/alipay_account" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/source" - } - ] - } + "description": "Data used for generating a Mandate.", + "nullable": true }, - "delinquent": { - "description": "When the customer's latest invoice is billed by charging automatically, `delinquent` is `true` if the invoice's latest charge failed. When the customer's latest invoice is billed by sending an invoice, `delinquent` is `true` if the invoice isn't paid by its due date.\n\nIf an invoice is marked uncollectible by [dunning](https://stripe.com/docs/billing/automatic-collection), `delinquent` doesn't get reset to `false`.", - "nullable": true, - "type": "boolean" + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["confirmation_token"], + "type": "string" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "payment_intent": { + "description": "ID of the PaymentIntent that this ConfirmationToken was used to confirm, or null if this ConfirmationToken has not yet been used.", "maxLength": 5000, "nullable": true, "type": "string" }, - "discount": { + "payment_method_options": { "anyOf": [ { - "$ref": "#/components/schemas/discount" + "$ref": "#/components/schemas/confirmation_tokens_resource_payment_method_options" } ], - "description": "Describes the current discount active on the customer, if there is one.", + "description": "Payment-method-specific configuration for this ConfirmationToken.", "nullable": true }, - "email": { - "description": "The customer's email address.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "payment_method_preview": { + "anyOf": [ + { + "$ref": "#/components/schemas/confirmation_tokens_resource_payment_method_preview" + } + ], + "description": "Payment details collected by the Payment Element, used to create a PaymentMethod when a PaymentIntent or SetupIntent is confirmed with this ConfirmationToken.", + "nullable": true }, - "invoice_prefix": { - "description": "The prefix for the customer used to generate unique invoice numbers.", + "return_url": { + "description": "Return URL used to confirm the Intent.", "maxLength": 5000, "nullable": true, "type": "string" }, - "invoice_settings": { - "$ref": "#/components/schemas/invoice_setting_customer_setting" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "name": { - "description": "The customer's full name or business name.", - "maxLength": 5000, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this ConfirmationToken's payment method.\n\nThe presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.", + "enum": ["off_session", "on_session"], "nullable": true, "type": "string" }, - "next_invoice_sequence": { - "description": "The suffix of the customer's next invoice number, e.g., 0001.", - "type": "integer" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["customer"], - "type": "string" - }, - "phone": { - "description": "The customer's phone number.", + "setup_intent": { + "description": "ID of the SetupIntent that this ConfirmationToken was used to confirm, or null if this ConfirmationToken has not yet been used.", "maxLength": 5000, "nullable": true, "type": "string" }, - "preferred_locales": { - "description": "The customer's preferred locales (languages), ordered by preference.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "nullable": true, - "type": "array" - }, "shipping": { "anyOf": [ { - "$ref": "#/components/schemas/shipping" + "$ref": "#/components/schemas/confirmation_tokens_resource_shipping" } ], - "description": "Mailing and shipping address for the customer. Appears on invoices emailed to this customer.", + "description": "Shipping information collected on this ConfirmationToken.", "nullable": true }, - "sources": { - "description": "The customer's payment sources, if any.", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "anyOf": [ - { - "$ref": "#/components/schemas/alipay_account" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/source" - } - ], - "title": "Polymorphic" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "ApmsSourcesSourceList", - "type": "object", - "x-expandableFields": ["data"] - }, - "subscriptions": { - "description": "The customer's current subscriptions, if any.", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/subscription" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" + "use_stripe_sdk": { + "description": "Indicates whether the Stripe SDK is used to handle confirmation flow. Defaults to `true` on ConfirmationToken.", + "type": "boolean" + } + }, + "required": ["created", "id", "livemode", "object", "use_stripe_sdk"], + "title": "ConfirmationTokensResourceConfirmationToken", + "type": "object", + "x-expandableFields": [ + "mandate_data", + "payment_method_options", + "payment_method_preview", + "shipping" + ], + "x-resourceId": "confirmation_token" + }, + "confirmation_tokens_resource_mandate_data": { + "description": "Data used for generating a Mandate.", + "properties": { + "customer_acceptance": { + "$ref": "#/components/schemas/confirmation_tokens_resource_mandate_data_resource_customer_acceptance" + } + }, + "required": ["customer_acceptance"], + "title": "ConfirmationTokensResourceMandateData", + "type": "object", + "x-expandableFields": ["customer_acceptance"] + }, + "confirmation_tokens_resource_mandate_data_resource_customer_acceptance": { + "description": "This hash contains details about the customer acceptance of the Mandate.", + "properties": { + "online": { + "anyOf": [ + { + "$ref": "#/components/schemas/confirmation_tokens_resource_mandate_data_resource_customer_acceptance_resource_online" } - }, - "required": ["data", "has_more", "object", "url"], - "title": "SubscriptionList", - "type": "object", - "x-expandableFields": ["data"] + ], + "description": "If this is a Mandate accepted online, this hash contains details about the online acceptance.", + "nullable": true }, - "tax_exempt": { - "description": "Describes the customer's tax exemption status. One of `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the text **\"Reverse charge\"**.", - "enum": ["exempt", "none", "reverse"], + "type": { + "description": "The type of customer acceptance information included with the Mandate.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "ConfirmationTokensResourceMandateDataResourceCustomerAcceptance", + "type": "object", + "x-expandableFields": ["online"] + }, + "confirmation_tokens_resource_mandate_data_resource_customer_acceptance_resource_online": { + "description": "This hash contains details about the online acceptance.", + "properties": { + "ip_address": { + "description": "The IP address from which the Mandate was accepted by the customer.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "tax_ids": { - "description": "The customer's tax IDs.", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/tax_id" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" + "user_agent": { + "description": "The user agent of the browser from which the Mandate was accepted by the customer.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "ConfirmationTokensResourceMandateDataResourceCustomerAcceptanceResourceOnline", + "type": "object", + "x-expandableFields": [] + }, + "confirmation_tokens_resource_payment_method_options": { + "description": "Payment-method-specific configuration", + "properties": { + "card": { + "anyOf": [ + { + "$ref": "#/components/schemas/confirmation_tokens_resource_payment_method_options_resource_card" } - }, - "required": ["data", "has_more", "object", "url"], - "title": "TaxIDsList", - "type": "object", - "x-expandableFields": ["data"] + ], + "description": "This hash contains the card payment method options.", + "nullable": true } }, - "required": ["created", "id", "livemode", "object"], - "title": "Customer", + "title": "ConfirmationTokensResourcePaymentMethodOptions", "type": "object", - "x-expandableFields": [ - "address", - "default_source", - "discount", - "invoice_settings", - "shipping", - "sources", - "subscriptions", - "tax_ids" - ], - "x-resourceId": "customer" + "x-expandableFields": ["card"] }, - "customer_acceptance": { - "description": "", + "confirmation_tokens_resource_payment_method_options_resource_card": { + "description": "This hash contains the card payment method options.", "properties": { - "accepted_at": { - "description": "The time at which the customer accepted the Mandate.", - "format": "unix-time", + "cvc_token": { + "description": "The `cvc_update` Token collected from the Payment Element.", + "maxLength": 5000, "nullable": true, - "type": "integer" - }, - "offline": { - "$ref": "#/components/schemas/offline_acceptance" - }, - "online": { - "$ref": "#/components/schemas/online_acceptance" - }, - "type": { - "description": "The type of customer acceptance information included with the Mandate. One of `online` or `offline`.", - "enum": ["offline", "online"], "type": "string" } }, - "required": ["type"], - "title": "customer_acceptance", + "title": "ConfirmationTokensResourcePaymentMethodOptionsResourceCard", "type": "object", - "x-expandableFields": ["offline", "online"] + "x-expandableFields": [] }, - "customer_balance_transaction": { - "description": "Each customer has a [`balance`](https://stripe.com/docs/api/customers/object#customer_object-balance) value,\nwhich denotes a debit or credit that's automatically applied to their next invoice upon finalization.\nYou may modify the value directly by using the [update customer API](https://stripe.com/docs/api/customers/update),\nor by creating a Customer Balance Transaction, which increments or decrements the customer's `balance` by the specified `amount`.\n\nRelated guide: [Customer Balance](https://stripe.com/docs/billing/customer/balance) to learn more.", + "confirmation_tokens_resource_payment_method_preview": { + "description": "Details of the PaymentMethod collected by Payment Element", "properties": { - "amount": { - "description": "The amount of the transaction. A negative value is a credit for the customer's balance, and a positive value is a debit to the customer's `balance`.", - "type": "integer" + "acss_debit": { + "$ref": "#/components/schemas/payment_method_acss_debit" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "affirm": { + "$ref": "#/components/schemas/payment_method_affirm" }, - "credit_note": { + "afterpay_clearpay": { + "$ref": "#/components/schemas/payment_method_afterpay_clearpay" + }, + "alipay": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_alipay" + }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to “unspecified”.", + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "amazon_pay": { + "$ref": "#/components/schemas/payment_method_amazon_pay" + }, + "au_becs_debit": { + "$ref": "#/components/schemas/payment_method_au_becs_debit" + }, + "bacs_debit": { + "$ref": "#/components/schemas/payment_method_bacs_debit" + }, + "bancontact": { + "$ref": "#/components/schemas/payment_method_bancontact" + }, + "billing_details": { + "$ref": "#/components/schemas/billing_details" + }, + "blik": { + "$ref": "#/components/schemas/payment_method_blik" + }, + "boleto": { + "$ref": "#/components/schemas/payment_method_boleto" + }, + "card": { + "$ref": "#/components/schemas/payment_method_card" + }, + "card_present": { + "$ref": "#/components/schemas/payment_method_card_present" + }, + "cashapp": { + "$ref": "#/components/schemas/payment_method_cashapp" + }, + "customer": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/credit_note" + "$ref": "#/components/schemas/customer" } ], - "description": "The ID of the credit note (if any) related to the transaction.", + "description": "The ID of the Customer to which this PaymentMethod is saved. This will not be set when the PaymentMethod has not been saved to a Customer.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/credit_note" + "$ref": "#/components/schemas/customer" } ] } }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "customer_balance": { + "$ref": "#/components/schemas/payment_method_customer_balance" + }, + "eps": { + "$ref": "#/components/schemas/payment_method_eps" + }, + "fpx": { + "$ref": "#/components/schemas/payment_method_fpx" + }, + "giropay": { + "$ref": "#/components/schemas/payment_method_giropay" + }, + "grabpay": { + "$ref": "#/components/schemas/payment_method_grabpay" + }, + "ideal": { + "$ref": "#/components/schemas/payment_method_ideal" + }, + "interac_present": { + "$ref": "#/components/schemas/payment_method_interac_present" + }, + "klarna": { + "$ref": "#/components/schemas/payment_method_klarna" + }, + "konbini": { + "$ref": "#/components/schemas/payment_method_konbini" + }, + "link": { + "$ref": "#/components/schemas/payment_method_link" + }, + "mobilepay": { + "$ref": "#/components/schemas/payment_method_mobilepay" + }, + "multibanco": { + "$ref": "#/components/schemas/payment_method_multibanco" + }, + "oxxo": { + "$ref": "#/components/schemas/payment_method_oxxo" + }, + "p24": { + "$ref": "#/components/schemas/payment_method_p24" + }, + "paynow": { + "$ref": "#/components/schemas/payment_method_paynow" + }, + "paypal": { + "$ref": "#/components/schemas/payment_method_paypal" + }, + "pix": { + "$ref": "#/components/schemas/payment_method_pix" + }, + "promptpay": { + "$ref": "#/components/schemas/payment_method_promptpay" + }, + "revolut_pay": { + "$ref": "#/components/schemas/payment_method_revolut_pay" + }, + "sepa_debit": { + "$ref": "#/components/schemas/payment_method_sepa_debit" + }, + "sofort": { + "$ref": "#/components/schemas/payment_method_sofort" + }, + "swish": { + "$ref": "#/components/schemas/payment_method_swish" + }, + "twint": { + "$ref": "#/components/schemas/payment_method_twint" + }, + "type": { + "description": "The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.", + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "card_present", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "interac_present", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "$ref": "#/components/schemas/payment_method_us_bank_account" + }, + "wechat_pay": { + "$ref": "#/components/schemas/payment_method_wechat_pay" + }, + "zip": { + "$ref": "#/components/schemas/payment_method_zip" + } + }, + "required": ["billing_details", "type"], + "title": "ConfirmationTokensResourcePaymentMethodPreview", + "type": "object", + "x-expandableFields": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "billing_details", + "blik", + "boleto", + "card", + "card_present", + "cashapp", + "customer", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "interac_present", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ] + }, + "confirmation_tokens_resource_shipping": { + "description": "", + "properties": { + "address": { + "$ref": "#/components/schemas/address" + }, + "name": { + "description": "Recipient name.", + "maxLength": 5000, "type": "string" }, - "customer": { + "phone": { + "description": "Recipient phone (including extension).", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["address", "name"], + "title": "ConfirmationTokensResourceShipping", + "type": "object", + "x-expandableFields": ["address"] + }, + "connect_account_reference": { + "description": "", + "properties": { + "account": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/account" } ], - "description": "The ID of the customer the transaction belongs to.", + "description": "The connected account being referenced when `type` is `account`.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/account" } ] } }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 5000, - "nullable": true, + "type": { + "description": "Type of the account referenced.", + "enum": ["account", "self"], "type": "string" - }, - "ending_balance": { - "description": "The customer's `balance` after the transaction was applied. A negative value decreases the amount due on the customer's next invoice. A positive value increases the amount due on the customer's next invoice.", + } + }, + "required": ["type"], + "title": "ConnectAccountReference", + "type": "object", + "x-expandableFields": ["account"] + }, + "connect_collection_transfer": { + "description": "", + "properties": { + "amount": { + "description": "Amount transferred, in cents (or local equivalent).", "type": "integer" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, - "invoice": { + "destination": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/invoice" + "$ref": "#/components/schemas/account" } ], - "description": "The ID of the invoice (if any) related to the transaction.", - "nullable": true, + "description": "ID of the account that funds are being collected for.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/invoice" + "$ref": "#/components/schemas/account" } ] } }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, - "type": "object" - }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["customer_balance_transaction"], - "type": "string" - }, - "type": { - "description": "Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types.", - "enum": [ - "adjustment", - "applied_to_invoice", - "credit_note", - "initial", - "invoice_too_large", - "invoice_too_small", - "migration", - "unapplied_from_invoice", - "unspent_receiver_credit" - ], + "enum": ["connect_collection_transfer"], "type": "string" } }, "required": [ "amount", - "created", "currency", - "customer", - "ending_balance", + "destination", "id", "livemode", - "object", - "type" + "object" ], - "title": "CustomerBalanceTransaction", + "title": "ConnectCollectionTransfer", "type": "object", - "x-expandableFields": ["credit_note", "customer", "invoice"], - "x-resourceId": "customer_balance_transaction" + "x-expandableFields": ["destination"] }, - "deleted_account": { + "connect_embedded_account_config_claim": { "description": "", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], + "enabled": { + "description": "Whether the embedded component is enabled.", "type": "boolean" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["account"], - "type": "string" + "features": { + "$ref": "#/components/schemas/connect_embedded_account_features_claim" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedAccount", + "required": ["enabled", "features"], + "title": "ConnectEmbeddedAccountConfigClaim", "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_account" + "x-expandableFields": ["features"] }, - "deleted_alipay_account": { + "connect_embedded_account_features_claim": { "description": "", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], + "external_account_collection": { + "description": "Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.", "type": "boolean" + } + }, + "required": ["external_account_collection"], + "title": "ConnectEmbeddedAccountFeaturesClaim", + "type": "object", + "x-expandableFields": [] + }, + "connect_embedded_account_session_create_components": { + "description": "", + "properties": { + "account_management": { + "$ref": "#/components/schemas/connect_embedded_account_config_claim" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "account_onboarding": { + "$ref": "#/components/schemas/connect_embedded_account_config_claim" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["alipay_account"], - "type": "string" + "balances": { + "$ref": "#/components/schemas/connect_embedded_payouts_config_claim" + }, + "documents": { + "$ref": "#/components/schemas/connect_embedded_base_config_claim" + }, + "notification_banner": { + "$ref": "#/components/schemas/connect_embedded_account_config_claim" + }, + "payment_details": { + "$ref": "#/components/schemas/connect_embedded_payments_config_claim" + }, + "payments": { + "$ref": "#/components/schemas/connect_embedded_payments_config_claim" + }, + "payouts": { + "$ref": "#/components/schemas/connect_embedded_payouts_config_claim" + }, + "payouts_list": { + "$ref": "#/components/schemas/connect_embedded_base_config_claim" + }, + "tax_registrations": { + "$ref": "#/components/schemas/connect_embedded_base_config_claim" + }, + "tax_settings": { + "$ref": "#/components/schemas/connect_embedded_base_config_claim" } }, - "required": ["deleted", "id", "object"], - "title": "AlipayDeletedAccount", + "required": [ + "account_management", + "account_onboarding", + "balances", + "documents", + "notification_banner", + "payment_details", + "payments", + "payouts", + "payouts_list", + "tax_registrations", + "tax_settings" + ], + "title": "ConnectEmbeddedAccountSessionCreateComponents", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [ + "account_management", + "account_onboarding", + "balances", + "documents", + "notification_banner", + "payment_details", + "payments", + "payouts", + "payouts_list", + "tax_registrations", + "tax_settings" + ] }, - "deleted_apple_pay_domain": { + "connect_embedded_base_config_claim": { "description": "", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], + "enabled": { + "description": "Whether the embedded component is enabled.", "type": "boolean" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "features": { + "$ref": "#/components/schemas/connect_embedded_base_features" + } + }, + "required": ["enabled", "features"], + "title": "ConnectEmbeddedBaseConfigClaim", + "type": "object", + "x-expandableFields": ["features"] + }, + "connect_embedded_base_features": { + "description": "", + "properties": {}, + "title": "ConnectEmbeddedBaseFeatures", + "type": "object", + "x-expandableFields": [] + }, + "connect_embedded_payments_config_claim": { + "description": "", + "properties": { + "enabled": { + "description": "Whether the embedded component is enabled.", + "type": "boolean" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["apple_pay_domain"], - "type": "string" + "features": { + "$ref": "#/components/schemas/connect_embedded_payments_features" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedApplePayDomain", + "required": ["enabled", "features"], + "title": "ConnectEmbeddedPaymentsConfigClaim", "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_apple_pay_domain" + "x-expandableFields": ["features"] }, - "deleted_bank_account": { + "connect_embedded_payments_features": { "description": "", "properties": { - "currency": { - "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "capture_payments": { + "description": "Whether to allow capturing and cancelling payment intents. This is `true` by default.", + "type": "boolean" }, - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], + "destination_on_behalf_of_charge_management": { + "description": "Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.", "type": "boolean" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "dispute_management": { + "description": "Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.", + "type": "boolean" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["bank_account"], - "type": "string" + "refund_management": { + "description": "Whether to allow sending refunds. This is `true` by default.", + "type": "boolean" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedBankAccount", + "required": [ + "capture_payments", + "destination_on_behalf_of_charge_management", + "dispute_management", + "refund_management" + ], + "title": "ConnectEmbeddedPaymentsFeatures", "type": "object", "x-expandableFields": [] }, - "deleted_bitcoin_receiver": { + "connect_embedded_payouts_config_claim": { "description": "", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], + "enabled": { + "description": "Whether the embedded component is enabled.", "type": "boolean" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "features": { + "$ref": "#/components/schemas/connect_embedded_payouts_features" + } + }, + "required": ["enabled", "features"], + "title": "ConnectEmbeddedPayoutsConfigClaim", + "type": "object", + "x-expandableFields": ["features"] + }, + "connect_embedded_payouts_features": { + "description": "", + "properties": { + "edit_payout_schedule": { + "description": "Whether to allow payout schedule to be changed. Default `true` when Stripe owns Loss Liability, default `false` otherwise.", + "type": "boolean" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["bitcoin_receiver"], - "type": "string" + "external_account_collection": { + "description": "Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.", + "type": "boolean" + }, + "instant_payouts": { + "description": "Whether to allow creation of instant payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.", + "type": "boolean" + }, + "standard_payouts": { + "description": "Whether to allow creation of standard payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.", + "type": "boolean" } }, - "required": ["deleted", "id", "object"], - "title": "BitcoinDeletedReceiver", + "required": [ + "edit_payout_schedule", + "external_account_collection", + "instant_payouts", + "standard_payouts" + ], + "title": "ConnectEmbeddedPayoutsFeatures", "type": "object", "x-expandableFields": [] }, - "deleted_card": { - "description": "", + "country_spec": { + "description": "Stripe needs to collect certain pieces of information about each account\ncreated. These requirements can differ depending on the account's country. The\nCountry Specs API makes these rules available to your integration.\n\nYou can also view the information from this API call as [an online\nguide](/docs/connect/required-verification-information).", "properties": { - "currency": { - "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account.", + "default_currency": { + "description": "The default currency for this country. This applies to both payment methods and bank accounts.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" - }, "id": { - "description": "Unique identifier for the object.", + "description": "Unique identifier for the object. Represented as the ISO country code for this country.", "maxLength": 5000, "type": "string" }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["card"], + "enum": ["country_spec"], "type": "string" + }, + "supported_bank_account_currencies": { + "additionalProperties": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "description": "Currencies that can be accepted in the specific country (for transfers).", + "type": "object" + }, + "supported_payment_currencies": { + "description": "Currencies that can be accepted in the specified country (for payments).", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "supported_payment_methods": { + "description": "Payment methods available in the specified country. You may need to enable some payment methods (e.g., [ACH](https://stripe.com/docs/ach)) on your account before they appear in this list. The `stripe` payment method refers to [charging through your platform](https://stripe.com/docs/connect/destination-charges).", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "supported_transfer_countries": { + "description": "Countries that can accept transfers from the specified country.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "verification_fields": { + "$ref": "#/components/schemas/country_spec_verification_fields" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedCard", + "required": [ + "default_currency", + "id", + "object", + "supported_bank_account_currencies", + "supported_payment_currencies", + "supported_payment_methods", + "supported_transfer_countries", + "verification_fields" + ], + "title": "CountrySpec", + "type": "object", + "x-expandableFields": ["verification_fields"], + "x-resourceId": "country_spec" + }, + "country_spec_verification_field_details": { + "description": "", + "properties": { + "additional": { + "description": "Additional fields which are only required for some users.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "minimum": { + "description": "Fields which every account must eventually provide.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "required": ["additional", "minimum"], + "title": "CountrySpecVerificationFieldDetails", "type": "object", "x-expandableFields": [] }, - "deleted_coupon": { + "country_spec_verification_fields": { "description": "", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" + "company": { + "$ref": "#/components/schemas/country_spec_verification_field_details" + }, + "individual": { + "$ref": "#/components/schemas/country_spec_verification_field_details" + } + }, + "required": ["company", "individual"], + "title": "CountrySpecVerificationFields", + "type": "object", + "x-expandableFields": ["company", "individual"] + }, + "coupon": { + "description": "A coupon contains information about a percent-off or amount-off discount you\nmight want to apply to a customer. Coupons may be applied to [subscriptions](https://stripe.com/docs/api#subscriptions), [invoices](https://stripe.com/docs/api#invoices),\n[checkout sessions](https://stripe.com/docs/api/checkout/sessions), [quotes](https://stripe.com/docs/api#quotes), and more. Coupons do not work with conventional one-off [charges](https://stripe.com/docs/api#create_charge) or [payment intents](https://stripe.com/docs/api/payment_intents).", + "properties": { + "amount_off": { + "description": "Amount (in the `currency` specified) that will be taken off the subtotal of any invoices for this customer.", + "nullable": true, + "type": "integer" + }, + "applies_to": { + "$ref": "#/components/schemas/coupon_applies_to" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "If `amount_off` has been set, the three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the amount to take off.", + "nullable": true, + "type": "string" + }, + "currency_options": { + "additionalProperties": { + "$ref": "#/components/schemas/coupon_currency_option" + }, + "description": "Coupons defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).", + "type": "object" + }, + "duration": { + "description": "One of `forever`, `once`, and `repeating`. Describes how long a customer who applies this coupon will get the discount.", + "enum": ["forever", "once", "repeating"], + "type": "string", + "x-stripeBypassValidation": true + }, + "duration_in_months": { + "description": "If `duration` is `repeating`, the number of months the coupon applies. Null if coupon `duration` is `forever` or `once`.", + "nullable": true, + "type": "integer" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "max_redemptions": { + "description": "Maximum number of times this coupon can be redeemed, in total, across all customers, before it is no longer valid.", + "nullable": true, + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "name": { + "description": "Name of the coupon displayed to customers on for instance invoices or receipts.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", "enum": ["coupon"], "type": "string" + }, + "percent_off": { + "description": "Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon. For example, a coupon with percent_off of 50 will make a $ (or local equivalent)100 invoice $ (or local equivalent)50 instead.", + "nullable": true, + "type": "number" + }, + "redeem_by": { + "description": "Date after which the coupon can no longer be redeemed.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "times_redeemed": { + "description": "Number of times this coupon has been applied to a customer.", + "type": "integer" + }, + "valid": { + "description": "Taking account of the above properties, whether this coupon can still be applied to a customer.", + "type": "boolean" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedCoupon", + "required": [ + "created", + "duration", + "id", + "livemode", + "object", + "times_redeemed", + "valid" + ], + "title": "Coupon", "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_coupon" + "x-expandableFields": ["applies_to", "currency_options"], + "x-resourceId": "coupon" }, - "deleted_customer": { + "coupon_applies_to": { "description": "", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["customer"], - "type": "string" + "products": { + "description": "A list of product IDs this coupon applies to", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedCustomer", + "required": ["products"], + "title": "CouponAppliesTo", "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_customer" + "x-expandableFields": [] }, - "deleted_discount": { + "coupon_currency_option": { "description": "", "properties": { - "checkout_session": { - "description": "The Checkout session that this coupon is applied to, if it is applied to a particular session in payment mode. Will not be present for subscription mode.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "amount_off": { + "description": "Amount (in the `currency` specified) that will be taken off the subtotal of any invoices for this customer.", + "type": "integer" + } + }, + "required": ["amount_off"], + "title": "CouponCurrencyOption", + "type": "object", + "x-expandableFields": [] + }, + "credit_note": { + "description": "Issue a credit note to adjust an invoice's amount after the invoice is finalized.\n\nRelated guide: [Credit notes](https://stripe.com/docs/billing/invoices/credit-notes)", + "properties": { + "amount": { + "description": "The integer amount in cents (or local equivalent) representing the total amount of the credit note, including tax.", + "type": "integer" }, - "coupon": { - "$ref": "#/components/schemas/coupon" + "amount_shipping": { + "description": "This is the sum of all the shipping amounts.", + "type": "integer" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" }, "customer": { "anyOf": [ @@ -4771,8 +7212,7 @@ "$ref": "#/components/schemas/deleted_customer" } ], - "description": "The ID of the customer associated with this discount.", - "nullable": true, + "description": "ID of the customer.", "x-expansionResources": { "oneOf": [ { @@ -4784,720 +7224,899 @@ ] } }, - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" - }, - "id": { - "description": "The ID of the discount object. Discounts cannot be fetched by ID. Use `expand[]=discounts` in API calls to expand discount IDs in an array.", - "maxLength": 5000, - "type": "string" - }, - "invoice": { - "description": "The invoice that the discount's coupon was applied to, if it was applied directly to a particular invoice.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "invoice_item": { - "description": "The invoice item `id` (or invoice line item `id` for invoice line items of type='subscription') that the discount's coupon was applied to, if it was applied directly to a particular invoice item or invoice line item.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["discount"], - "type": "string" - }, - "promotion_code": { + "customer_balance_transaction": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/promotion_code" + "$ref": "#/components/schemas/customer_balance_transaction" } ], - "description": "The promotion code applied to create this discount.", + "description": "Customer balance transaction related to this credit note.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/promotion_code" + "$ref": "#/components/schemas/customer_balance_transaction" } ] } }, - "start": { - "description": "Date that the coupon was applied.", - "format": "unix-time", + "discount_amount": { + "description": "The integer amount in cents (or local equivalent) representing the total amount of discount that was credited.", "type": "integer" }, - "subscription": { - "description": "The subscription that this coupon is applied to, if it is applied to a particular subscription.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "required": ["coupon", "deleted", "id", "object", "start"], - "title": "DeletedDiscount", - "type": "object", - "x-expandableFields": ["coupon", "customer", "promotion_code"], - "x-resourceId": "deleted_discount" - }, - "deleted_external_account": { - "anyOf": [ - { - "$ref": "#/components/schemas/deleted_bank_account" + "discount_amounts": { + "description": "The aggregate amounts calculated per discount for all line items.", + "items": { + "$ref": "#/components/schemas/discounts_resource_discount_amount" + }, + "type": "array" }, - { - "$ref": "#/components/schemas/deleted_card" - } - ], - "title": "Polymorphic", - "x-resourceId": "deleted_external_account" - }, - "deleted_invoice": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" + "effective_at": { + "description": "The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.", + "format": "unix-time", + "nullable": true, + "type": "integer" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["invoice"], - "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "DeletedInvoice", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_invoice" - }, - "deleted_invoiceitem": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], + "invoice": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/invoice" + } + ], + "description": "ID of the invoice.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/invoice" + } + ] + } + }, + "lines": { + "description": "Line items that make up the credit note", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/credit_note_line_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "CreditNoteLinesList", + "type": "object", + "x-expandableFields": ["data"] + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "id": { - "description": "Unique identifier for the object.", + "memo": { + "description": "Customer-facing text that appears on the credit note PDF.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["invoiceitem"], - "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "DeletedInvoiceItem", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_invoiceitem" - }, - "deleted_payment_source": { - "anyOf": [ - { - "$ref": "#/components/schemas/deleted_alipay_account" - }, - { - "$ref": "#/components/schemas/deleted_bank_account" - }, - { - "$ref": "#/components/schemas/deleted_bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/deleted_card" - } - ], - "title": "Polymorphic", - "x-resourceId": "deleted_payment_source" - }, - "deleted_person": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" }, - "id": { - "description": "Unique identifier for the object.", + "number": { + "description": "A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice.", "maxLength": 5000, "type": "string" }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["person"], + "enum": ["credit_note"], "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "DeletedPerson", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_person" - }, - "deleted_plan": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" }, - "id": { - "description": "Unique identifier for the object.", + "out_of_band_amount": { + "description": "Amount that was credited outside of Stripe.", + "nullable": true, + "type": "integer" + }, + "pdf": { + "description": "The link to download the PDF of the credit note.", "maxLength": 5000, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["plan"], + "reason": { + "description": "Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`", + "enum": [ + "duplicate", + "fraudulent", + "order_change", + "product_unsatisfactory" + ], + "nullable": true, "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "DeletedPlan", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_plan" - }, - "deleted_price": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "refund": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/refund" + } + ], + "description": "Refund related to this credit note.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/refund" + } + ] + } }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["price"], + "shipping_cost": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoices_resource_shipping_cost" + } + ], + "description": "The details of the cost of shipping, including the ShippingRate applied to the invoice.", + "nullable": true + }, + "status": { + "description": "Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding).", + "enum": ["issued", "void"], + "type": "string", + "x-stripeBypassValidation": true + }, + "subtotal": { + "description": "The integer amount in cents (or local equivalent) representing the amount of the credit note, excluding exclusive tax and invoice level discounts.", + "type": "integer" + }, + "subtotal_excluding_tax": { + "description": "The integer amount in cents (or local equivalent) representing the amount of the credit note, excluding all tax and invoice level discounts.", + "nullable": true, + "type": "integer" + }, + "tax_amounts": { + "description": "The aggregate amounts calculated per tax rate for all line items.", + "items": { + "$ref": "#/components/schemas/credit_note_tax_amount" + }, + "type": "array" + }, + "total": { + "description": "The integer amount in cents (or local equivalent) representing the total amount of the credit note, including tax and all discount.", + "type": "integer" + }, + "total_excluding_tax": { + "description": "The integer amount in cents (or local equivalent) representing the total amount of the credit note, excluding tax, but including discounts.", + "nullable": true, + "type": "integer" + }, + "type": { + "description": "Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid.", + "enum": ["post_payment", "pre_payment"], "type": "string" + }, + "voided_at": { + "description": "The time that the credit note was voided.", + "format": "unix-time", + "nullable": true, + "type": "integer" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedPrice", + "required": [ + "amount", + "amount_shipping", + "created", + "currency", + "customer", + "discount_amount", + "discount_amounts", + "id", + "invoice", + "lines", + "livemode", + "number", + "object", + "pdf", + "status", + "subtotal", + "tax_amounts", + "total", + "type" + ], + "title": "CreditNote", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [ + "customer", + "customer_balance_transaction", + "discount_amounts", + "invoice", + "lines", + "refund", + "shipping_cost", + "tax_amounts" + ], + "x-resourceId": "credit_note" }, - "deleted_product": { - "description": "", + "credit_note_line_item": { + "description": "The credit note line item object", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" + "amount": { + "description": "The integer amount in cents (or local equivalent) representing the gross amount being credited for this line item, excluding (exclusive) tax and discounts.", + "type": "integer" }, - "id": { - "description": "Unique identifier for the object.", + "amount_excluding_tax": { + "description": "The integer amount in cents (or local equivalent) representing the amount being credited for this line item, excluding all tax and discounts.", + "nullable": true, + "type": "integer" + }, + "description": { + "description": "Description of the item being credited.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["product"], - "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "DeletedProduct", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_product" - }, - "deleted_radar.value_list": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" + "discount_amount": { + "description": "The integer amount in cents (or local equivalent) representing the discount being credited for this line item.", + "type": "integer" + }, + "discount_amounts": { + "description": "The amount of discount calculated per discount for this line item", + "items": { + "$ref": "#/components/schemas/discounts_resource_discount_amount" + }, + "type": "array" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, + "invoice_line_item": { + "description": "ID of the invoice line item being credited", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["radar.value_list"], + "enum": ["credit_note_line_item"], "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "RadarListDeletedList", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_radar.value_list" - }, - "deleted_radar.value_list_item": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "quantity": { + "description": "The number of units of product being credited.", + "nullable": true, + "type": "integer" + }, + "tax_amounts": { + "description": "The amount of tax calculated per tax rate for this line item", + "items": { + "$ref": "#/components/schemas/credit_note_tax_amount" + }, + "type": "array" + }, + "tax_rates": { + "description": "The tax rates which apply to the line item.", + "items": { + "$ref": "#/components/schemas/tax_rate" + }, + "type": "array" + }, + "type": { + "description": "The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice.", + "enum": ["custom_line_item", "invoice_line_item"], "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["radar.value_list_item"], + "unit_amount": { + "description": "The cost of each unit of product being credited.", + "nullable": true, + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.", + "format": "decimal", + "nullable": true, + "type": "string" + }, + "unit_amount_excluding_tax": { + "description": "The amount in cents (or local equivalent) representing the unit amount being credited for this line item, excluding all tax and discounts.", + "format": "decimal", + "nullable": true, "type": "string" } }, - "required": ["deleted", "id", "object"], - "title": "RadarListDeletedListItem", + "required": [ + "amount", + "discount_amount", + "discount_amounts", + "id", + "livemode", + "object", + "tax_amounts", + "tax_rates", + "type" + ], + "title": "CreditNoteLineItem", "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_radar.value_list_item" + "x-expandableFields": ["discount_amounts", "tax_amounts", "tax_rates"], + "x-resourceId": "credit_note_line_item" }, - "deleted_recipient": { + "credit_note_tax_amount": { "description": "", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], + "amount": { + "description": "The amount, in cents (or local equivalent), of the tax.", + "type": "integer" + }, + "inclusive": { + "description": "Whether this tax amount is inclusive or exclusive.", "type": "boolean" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "tax_rate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_rate" + } + ], + "description": "The tax rate that was applied to get this tax amount.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_rate" + } + ] + } }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["recipient"], - "type": "string" + "taxability_reason": { + "description": "The reasoning behind this tax, for example, if the product is tax exempt. The possible values for this field may be extended as new tax rules are supported.", + "enum": [ + "customer_exempt", + "not_collecting", + "not_subject_to_tax", + "not_supported", + "portion_product_exempt", + "portion_reduced_rated", + "portion_standard_rated", + "product_exempt", + "product_exempt_holiday", + "proportionally_rated", + "reduced_rated", + "reverse_charge", + "standard_rated", + "taxable_basis_reduced", + "zero_rated" + ], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "taxable_amount": { + "description": "The amount on which tax is calculated, in cents (or local equivalent).", + "nullable": true, + "type": "integer" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedTransferRecipient", + "required": ["amount", "inclusive", "tax_rate"], + "title": "CreditNoteTaxAmount", "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_recipient" + "x-expandableFields": ["tax_rate"] }, - "deleted_sku": { + "currency_option": { "description": "", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" + "custom_unit_amount": { + "anyOf": [ + { + "$ref": "#/components/schemas/custom_unit_amount" + } + ], + "description": "When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.", + "nullable": true }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": ["exclusive", "inclusive", "unspecified"], + "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["sku"], + "tiers": { + "description": "Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.", + "items": { + "$ref": "#/components/schemas/price_tier" + }, + "type": "array" + }, + "unit_amount": { + "description": "The unit amount in cents (or local equivalent) to be charged, represented as a whole integer if possible. Only set if `billing_scheme=per_unit`.", + "nullable": true, + "type": "integer" + }, + "unit_amount_decimal": { + "description": "The unit amount in cents (or local equivalent) to be charged, represented as a decimal string with at most 12 decimal places. Only set if `billing_scheme=per_unit`.", + "format": "decimal", + "nullable": true, "type": "string" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedSku", + "title": "CurrencyOption", "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_sku" + "x-expandableFields": ["custom_unit_amount", "tiers"] }, - "deleted_subscription_item": { + "custom_unit_amount": { "description": "", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" + "maximum": { + "description": "The maximum unit amount the customer can specify for this item.", + "nullable": true, + "type": "integer" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "minimum": { + "description": "The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.", + "nullable": true, + "type": "integer" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["subscription_item"], - "type": "string" + "preset": { + "description": "The starting unit amount which can be updated by the customer.", + "nullable": true, + "type": "integer" } }, - "required": ["deleted", "id", "object"], - "title": "DeletedSubscriptionItem", + "title": "CustomUnitAmount", "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_subscription_item" + "x-expandableFields": [] }, - "deleted_tax_id": { - "description": "", + "customer": { + "description": "This object represents a customer of your business. Use it to create recurring charges and track payments that belong to the same customer.\n\nRelated guide: [Save a card during payment](https://stripe.com/docs/payments/save-during-payment)", "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["tax_id"], - "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "deleted_tax_id", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_tax_id" - }, - "deleted_terminal.location": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["terminal.location"], - "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "TerminalLocationDeletedLocation", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_terminal.location" - }, - "deleted_terminal.reader": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["terminal.reader"], - "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "TerminalReaderDeletedReader", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_terminal.reader" - }, - "deleted_webhook_endpoint": { - "description": "", - "properties": { - "deleted": { - "description": "Always true for a deleted object", - "enum": [true], - "type": "boolean" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "address": { + "anyOf": [ + { + "$ref": "#/components/schemas/address" + } + ], + "description": "The customer's address.", + "nullable": true }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["webhook_endpoint"], - "type": "string" - } - }, - "required": ["deleted", "id", "object"], - "title": "NotificationWebhookEndpointDeleted", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "deleted_webhook_endpoint" - }, - "delivery_estimate": { - "description": "", - "properties": { - "date": { - "description": "If `type` is `\"exact\"`, `date` will be the expected delivery date in the format YYYY-MM-DD.", - "maxLength": 5000, - "type": "string" + "balance": { + "description": "The current balance, if any, that's stored on the customer. If negative, the customer has credit to apply to their next invoice. If positive, the customer has an amount owed that's added to their next invoice. The balance only considers amounts that Stripe hasn't successfully applied to any invoice. It doesn't reflect unpaid invoices. This balance is only taken into account after invoices finalize.", + "type": "integer" }, - "earliest": { - "description": "If `type` is `\"range\"`, `earliest` will be be the earliest delivery date in the format YYYY-MM-DD.", - "maxLength": 5000, - "type": "string" + "cash_balance": { + "anyOf": [ + { + "$ref": "#/components/schemas/cash_balance" + } + ], + "description": "The current funds being held by Stripe on behalf of the customer. You can apply these funds towards payment intents when the source is \"cash_balance\". The `settings[reconciliation_mode]` field describes if these funds apply to these payment intents manually or automatically.", + "nullable": true }, - "latest": { - "description": "If `type` is `\"range\"`, `latest` will be the latest delivery date in the format YYYY-MM-DD.", - "maxLength": 5000, - "type": "string" + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" }, - "type": { - "description": "The type of estimate. Must be either `\"range\"` or `\"exact\"`.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["type"], - "title": "DeliveryEstimate", - "type": "object", - "x-expandableFields": [] - }, - "discount": { - "description": "A discount represents the actual application of a coupon to a particular\ncustomer. It contains information about when the discount began and when it\nwill end.\n\nRelated guide: [Applying Discounts to Subscriptions](https://stripe.com/docs/billing/subscriptions/discounts).", - "properties": { - "checkout_session": { - "description": "The Checkout session that this coupon is applied to, if it is applied to a particular session in payment mode. Will not be present for subscription mode.", + "currency": { + "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) the customer can be charged in for recurring billing purposes.", "maxLength": 5000, "nullable": true, "type": "string" }, - "coupon": { - "$ref": "#/components/schemas/coupon" - }, - "customer": { + "default_source": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/bank_account" }, { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/source" } ], - "description": "The ID of the customer associated with this discount.", + "description": "ID of the default payment source for the customer.\n\nIf you use payment methods created through the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) field instead.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/bank_account" }, { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/source" } ] - } + }, + "x-stripeBypassValidation": true }, - "end": { - "description": "If the coupon has a duration of `repeating`, the date that this discount will end. If the coupon has a duration of `once` or `forever`, this attribute will be null.", - "format": "unix-time", + "delinquent": { + "description": "Tracks the most recent state change on any invoice belonging to the customer. Paying an invoice or marking it uncollectible via the API will set this field to false. An automatic payment failure or passing the `invoice.due_date` will set this field to `true`.\n\nIf an invoice becomes uncollectible by [dunning](https://stripe.com/docs/billing/automatic-collection), `delinquent` doesn't reset to `false`.\n\nIf you care whether the customer has paid their most recent subscription invoice, use `subscription.status` instead. Paying or marking uncollectible any customer invoice regardless of whether it is the latest invoice for a subscription will always set this field to `false`.", "nullable": true, - "type": "integer" + "type": "boolean" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "discount": { + "anyOf": [ + { + "$ref": "#/components/schemas/discount" + } + ], + "description": "Describes the current discount active on the customer, if there is one.", + "nullable": true + }, + "email": { + "description": "The customer's email address.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, "id": { - "description": "The ID of the discount object. Discounts cannot be fetched by ID. Use `expand[]=discounts` in API calls to expand discount IDs in an array.", + "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "invoice": { - "description": "The invoice that the discount's coupon was applied to, if it was applied directly to a particular invoice.", + "invoice_credit_balance": { + "additionalProperties": { + "type": "integer" + }, + "description": "The current multi-currency balances, if any, that's stored on the customer. If positive in a currency, the customer has a credit to apply to their next invoice denominated in that currency. If negative, the customer has an amount owed that's added to their next invoice denominated in that currency. These balances don't apply to unpaid invoices. They solely track amounts that Stripe hasn't successfully applied to any invoice. Stripe only applies a balance in a specific currency to an invoice after that invoice (which is in the same currency) finalizes.", + "type": "object" + }, + "invoice_prefix": { + "description": "The prefix for the customer used to generate unique invoice numbers.", "maxLength": 5000, "nullable": true, "type": "string" }, - "invoice_item": { - "description": "The invoice item `id` (or invoice line item `id` for invoice line items of type='subscription') that the discount's coupon was applied to, if it was applied directly to a particular invoice item or invoice line item.", + "invoice_settings": { + "$ref": "#/components/schemas/invoice_setting_customer_setting" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "name": { + "description": "The customer's full name or business name.", "maxLength": 5000, "nullable": true, "type": "string" }, + "next_invoice_sequence": { + "description": "The suffix of the customer's next invoice number (for example, 0001). When the account uses account level sequencing, this parameter is ignored in API requests and the field omitted in API responses.", + "type": "integer" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["discount"], + "enum": ["customer"], "type": "string" }, - "promotion_code": { + "phone": { + "description": "The customer's phone number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "preferred_locales": { + "description": "The customer's preferred locales (languages), ordered by preference.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "shipping": { + "anyOf": [ + { + "$ref": "#/components/schemas/shipping" + } + ], + "description": "Mailing and shipping address for the customer. Appears on invoices emailed to this customer.", + "nullable": true + }, + "sources": { + "description": "The customer's payment sources, if any.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "anyOf": [ + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/source" + } + ], + "title": "Polymorphic", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ApmsSourcesSourceList", + "type": "object", + "x-expandableFields": ["data"] + }, + "subscriptions": { + "description": "The customer's current subscriptions, if any.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/subscription" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SubscriptionList", + "type": "object", + "x-expandableFields": ["data"] + }, + "tax": { + "$ref": "#/components/schemas/customer_tax" + }, + "tax_exempt": { + "description": "Describes the customer's tax exemption status, which is `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the following text: **\"Reverse charge\"**.", + "enum": ["exempt", "none", "reverse"], + "nullable": true, + "type": "string" + }, + "tax_ids": { + "description": "The customer's tax IDs.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/tax_id" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TaxIDsList", + "type": "object", + "x-expandableFields": ["data"] + }, + "test_clock": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/promotion_code" + "$ref": "#/components/schemas/test_helpers.test_clock" } ], - "description": "The promotion code applied to create this discount.", + "description": "ID of the test clock that this customer belongs to.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/promotion_code" + "$ref": "#/components/schemas/test_helpers.test_clock" } ] } - }, - "start": { - "description": "Date that the coupon was applied.", + } + }, + "required": ["created", "id", "livemode", "object"], + "title": "Customer", + "type": "object", + "x-expandableFields": [ + "address", + "cash_balance", + "default_source", + "discount", + "invoice_settings", + "shipping", + "sources", + "subscriptions", + "tax", + "tax_ids", + "test_clock" + ], + "x-resourceId": "customer" + }, + "customer_acceptance": { + "description": "", + "properties": { + "accepted_at": { + "description": "The time that the customer accepts the mandate.", "format": "unix-time", + "nullable": true, "type": "integer" }, - "subscription": { - "description": "The subscription that this coupon is applied to, if it is applied to a particular subscription.", - "maxLength": 5000, - "nullable": true, + "offline": { + "$ref": "#/components/schemas/offline_acceptance" + }, + "online": { + "$ref": "#/components/schemas/online_acceptance" + }, + "type": { + "description": "The mandate includes the type of customer acceptance information, such as: `online` or `offline`.", + "enum": ["offline", "online"], "type": "string" } }, - "required": ["coupon", "id", "object", "start"], - "title": "Discount", + "required": ["type"], + "title": "customer_acceptance", "type": "object", - "x-expandableFields": ["coupon", "customer", "promotion_code"], - "x-resourceId": "discount" + "x-expandableFields": ["offline", "online"] }, - "discounts_resource_discount_amount": { + "customer_balance_customer_balance_settings": { "description": "", "properties": { - "amount": { - "description": "The amount, in %s, of the discount.", - "type": "integer" + "reconciliation_mode": { + "description": "The configuration for how funds that land in the customer cash balance are reconciled.", + "enum": ["automatic", "manual"], + "type": "string" }, - "discount": { + "using_merchant_default": { + "description": "A flag to indicate if reconciliation mode returned is the user's default or is specific to this customer cash balance", + "type": "boolean" + } + }, + "required": ["reconciliation_mode", "using_merchant_default"], + "title": "CustomerBalanceCustomerBalanceSettings", + "type": "object", + "x-expandableFields": [] + }, + "customer_balance_resource_cash_balance_transaction_resource_adjusted_for_overdraft": { + "description": "", + "properties": { + "balance_transaction": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/discount" - }, - { - "$ref": "#/components/schemas/deleted_discount" + "$ref": "#/components/schemas/balance_transaction" } ], - "description": "The discount that was applied to get this discount amount.", + "description": "The [Balance Transaction](https://stripe.com/docs/api/balance_transactions/object) that corresponds to funds taken out of your Stripe balance.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/discount" - }, - { - "$ref": "#/components/schemas/deleted_discount" + "$ref": "#/components/schemas/balance_transaction" } ] } - } - }, - "required": ["amount", "discount"], - "title": "DiscountsResourceDiscountAmount", - "type": "object", - "x-expandableFields": ["discount"] - }, - "dispute": { - "description": "A dispute occurs when a customer questions your charge with their card issuer.\nWhen this happens, you're given the opportunity to respond to the dispute with\nevidence that shows that the charge is legitimate. You can find more\ninformation about the dispute process in our [Disputes and\nFraud](/docs/disputes) documentation.\n\nRelated guide: [Disputes and Fraud](https://stripe.com/docs/disputes).", - "properties": { - "amount": { - "description": "Disputed amount. Usually the amount of the charge, but can differ (usually because of currency fluctuation or because only part of the order is disputed).", - "type": "integer" - }, - "balance_transactions": { - "description": "List of zero, one, or two balance transactions that show funds withdrawn and reinstated to your Stripe account as a result of this dispute.", - "items": { - "$ref": "#/components/schemas/balance_transaction" - }, - "type": "array" }, - "charge": { + "linked_transaction": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/customer_cash_balance_transaction" } ], - "description": "ID of the charge that was disputed.", + "description": "The [Cash Balance Transaction](https://stripe.com/docs/api/cash_balance_transactions/object) that brought the customer balance negative, triggering the clawback of funds.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/customer_cash_balance_transaction" } ] } - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "evidence": { - "$ref": "#/components/schemas/dispute_evidence" - }, - "evidence_details": { - "$ref": "#/components/schemas/dispute_evidence_details" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "is_charge_refundable": { - "description": "If true, it is still possible to refund the disputed payment. Once the payment has been fully refunded, no further funds will be withdrawn from your Stripe account as a result of this dispute.", - "type": "boolean" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["dispute"], - "type": "string" - }, + } + }, + "required": ["balance_transaction", "linked_transaction"], + "title": "CustomerBalanceResourceCashBalanceTransactionResourceAdjustedForOverdraft", + "type": "object", + "x-expandableFields": ["balance_transaction", "linked_transaction"] + }, + "customer_balance_resource_cash_balance_transaction_resource_applied_to_payment_transaction": { + "description": "", + "properties": { "payment_intent": { "anyOf": [ { @@ -5508,8 +8127,7 @@ "$ref": "#/components/schemas/payment_intent" } ], - "description": "ID of the PaymentIntent that was disputed.", - "nullable": true, + "description": "The [Payment Intent](https://stripe.com/docs/api/payment_intents/object) that funds were applied to.", "x-expansionResources": { "oneOf": [ { @@ -5517,399 +8135,436 @@ } ] } + } + }, + "required": ["payment_intent"], + "title": "CustomerBalanceResourceCashBalanceTransactionResourceAppliedToPaymentTransaction", + "type": "object", + "x-expandableFields": ["payment_intent"] + }, + "customer_balance_resource_cash_balance_transaction_resource_funded_transaction": { + "description": "", + "properties": { + "bank_transfer": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer" + } + }, + "required": ["bank_transfer"], + "title": "CustomerBalanceResourceCashBalanceTransactionResourceFundedTransaction", + "type": "object", + "x-expandableFields": ["bank_transfer"] + }, + "customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer": { + "description": "", + "properties": { + "eu_bank_transfer": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer_resource_eu_bank_transfer" }, - "reason": { - "description": "Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Read more about [dispute reasons](https://stripe.com/docs/disputes/categories).", + "gb_bank_transfer": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer_resource_gb_bank_transfer" + }, + "jp_bank_transfer": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer_resource_jp_bank_transfer" + }, + "reference": { + "description": "The user-supplied reference field on the bank transfer.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "status": { - "description": "Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, or `lost`.", + "type": { + "description": "The funding method type used to fund the customer balance. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.", "enum": [ - "charge_refunded", - "lost", - "needs_response", - "under_review", - "warning_closed", - "warning_needs_response", - "warning_under_review", - "won" + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "mx_bank_transfer", + "us_bank_transfer" ], - "type": "string" + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_transfer": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer_resource_us_bank_transfer" } }, - "required": [ - "amount", - "balance_transactions", - "charge", - "created", - "currency", - "evidence", - "evidence_details", - "id", - "is_charge_refundable", - "livemode", - "metadata", - "object", - "reason", - "status" - ], - "title": "Dispute", + "required": ["type"], + "title": "CustomerBalanceResourceCashBalanceTransactionResourceFundedTransactionResourceBankTransfer", "type": "object", "x-expandableFields": [ - "balance_transactions", - "charge", - "evidence", - "evidence_details", - "payment_intent" - ], - "x-resourceId": "dispute" + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "us_bank_transfer" + ] }, - "dispute_evidence": { + "customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer_resource_eu_bank_transfer": { "description": "", "properties": { - "access_activity_log": { - "description": "Any server or activity logs showing proof that the customer accessed or downloaded the purchased digital product. This information should include IP addresses, corresponding timestamps, and any detailed recorded activity.", - "maxLength": 150000, + "bic": { + "description": "The BIC of the bank of the sender of the funding.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "billing_address": { - "description": "The billing address provided by the customer.", + "iban_last4": { + "description": "The last 4 digits of the IBAN of the sender of the funding.", "maxLength": 5000, "nullable": true, "type": "string" }, - "cancellation_policy": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/file" - } - ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your subscription cancellation policy, as shown to the customer.", + "sender_name": { + "description": "The full name of the sender, as supplied by the sending bank.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/file" - } - ] - } - }, - "cancellation_policy_disclosure": { - "description": "An explanation of how and when the customer was shown your refund policy prior to purchase.", - "maxLength": 150000, + "type": "string" + } + }, + "title": "CustomerBalanceResourceCashBalanceTransactionResourceFundedTransactionResourceBankTransferResourceEuBankTransfer", + "type": "object", + "x-expandableFields": [] + }, + "customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer_resource_gb_bank_transfer": { + "description": "", + "properties": { + "account_number_last4": { + "description": "The last 4 digits of the account number of the sender of the funding.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "cancellation_rebuttal": { - "description": "A justification for why the customer's subscription was not canceled.", - "maxLength": 150000, + "sender_name": { + "description": "The full name of the sender, as supplied by the sending bank.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "customer_communication": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/file" - } - ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any communication with the customer that you feel is relevant to your case. Examples include emails proving that the customer received the product or service, or demonstrating their use of or satisfaction with the product or service.", + "sort_code": { + "description": "The sort code of the bank of the sender of the funding", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/file" - } - ] - } - }, - "customer_email_address": { - "description": "The email address of the customer.", + "type": "string" + } + }, + "title": "CustomerBalanceResourceCashBalanceTransactionResourceFundedTransactionResourceBankTransferResourceGbBankTransfer", + "type": "object", + "x-expandableFields": [] + }, + "customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer_resource_jp_bank_transfer": { + "description": "", + "properties": { + "sender_bank": { + "description": "The name of the bank of the sender of the funding.", "maxLength": 5000, "nullable": true, "type": "string" }, - "customer_name": { - "description": "The name of the customer.", + "sender_branch": { + "description": "The name of the bank branch of the sender of the funding.", "maxLength": 5000, "nullable": true, "type": "string" }, - "customer_purchase_ip": { - "description": "The IP address that the customer used when making the purchase.", + "sender_name": { + "description": "The full name of the sender, as supplied by the sending bank.", "maxLength": 5000, "nullable": true, "type": "string" + } + }, + "title": "CustomerBalanceResourceCashBalanceTransactionResourceFundedTransactionResourceBankTransferResourceJpBankTransfer", + "type": "object", + "x-expandableFields": [] + }, + "customer_balance_resource_cash_balance_transaction_resource_funded_transaction_resource_bank_transfer_resource_us_bank_transfer": { + "description": "", + "properties": { + "network": { + "description": "The banking network used for this funding.", + "enum": ["ach", "domestic_wire_us", "swift"], + "type": "string" }, - "customer_signature": { + "sender_name": { + "description": "The full name of the sender, as supplied by the sending bank.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "CustomerBalanceResourceCashBalanceTransactionResourceFundedTransactionResourceBankTransferResourceUsBankTransfer", + "type": "object", + "x-expandableFields": [] + }, + "customer_balance_resource_cash_balance_transaction_resource_refunded_from_payment_transaction": { + "description": "", + "properties": { + "refund": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/refund" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A relevant document or contract showing the customer's signature.", - "nullable": true, + "description": "The [Refund](https://stripe.com/docs/api/refunds/object) that moved these funds into the customer's cash balance.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/refund" } ] } - }, - "duplicate_charge_documentation": { + } + }, + "required": ["refund"], + "title": "CustomerBalanceResourceCashBalanceTransactionResourceRefundedFromPaymentTransaction", + "type": "object", + "x-expandableFields": ["refund"] + }, + "customer_balance_resource_cash_balance_transaction_resource_transferred_to_balance": { + "description": "", + "properties": { + "balance_transaction": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/balance_transaction" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation for the prior charge that can uniquely identify the charge, such as a receipt, shipping label, work order, etc. This document should be paired with a similar document from the disputed payment that proves the two payments are separate.", - "nullable": true, + "description": "The [Balance Transaction](https://stripe.com/docs/api/balance_transactions/object) that corresponds to funds transferred to your Stripe balance.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/balance_transaction" } ] } - }, - "duplicate_charge_explanation": { - "description": "An explanation of the difference between the disputed charge versus the prior charge that appears to be a duplicate.", - "maxLength": 150000, - "nullable": true, - "type": "string" - }, - "duplicate_charge_id": { - "description": "The Stripe ID for the prior charge which appears to be a duplicate of the disputed charge.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "product_description": { - "description": "A description of the product or service that was sold.", - "maxLength": 150000, - "nullable": true, - "type": "string" - }, - "receipt": { + } + }, + "required": ["balance_transaction"], + "title": "CustomerBalanceResourceCashBalanceTransactionResourceTransferredToBalance", + "type": "object", + "x-expandableFields": ["balance_transaction"] + }, + "customer_balance_resource_cash_balance_transaction_resource_unapplied_from_payment_transaction": { + "description": "", + "properties": { + "payment_intent": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/payment_intent" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any receipt or message sent to the customer notifying them of the charge.", - "nullable": true, + "description": "The [Payment Intent](https://stripe.com/docs/api/payment_intents/object) that funds were unapplied from.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/payment_intent" } ] } + } + }, + "required": ["payment_intent"], + "title": "CustomerBalanceResourceCashBalanceTransactionResourceUnappliedFromPaymentTransaction", + "type": "object", + "x-expandableFields": ["payment_intent"] + }, + "customer_balance_transaction": { + "description": "Each customer has a [Balance](https://stripe.com/docs/api/customers/object#customer_object-balance) value,\nwhich denotes a debit or credit that's automatically applied to their next invoice upon finalization.\nYou may modify the value directly by using the [update customer API](https://stripe.com/docs/api/customers/update),\nor by creating a Customer Balance Transaction, which increments or decrements the customer's `balance` by the specified `amount`.\n\nRelated guide: [Customer balance](https://stripe.com/docs/billing/customer/balance)", + "properties": { + "amount": { + "description": "The amount of the transaction. A negative value is a credit for the customer's balance, and a positive value is a debit to the customer's `balance`.", + "type": "integer" }, - "refund_policy": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "credit_note": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/credit_note" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your refund policy, as shown to the customer.", + "description": "The ID of the credit note (if any) related to the transaction.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/credit_note" } ] } }, - "refund_policy_disclosure": { - "description": "Documentation demonstrating that the customer was shown your refund policy prior to purchase.", - "maxLength": 150000, - "nullable": true, - "type": "string" - }, - "refund_refusal_explanation": { - "description": "A justification for why the customer is not entitled to a refund.", - "maxLength": 150000, - "nullable": true, - "type": "string" - }, - "service_date": { - "description": "The date on which the customer received or began receiving the purchased service, in a clear human-readable format.", - "maxLength": 5000, - "nullable": true, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, - "service_documentation": { + "customer": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/customer" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a service was provided to the customer. This could include a copy of a signed contract, work order, or other form of written agreement.", - "nullable": true, + "description": "The ID of the customer the transaction belongs to.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/customer" } ] } }, - "shipping_address": { - "description": "The address to which a physical product was shipped. You should try to include as complete address information as possible.", + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", "maxLength": 5000, "nullable": true, "type": "string" }, - "shipping_carrier": { - "description": "The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc. If multiple carriers were used for this purchase, please separate them with commas.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "ending_balance": { + "description": "The customer's `balance` after the transaction was applied. A negative value decreases the amount due on the customer's next invoice. A positive value increases the amount due on the customer's next invoice.", + "type": "integer" }, - "shipping_date": { - "description": "The date on which a physical product began its route to the shipping address, in a clear human-readable format.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "shipping_documentation": { + "invoice": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/invoice" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a product was shipped to the customer at the same address the customer provided to you. This could include a copy of the shipment receipt, shipping label, etc. It should show the customer's full shipping address, if possible.", + "description": "The ID of the invoice (if any) related to the transaction.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/invoice" } ] } }, - "shipping_tracking_number": { - "description": "The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.", - "maxLength": 5000, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", "nullable": true, + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["customer_balance_transaction"], "type": "string" }, - "uncategorized_file": { + "type": { + "description": "Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_overpaid`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, or `unapplied_from_invoice`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types.", + "enum": [ + "adjustment", + "applied_to_invoice", + "credit_note", + "initial", + "invoice_overpaid", + "invoice_too_large", + "invoice_too_small", + "migration", + "unapplied_from_invoice", + "unspent_receiver_credit" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "amount", + "created", + "currency", + "customer", + "ending_balance", + "id", + "livemode", + "object", + "type" + ], + "title": "CustomerBalanceTransaction", + "type": "object", + "x-expandableFields": ["credit_note", "customer", "invoice"], + "x-resourceId": "customer_balance_transaction" + }, + "customer_cash_balance_transaction": { + "description": "Customers with certain payments enabled have a cash balance, representing funds that were paid\nby the customer to a merchant, but have not yet been allocated to a payment. Cash Balance Transactions\nrepresent when funds are moved into or out of this balance. This includes funding by the customer, allocation\nto payments, and refunds to the customer.", + "properties": { + "adjusted_for_overdraft": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_adjusted_for_overdraft" + }, + "applied_to_payment": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_applied_to_payment_transaction" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "maxLength": 5000, + "type": "string" + }, + "customer": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/customer" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any additional evidence or statements.", - "nullable": true, + "description": "The customer whose available cash balance changed as a result of this transaction.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/customer" } ] } }, - "uncategorized_text": { - "description": "Any additional evidence or statements.", - "maxLength": 150000, - "nullable": true, - "type": "string" - } - }, - "title": "DisputeEvidence", - "type": "object", - "x-expandableFields": [ - "cancellation_policy", - "customer_communication", - "customer_signature", - "duplicate_charge_documentation", - "receipt", - "refund_policy", - "service_documentation", - "shipping_documentation", - "uncategorized_file" - ] - }, - "dispute_evidence_details": { - "description": "", - "properties": { - "due_by": { - "description": "Date by which evidence must be submitted in order to successfully challenge dispute. Will be null if the customer's bank or credit card company doesn't allow a response for this particular dispute.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "has_evidence": { - "description": "Whether evidence has been staged for this dispute.", - "type": "boolean" - }, - "past_due": { - "description": "Whether the last evidence submission was submitted past the due date. Defaults to `false` if no evidence submissions have occurred. If `true`, then delivery of the latest evidence is *not* guaranteed.", - "type": "boolean" - }, - "submission_count": { - "description": "The number of times evidence has been submitted. Typically, you may only submit evidence once.", - "type": "integer" - } - }, - "required": ["has_evidence", "past_due", "submission_count"], - "title": "DisputeEvidenceDetails", - "type": "object", - "x-expandableFields": [] - }, - "ephemeral_key": { - "description": "", - "properties": { - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", + "ending_balance": { + "description": "The total available cash balance for the specified currency after this transaction was applied. Represented in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", "type": "integer" }, - "expires": { - "description": "Time at which the key will expire. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "funded": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_funded_transaction" }, "id": { "description": "Unique identifier for the object.", @@ -5920,59 +8575,103 @@ "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, + "net_amount": { + "description": "The amount by which the cash balance changed, represented in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). A positive value represents funds being added to the cash balance, a negative value represents funds being removed from the cash balance.", + "type": "integer" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["ephemeral_key"], + "enum": ["customer_cash_balance_transaction"], "type": "string" }, - "secret": { - "description": "The key's secret. You can use this value to make authorized requests to the Stripe API.", - "maxLength": 5000, + "refunded_from_payment": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_refunded_from_payment_transaction" + }, + "transferred_to_balance": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_transferred_to_balance" + }, + "type": { + "description": "The type of the cash balance transaction. New types may be added in future. See [Customer Balance](https://stripe.com/docs/payments/customer-balance#types) to learn more about these types.", + "enum": [ + "adjusted_for_overdraft", + "applied_to_payment", + "funded", + "funding_reversed", + "refunded_from_payment", + "return_canceled", + "return_initiated", + "transferred_to_balance", + "unapplied_from_payment" + ], "type": "string" + }, + "unapplied_from_payment": { + "$ref": "#/components/schemas/customer_balance_resource_cash_balance_transaction_resource_unapplied_from_payment_transaction" } }, - "required": ["created", "expires", "id", "livemode", "object"], - "title": "EphemeralKey", + "required": [ + "created", + "currency", + "customer", + "ending_balance", + "id", + "livemode", + "net_amount", + "object", + "type" + ], + "title": "CustomerCashBalanceTransaction", "type": "object", - "x-expandableFields": [], - "x-resourceId": "ephemeral_key" - }, - "error": { - "description": "An error response from the Stripe API", - "properties": { - "error": { - "$ref": "#/components/schemas/api_errors" - } - }, - "required": ["error"], - "type": "object" + "x-expandableFields": [ + "adjusted_for_overdraft", + "applied_to_payment", + "customer", + "funded", + "refunded_from_payment", + "transferred_to_balance", + "unapplied_from_payment" + ], + "x-resourceId": "customer_cash_balance_transaction" }, - "event": { - "description": "Events are our way of letting you know when something interesting happens in\nyour account. When an interesting event occurs, we create a new `Event`\nobject. For example, when a charge succeeds, we create a `charge.succeeded`\nevent; and when an invoice payment attempt fails, we create an\n`invoice.payment_failed` event. Note that many API requests may cause multiple\nevents to be created. For example, if you create a new subscription for a\ncustomer, you will receive both a `customer.subscription.created` event and a\n`charge.succeeded` event.\n\nEvents occur when the state of another API resource changes. The state of that\nresource at the time of the change is embedded in the event's data field. For\nexample, a `charge.succeeded` event will contain a charge, and an\n`invoice.payment_failed` event will contain an invoice.\n\nAs with other API resources, you can use endpoints to retrieve an\n[individual event](https://stripe.com/docs/api#retrieve_event) or a [list of events](https://stripe.com/docs/api#list_events)\nfrom the API. We also have a separate\n[webhooks](https://en.wikipedia.org/wiki/Webhook) system for sending the\n`Event` objects directly to an endpoint on your server. Webhooks are managed\nin your\n[account settings](https://dashboard.stripe.com/account/webhooks),\nand our [Using Webhooks](https://stripe.com/docs/webhooks) guide will help you get set up.\n\nWhen using [Connect](https://stripe.com/docs/connect), you can also receive notifications of\nevents that occur in connected accounts. For these events, there will be an\nadditional `account` attribute in the received `Event` object.\n\n**NOTE:** Right now, access to events through the [Retrieve Event API](https://stripe.com/docs/api#retrieve_event) is\nguaranteed only for 30 days.", + "customer_session": { + "description": "A Customer Session allows you to grant Stripe's frontend SDKs (like Stripe.js) client-side access\ncontrol over a Customer.\n\nRelated guides: [Customer Session with the Payment Element](/payments/accept-a-payment-deferred?platform=web&type=payment#save-payment-methods),\n[Customer Session with the Pricing Table](/payments/checkout/pricing-table#customer-session),\n[Customer Session with the Buy Button](/payment-links/buy-button#pass-an-existing-customer).", "properties": { - "account": { - "description": "The connected account that originated the event.", + "client_secret": { + "description": "The client secret of this Customer Session. Used on the client to set up secure access to the given `customer`.\n\nThe client secret can be used to provide access to `customer` from your frontend. It should not be stored, logged, or exposed to anyone other than the relevant customer. Make sure that you have TLS enabled on any page that includes the client secret.", "maxLength": 5000, "type": "string" }, - "api_version": { - "description": "The Stripe API version used to render `data`. *Note: This property is populated only for events on or after October 31, 2014*.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "components": { + "$ref": "#/components/schemas/customer_session_resource_components" }, "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, - "data": { - "$ref": "#/components/schemas/notification_event_data" + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + } + ], + "description": "The Customer the Customer Session was created for.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + } + ] + } }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "expires_at": { + "description": "The timestamp at which this Customer Session will expire.", + "format": "unix-time", + "type": "integer" }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", @@ -5980,1433 +8679,1207 @@ }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["event"], - "type": "string" - }, - "pending_webhooks": { - "description": "Number of webhooks that have yet to be successfully delivered (i.e., to return a 20x response) to the URLs you've specified.", - "type": "integer" - }, - "request": { - "anyOf": [ - { - "$ref": "#/components/schemas/notification_event_request" - } - ], - "description": "Information on the API request that instigated the event.", - "nullable": true - }, - "type": { - "description": "Description of the event (e.g., `invoice.created` or `charge.refunded`).", - "maxLength": 5000, + "enum": ["customer_session"], "type": "string" } }, "required": [ + "client_secret", "created", - "data", - "id", + "customer", + "expires_at", "livemode", - "object", - "pending_webhooks", - "type" + "object" ], - "title": "NotificationEvent", + "title": "CustomerSessionResourceCustomerSession", "type": "object", - "x-expandableFields": ["data", "request"], - "x-resourceId": "event" + "x-expandableFields": ["components", "customer"], + "x-resourceId": "customer_session" }, - "exchange_rate": { - "description": "`Exchange Rate` objects allow you to determine the rates that Stripe is\ncurrently using to convert from one currency to another. Since this number is\nvariable throughout the day, there are various reasons why you might want to\nknow the current rate (for example, to dynamically price an item for a user\nwith a default payment in a foreign currency).\n\nIf you want a guarantee that the charge is made with a certain exchange rate\nyou expect is current, you can pass in `exchange_rate` to charges endpoints.\nIf the value is no longer up to date, the charge won't go through. Please\nrefer to our [Exchange Rates API](https://stripe.com/docs/exchange-rates) guide for more\ndetails.", + "customer_session_resource_components": { + "description": "Configuration for the components supported by this Customer Session.", "properties": { - "id": { - "description": "Unique identifier for the object. Represented as the three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) in lowercase.", - "maxLength": 5000, - "type": "string" + "buy_button": { + "$ref": "#/components/schemas/customer_session_resource_components_resource_buy_button" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["exchange_rate"], - "type": "string" + "payment_element": { + "$ref": "#/components/schemas/customer_session_resource_components_resource_payment_element" }, - "rates": { - "additionalProperties": { - "type": "number" - }, - "description": "Hash where the keys are supported currencies and the values are the exchange rate at which the base id currency converts to the key currency.", - "type": "object" + "pricing_table": { + "$ref": "#/components/schemas/customer_session_resource_components_resource_pricing_table" } }, - "required": ["id", "object", "rates"], - "title": "ExchangeRate", + "required": ["buy_button", "payment_element", "pricing_table"], + "title": "CustomerSessionResourceComponents", "type": "object", - "x-expandableFields": [], - "x-resourceId": "exchange_rate" + "x-expandableFields": ["buy_button", "payment_element", "pricing_table"] }, - "external_account": { - "anyOf": [ - { - "$ref": "#/components/schemas/bank_account" + "customer_session_resource_components_resource_buy_button": { + "description": "This hash contains whether the buy button is enabled.", + "properties": { + "enabled": { + "description": "Whether the buy button is enabled.", + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "CustomerSessionResourceComponentsResourceBuyButton", + "type": "object", + "x-expandableFields": [] + }, + "customer_session_resource_components_resource_payment_element": { + "description": "This hash contains whether the Payment Element is enabled and the features it supports.", + "properties": { + "enabled": { + "description": "Whether the Payment Element is enabled.", + "type": "boolean" }, - { - "$ref": "#/components/schemas/card" + "features": { + "anyOf": [ + { + "$ref": "#/components/schemas/customer_session_resource_components_resource_payment_element_resource_features" + } + ], + "description": "This hash defines whether the Payment Element supports certain features.", + "nullable": true } - ], - "title": "Polymorphic", - "x-resourceId": "external_account" + }, + "required": ["enabled"], + "title": "CustomerSessionResourceComponentsResourcePaymentElement", + "type": "object", + "x-expandableFields": ["features"] }, - "fee": { - "description": "", + "customer_session_resource_components_resource_payment_element_resource_features": { + "description": "This hash contains the features the Payment Element supports.", "properties": { - "amount": { - "description": "Amount of the fee, in cents.", - "type": "integer" + "payment_method_allow_redisplay_filters": { + "description": "A list of [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) values that controls which saved payment methods the Payment Element displays by filtering to only show payment methods with an `allow_redisplay` value that is present in this list.\n\nIf not specified, defaults to [\"always\"]. In order to display all saved payment methods, specify [\"always\", \"limited\", \"unspecified\"].", + "items": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "type": "array" }, - "application": { - "description": "ID of the Connect application that earned the fee.", - "maxLength": 5000, + "payment_method_redisplay": { + "description": "Controls whether or not the Payment Element shows saved payment methods. This parameter defaults to `disabled`.", + "enum": ["disabled", "enabled"], + "type": "string", + "x-stripeBypassValidation": true + }, + "payment_method_redisplay_limit": { + "description": "Determines the max number of saved payment methods for the Payment Element to display. This parameter defaults to `3`.", "nullable": true, - "type": "string" + "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" + "payment_method_remove": { + "description": "Controls whether the Payment Element displays the option to remove a saved payment method. This parameter defaults to `disabled`.\n\nAllowing buyers to remove their saved payment methods impacts subscriptions that depend on that payment method. Removing the payment method detaches the [`customer` object](https://docs.stripe.com/api/payment_methods/object#payment_method_object-customer) from that [PaymentMethod](https://docs.stripe.com/api/payment_methods).", + "enum": ["disabled", "enabled"], + "type": "string", + "x-stripeBypassValidation": true }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "payment_method_save": { + "description": "Controls whether the Payment Element displays a checkbox offering to save a new payment method. This parameter defaults to `disabled`.\n\nIf a customer checks the box, the [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) value on the PaymentMethod is set to `'always'` at confirmation time. For PaymentIntents, the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value is also set to the value defined in `payment_method_save_usage`.", + "enum": ["disabled", "enabled"], + "type": "string", + "x-stripeBypassValidation": true }, - "type": { - "description": "Type of the fee, one of: `application_fee`, `stripe_fee` or `tax`.", - "maxLength": 5000, + "payment_method_save_usage": { + "description": "When using PaymentIntents and the customer checks the save checkbox, this field determines the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value used to confirm the PaymentIntent.\n\nWhen using SetupIntents, directly configure the [`usage`](https://docs.stripe.com/api/setup_intents/object#setup_intent_object-usage) value on SetupIntent creation.", + "enum": ["off_session", "on_session"], + "nullable": true, "type": "string" } }, - "required": ["amount", "currency", "type"], - "title": "Fee", + "required": [ + "payment_method_allow_redisplay_filters", + "payment_method_redisplay", + "payment_method_remove", + "payment_method_save" + ], + "title": "CustomerSessionResourceComponentsResourcePaymentElementResourceFeatures", "type": "object", "x-expandableFields": [] }, - "fee_refund": { - "description": "`Application Fee Refund` objects allow you to refund an application fee that\nhas previously been created but not yet refunded. Funds will be refunded to\nthe Stripe account from which the fee was originally collected.\n\nRelated guide: [Refunding Application Fees](https://stripe.com/docs/connect/destination-charges#refunding-app-fee).", + "customer_session_resource_components_resource_pricing_table": { + "description": "This hash contains whether the pricing table is enabled.", "properties": { - "amount": { - "description": "Amount, in %s.", - "type": "integer" - }, - "balance_transaction": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/balance_transaction" - } + "enabled": { + "description": "Whether the pricing table is enabled.", + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "CustomerSessionResourceComponentsResourcePricingTable", + "type": "object", + "x-expandableFields": [] + }, + "customer_tax": { + "description": "", + "properties": { + "automatic_tax": { + "description": "Surfaces if automatic tax computation is possible given the current customer location information.", + "enum": [ + "failed", + "not_collecting", + "supported", + "unrecognized_location" ], - "description": "Balance transaction that describes the impact on your account balance.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/balance_transaction" - } - ] - } - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "type": "string" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "ip_address": { + "description": "A recent IP address of the customer used for tax reporting and tax location inference.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "fee": { + "location": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/application_fee" + "$ref": "#/components/schemas/customer_tax_location" } ], - "description": "ID of the application fee that was refunded.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/application_fee" - } - ] - } + "description": "The customer's location as identified by Stripe Tax.", + "nullable": true + } + }, + "required": ["automatic_tax"], + "title": "CustomerTax", + "type": "object", + "x-expandableFields": ["location"] + }, + "customer_tax_location": { + "description": "", + "properties": { + "country": { + "description": "The customer's country as identified by Stripe Tax.", + "maxLength": 5000, + "type": "string" + }, + "source": { + "description": "The data source used to infer the customer's location.", + "enum": [ + "billing_address", + "ip_address", + "payment_method", + "shipping_destination" + ], + "type": "string" + }, + "state": { + "description": "The customer's state, county, province, or region as identified by Stripe Tax.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["country", "source"], + "title": "CustomerTaxLocation", + "type": "object", + "x-expandableFields": [] + }, + "deleted_account": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, - "type": "object" - }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["fee_refund"], + "enum": ["account"], "type": "string" } }, - "required": ["amount", "created", "currency", "fee", "id", "object"], - "title": "FeeRefund", + "required": ["deleted", "id", "object"], + "title": "DeletedAccount", "type": "object", - "x-expandableFields": ["balance_transaction", "fee"], - "x-resourceId": "fee_refund" + "x-expandableFields": [], + "x-resourceId": "deleted_account" }, - "file": { - "description": "This is an object representing a file hosted on Stripe's servers. The\nfile may have been uploaded by yourself using the [create file](https://stripe.com/docs/api#create_file)\nrequest (for example, when uploading dispute evidence) or it may have\nbeen created by Stripe (for example, the results of a [Sigma scheduled\nquery](#scheduled_queries)).\n\nRelated guide: [File Upload Guide](https://stripe.com/docs/file-upload).", + "deleted_apple_pay_domain": { + "description": "", "properties": { - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "expires_at": { - "description": "The time at which the file expires and is no longer available in epoch seconds.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "filename": { - "description": "A filename for the file, suitable for saving to a filesystem.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "links": { - "description": "A list of [file links](https://stripe.com/docs/api#file_links) that point at this file.", - "nullable": true, - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/file_link" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "FileFileLinkList", - "type": "object", - "x-expandableFields": ["data"] - }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["file"], + "enum": ["apple_pay_domain"], "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedApplePayDomain", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_apple_pay_domain" + }, + "deleted_application": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "purpose": { - "description": "The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.", - "enum": [ - "account_requirement", - "additional_verification", - "business_icon", - "business_logo", - "customer_signature", - "dispute_evidence", - "identity_document", - "pci_document", - "tax_document_user_upload" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "size": { - "description": "The size in bytes of the file object.", - "type": "integer" - }, - "title": { - "description": "A user friendly title for the document.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "type": { - "description": "The type of the file returned (e.g., `csv`, `pdf`, `jpg`, or `png`).", + "name": { + "description": "The name of the application.", "maxLength": 5000, "nullable": true, "type": "string" }, - "url": { - "description": "The URL from which the file can be downloaded using your live secret API key.", - "maxLength": 5000, - "nullable": true, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["application"], "type": "string" } }, - "required": ["created", "id", "object", "purpose", "size"], - "title": "File", + "required": ["deleted", "id", "object"], + "title": "DeletedApplication", "type": "object", - "x-expandableFields": ["links"], - "x-resourceId": "file" + "x-expandableFields": [] }, - "file_link": { - "description": "To share the contents of a `File` object with non-Stripe users, you can\ncreate a `FileLink`. `FileLink`s contain a URL that can be used to\nretrieve the contents of the file without authentication.", + "deleted_bank_account": { + "description": "", "properties": { - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "expired": { - "description": "Whether this link is already expired.", - "type": "boolean" - }, - "expires_at": { - "description": "Time at which the link expires.", - "format": "unix-time", + "currency": { + "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account.", + "maxLength": 5000, "nullable": true, - "type": "integer" + "type": "string" }, - "file": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/file" - } - ], - "description": "The file object this link points to.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/file" - } - ] - } + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["file_link"], - "type": "string" - }, - "url": { - "description": "The publicly accessible URL to download the file.", - "maxLength": 5000, - "nullable": true, + "enum": ["bank_account"], "type": "string" } }, - "required": [ - "created", - "expired", - "file", - "id", - "livemode", - "metadata", - "object" - ], - "title": "FileLink", + "required": ["deleted", "id", "object"], + "title": "DeletedBankAccount", "type": "object", - "x-expandableFields": ["file"], - "x-resourceId": "file_link" + "x-expandableFields": [] }, - "financial_reporting_finance_report_run_run_parameters": { + "deleted_card": { "description": "", "properties": { - "columns": { - "description": "The set of output columns requested for inclusion in the report run.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "connected_account": { - "description": "Connected account ID by which to filter the report run.", - "maxLength": 5000, - "type": "string" - }, "currency": { - "description": "Currency of objects to be included in the report run.", - "type": "string" - }, - "interval_end": { - "description": "Ending timestamp of data to be included in the report run (exclusive).", - "format": "unix-time", - "type": "integer" - }, - "interval_start": { - "description": "Starting timestamp of data to be included in the report run.", - "format": "unix-time", - "type": "integer" - }, - "payout": { - "description": "Payout ID by which to filter the report run.", + "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "reporting_category": { - "description": "Category of balance transactions to be included in the report run.", + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" + }, + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "timezone": { - "description": "Defaults to `Etc/UTC`. The output timezone for all timestamps in the report. A list of possible time zone values is maintained at the [IANA Time Zone Database](https://www.iana.org/time-zones). Has no effect on `interval_start` or `interval_end`.", - "maxLength": 5000, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["card"], "type": "string" } }, - "title": "FinancialReportingFinanceReportRunRunParameters", + "required": ["deleted", "id", "object"], + "title": "DeletedCard", "type": "object", "x-expandableFields": [] }, - "inventory": { + "deleted_coupon": { "description": "", "properties": { - "quantity": { - "description": "The count of inventory available. Will be present if and only if `type` is `finite`.", - "nullable": true, - "type": "integer" + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "type": { - "description": "Inventory type. Possible values are `finite`, `bucket` (not quantified), and `infinite`.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "value": { - "description": "An indicator of the inventory available. Possible values are `in_stock`, `limited`, and `out_of_stock`. Will be present if and only if `type` is `bucket`.", - "maxLength": 5000, - "nullable": true, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["coupon"], "type": "string" } }, - "required": ["type"], - "title": "Inventory", + "required": ["deleted", "id", "object"], + "title": "DeletedCoupon", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [], + "x-resourceId": "deleted_coupon" }, - "invoice": { - "description": "Invoices are statements of amounts owed by a customer, and are either\ngenerated one-off, or generated periodically from a subscription.\n\nThey contain [invoice items](https://stripe.com/docs/api#invoiceitems), and proration adjustments\nthat may be caused by subscription upgrades/downgrades (if necessary).\n\nIf your invoice is configured to be billed through automatic charges,\nStripe automatically finalizes your invoice and attempts payment. Note\nthat finalizing the invoice,\n[when automatic](https://stripe.com/docs/billing/invoices/workflow/#auto_advance), does\nnot happen immediately as the invoice is created. Stripe waits\nuntil one hour after the last webhook was successfully sent (or the last\nwebhook timed out after failing). If you (and the platforms you may have\nconnected to) have no webhooks configured, Stripe waits one hour after\ncreation to finalize the invoice.\n\nIf your invoice is configured to be billed by sending an email, then based on your\n[email settings](https://dashboard.stripe.com/account/billing/automatic'),\nStripe will email the invoice to your customer and await payment. These\nemails can contain a link to a hosted page to pay the invoice.\n\nStripe applies any customer credit on the account before determining the\namount due for the invoice (i.e., the amount that will be actually\ncharged). If the amount due for the invoice is less than Stripe's [minimum allowed charge\nper currency](/docs/currencies#minimum-and-maximum-charge-amounts), the\ninvoice is automatically marked paid, and we add the amount due to the\ncustomer's credit balance which is applied to the next invoice.\n\nMore details on the customer's credit balance are\n[here](https://stripe.com/docs/billing/customer/balance).\n\nRelated guide: [Send Invoices to Customers](https://stripe.com/docs/billing/invoices/sending).", + "deleted_customer": { + "description": "", "properties": { - "account_country": { - "description": "The country of the business associated with this invoice, most often the business creating the invoice.", + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" + }, + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "account_name": { - "description": "The public name of the business associated with this invoice, most often the business creating the invoice.", + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["customer"], + "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedCustomer", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_customer" + }, + "deleted_discount": { + "description": "", + "properties": { + "checkout_session": { + "description": "The Checkout session that this coupon is applied to, if it is applied to a particular session in payment mode. Will not be present for subscription mode.", "maxLength": 5000, "nullable": true, "type": "string" }, - "account_tax_ids": { - "description": "The account tax IDs associated with the invoice. Only editable when the invoice is a draft.", - "items": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, + "coupon": { + "$ref": "#/components/schemas/coupon" + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ], + "description": "The ID of the customer associated with this discount.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ { - "$ref": "#/components/schemas/tax_id" + "$ref": "#/components/schemas/customer" }, { - "$ref": "#/components/schemas/deleted_tax_id" + "$ref": "#/components/schemas/deleted_customer" } - ], - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/tax_id" - }, - { - "$ref": "#/components/schemas/deleted_tax_id" - } - ] - } - }, - "nullable": true, - "type": "array" + ] + } }, - "amount_due": { - "description": "Final amount due at this time for this invoice. If the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the `amount_due` may be 0. If there is a positive `starting_balance` for the invoice (the customer owes money), the `amount_due` will also take that into account. The charge that gets generated for the invoice will be for the amount specified in `amount_due`.", - "type": "integer" - }, - "amount_paid": { - "description": "The amount, in %s, that was paid.", - "type": "integer" - }, - "amount_remaining": { - "description": "The amount remaining, in %s, that is due.", - "type": "integer" - }, - "application_fee_amount": { - "description": "The fee in %s that will be applied to the invoice and transferred to the application owner's Stripe account when the invoice is paid.", - "nullable": true, - "type": "integer" - }, - "attempt_count": { - "description": "Number of payment attempts made for this invoice, from the perspective of the payment retry schedule. Any payment attempt counts as the first attempt, and subsequently only automatic retries increment the attempt count. In other words, manual payment attempts after the first attempt do not affect the retry schedule.", - "type": "integer" - }, - "attempted": { - "description": "Whether an attempt has been made to pay the invoice. An invoice is not attempted until 1 hour after the `invoice.created` webhook, for example, so you might not want to display that invoice as unpaid to your users.", - "type": "boolean" - }, - "auto_advance": { - "description": "Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action.", + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], "type": "boolean" }, - "billing_reason": { - "description": "Indicates the reason why the invoice was created. `subscription_cycle` indicates an invoice created by a subscription advancing into a new period. `subscription_create` indicates an invoice created due to creating a subscription. `subscription_update` indicates an invoice created due to updating a subscription. `subscription` is set for all old invoices to indicate either a change to a subscription or a period advancement. `manual` is set for all invoices unrelated to a subscription (for example: created via the invoice editor). The `upcoming` value is reserved for simulated invoices per the upcoming invoice endpoint. `subscription_threshold` indicates an invoice created due to a billing threshold being reached.", - "enum": [ - "automatic_pending_invoice_item_invoice", - "manual", - "subscription", - "subscription_create", - "subscription_cycle", - "subscription_threshold", - "subscription_update", - "upcoming" - ], - "nullable": true, + "id": { + "description": "The ID of the discount object. Discounts cannot be fetched by ID. Use `expand[]=discounts` in API calls to expand discount IDs in an array.", + "maxLength": 5000, "type": "string" }, - "charge": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/charge" - } - ], - "description": "ID of the latest charge generated for this invoice, if any.", + "invoice": { + "description": "The invoice that the discount's coupon was applied to, if it was applied directly to a particular invoice.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/charge" - } - ] - } + "type": "string" }, - "collection_method": { - "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions.", - "enum": ["charge_automatically", "send_invoice"], + "invoice_item": { + "description": "The invoice item `id` (or invoice line item `id` for invoice line items of type='subscription') that the discount's coupon was applied to, if it was applied directly to a particular invoice item or invoice line item.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["discount"], "type": "string" }, - "custom_fields": { - "description": "Custom fields displayed on the invoice.", - "items": { - "$ref": "#/components/schemas/invoice_setting_custom_field" - }, - "nullable": true, - "type": "array" - }, - "customer": { + "promotion_code": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/promotion_code" } ], - "description": "The ID of the customer who will be billed.", + "description": "The promotion code applied to create this discount.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/promotion_code" } ] } }, - "customer_address": { - "anyOf": [ - { - "$ref": "#/components/schemas/address" - } - ], - "description": "The customer's address. Until the invoice is finalized, this field will equal `customer.address`. Once the invoice is finalized, this field will no longer be updated.", - "nullable": true + "start": { + "description": "Date that the coupon was applied.", + "format": "unix-time", + "type": "integer" }, - "customer_email": { - "description": "The customer's email. Until the invoice is finalized, this field will equal `customer.email`. Once the invoice is finalized, this field will no longer be updated.", + "subscription": { + "description": "The subscription that this coupon is applied to, if it is applied to a particular subscription.", "maxLength": 5000, "nullable": true, "type": "string" }, - "customer_name": { - "description": "The customer's name. Until the invoice is finalized, this field will equal `customer.name`. Once the invoice is finalized, this field will no longer be updated.", + "subscription_item": { + "description": "The subscription item that this coupon is applied to, if it is applied to a particular subscription item.", "maxLength": 5000, "nullable": true, "type": "string" + } + }, + "required": ["coupon", "deleted", "id", "object", "start"], + "title": "DeletedDiscount", + "type": "object", + "x-expandableFields": ["coupon", "customer", "promotion_code"], + "x-resourceId": "deleted_discount" + }, + "deleted_external_account": { + "anyOf": [ + { + "$ref": "#/components/schemas/deleted_bank_account" }, - "customer_phone": { - "description": "The customer's phone number. Until the invoice is finalized, this field will equal `customer.phone`. Once the invoice is finalized, this field will no longer be updated.", + { + "$ref": "#/components/schemas/deleted_card" + } + ], + "title": "Polymorphic", + "x-resourceId": "deleted_external_account", + "x-stripeBypassValidation": true + }, + "deleted_invoice": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" + }, + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "customer_shipping": { - "anyOf": [ - { - "$ref": "#/components/schemas/shipping" - } - ], - "description": "The customer's shipping information. Until the invoice is finalized, this field will equal `customer.shipping`. Once the invoice is finalized, this field will no longer be updated.", - "nullable": true - }, - "customer_tax_exempt": { - "description": "The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated.", - "enum": ["exempt", "none", "reverse"], - "nullable": true, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["invoice"], "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedInvoice", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_invoice" + }, + "deleted_invoiceitem": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "customer_tax_ids": { - "description": "The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated.", - "items": { - "$ref": "#/components/schemas/invoices_resource_invoice_tax_id" - }, - "nullable": true, - "type": "array" - }, - "default_payment_method": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" - } - ], - "description": "ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } - }, - "default_source": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/alipay_account" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/source" - } - ], - "description": "ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/alipay_account" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/source" - } - ] - } - }, - "default_tax_rates": { - "description": "The tax rates applied to this invoice, if any.", - "items": { - "$ref": "#/components/schemas/tax_rate" - }, - "type": "array" - }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "discount": { - "anyOf": [ - { - "$ref": "#/components/schemas/discount" - } - ], - "description": "Describes the current discount applied to this invoice, if there is one. Not populated if there are multiple discounts.", - "nullable": true - }, - "discounts": { - "description": "The discounts applied to the invoice. Line item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.", - "items": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/discount" - }, - { - "$ref": "#/components/schemas/deleted_discount" - } - ], - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/discount" - }, - { - "$ref": "#/components/schemas/deleted_discount" - } - ] - } - }, - "nullable": true, - "type": "array" - }, - "due_date": { - "description": "The date on which payment for this invoice is due. This value will be `null` for invoices where `collection_method=charge_automatically`.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["invoiceitem"], + "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedInvoiceItem", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_invoiceitem" + }, + "deleted_payment_source": { + "anyOf": [ + { + "$ref": "#/components/schemas/deleted_bank_account" }, - "ending_balance": { - "description": "Ending customer balance after the invoice is finalized. Invoices are finalized approximately an hour after successful webhook delivery or when payment collection is attempted for the invoice. If the invoice has not been finalized yet, this will be null.", - "nullable": true, - "type": "integer" + { + "$ref": "#/components/schemas/deleted_card" + } + ], + "title": "Polymorphic", + "x-resourceId": "deleted_payment_source", + "x-stripeBypassValidation": true + }, + "deleted_person": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "footer": { - "description": "Footer displayed on the invoice.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "hosted_invoice_url": { - "description": "The URL for the hosted invoice page, which allows customers to view and pay an invoice. If the invoice has not been finalized yet, this will be null.", - "maxLength": 5000, - "nullable": true, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["person"], "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedPerson", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_person" + }, + "deleted_plan": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "invoice_pdf": { - "description": "The link to download the PDF for the invoice. If the invoice has not been finalized yet, this will be null.", + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["plan"], + "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedPlan", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_plan" + }, + "deleted_price": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" + }, + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "last_finalization_error": { - "anyOf": [ - { - "$ref": "#/components/schemas/api_errors" - } - ], - "description": "The error encountered during the previous attempt to finalize the invoice. This field is cleared when the invoice is successfully finalized.", - "nullable": true + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["price"], + "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedPrice", + "type": "object", + "x-expandableFields": [] + }, + "deleted_product": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "lines": { - "description": "The individual line items that make up the invoice. `lines` is sorted as follows: invoice items in reverse chronological order, followed by the subscription, if any.", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/line_item" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "InvoiceLinesList", - "type": "object", - "x-expandableFields": ["data"] + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["product"], + "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedProduct", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_product" + }, + "deleted_product_feature": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], "type": "boolean" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, - "type": "object" + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" }, - "next_payment_attempt": { - "description": "The time at which payment will next be attempted. This value will be `null` for invoices where `collection_method=send_invoice`.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["product_feature"], + "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedProductFeature", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_product_feature" + }, + "deleted_radar.value_list": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "number": { - "description": "A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["invoice"], + "enum": ["radar.value_list"], "type": "string" - }, - "on_behalf_of": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/account" - } - ], - "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/account" - } - ] - } - }, - "paid": { - "description": "Whether payment was successfully collected for this invoice. An invoice can be paid (most commonly) with a charge or with credit from the customer's account balance.", + } + }, + "required": ["deleted", "id", "object"], + "title": "RadarListDeletedList", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_radar.value_list" + }, + "deleted_radar.value_list_item": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], "type": "boolean" }, - "payment_intent": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_intent" - } - ], - "description": "The PaymentIntent associated with this invoice. The PaymentIntent is generated when the invoice is finalized, and can then be used to pay the invoice. Note that voiding an invoice will cancel the PaymentIntent.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_intent" - } - ] - } - }, - "payment_settings": { - "$ref": "#/components/schemas/invoices_payment_settings" - }, - "period_end": { - "description": "End of the usage period during which invoice items were added to this invoice.", - "format": "unix-time", - "type": "integer" - }, - "period_start": { - "description": "Start of the usage period during which invoice items were added to this invoice.", - "format": "unix-time", - "type": "integer" - }, - "post_payment_credit_notes_amount": { - "description": "Total amount of all post-payment credit notes issued for this invoice.", - "type": "integer" - }, - "pre_payment_credit_notes_amount": { - "description": "Total amount of all pre-payment credit notes issued for this invoice.", - "type": "integer" - }, - "receipt_number": { - "description": "This is the transaction number that appears on email receipts sent for this invoice.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "starting_balance": { - "description": "Starting customer balance before the invoice is finalized. If the invoice has not been finalized yet, this will be the current customer balance.", - "type": "integer" + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["radar.value_list_item"], + "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "RadarListDeletedListItem", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_radar.value_list_item" + }, + "deleted_subscription_item": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "statement_descriptor": { - "description": "Extra information about an invoice for the customer's credit card statement.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "status": { - "description": "The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)", - "enum": [ - "deleted", - "draft", - "open", - "paid", - "uncollectible", - "void" - ], - "nullable": true, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["subscription_item"], "type": "string" + } + }, + "required": ["deleted", "id", "object"], + "title": "DeletedSubscriptionItem", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "deleted_subscription_item" + }, + "deleted_tax_id": { + "description": "", + "properties": { + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "status_transitions": { - "$ref": "#/components/schemas/invoices_status_transitions" - }, - "subscription": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/subscription" - } - ], - "description": "The subscription that this invoice was prepared for, if any.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/subscription" - } - ] - } - }, - "subscription_proration_date": { - "description": "Only set for upcoming invoices that preview prorations. The time used to calculate prorations.", - "type": "integer" - }, - "subtotal": { - "description": "Total of all subscriptions, invoice items, and prorations on the invoice before any invoice level discount or tax is applied. Item discounts are already incorporated", - "type": "integer" - }, - "tax": { - "description": "The amount of tax on this invoice. This is the sum of all the tax amounts on this invoice.", - "nullable": true, - "type": "integer" - }, - "threshold_reason": { - "$ref": "#/components/schemas/invoice_threshold_reason" - }, - "total": { - "description": "Total after discounts and taxes.", - "type": "integer" - }, - "total_discount_amounts": { - "description": "The aggregate amounts calculated per discount across all line items.", - "items": { - "$ref": "#/components/schemas/discounts_resource_discount_amount" - }, - "nullable": true, - "type": "array" - }, - "total_tax_amounts": { - "description": "The aggregate amounts calculated per tax rate for all line items.", - "items": { - "$ref": "#/components/schemas/invoice_tax_amount" - }, - "type": "array" - }, - "transfer_data": { - "anyOf": [ - { - "$ref": "#/components/schemas/invoice_transfer_data" - } - ], - "description": "The account (if any) the payment will be attributed to for tax reporting, and where funds from the payment will be transferred to for the invoice.", - "nullable": true + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" }, - "webhooks_delivered_at": { - "description": "Invoices are automatically paid or sent 1 hour after webhooks are delivered, or until all webhook delivery attempts have [been exhausted](https://stripe.com/docs/billing/webhooks#understand). This field tracks the time when webhooks for this invoice were successfully delivered. If the invoice had no webhooks to deliver, this will be set while the invoice is being created.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax_id"], + "type": "string" } }, - "required": [ - "amount_due", - "amount_paid", - "amount_remaining", - "attempt_count", - "attempted", - "created", - "currency", - "default_tax_rates", - "lines", - "livemode", - "object", - "paid", - "payment_settings", - "period_end", - "period_start", - "post_payment_credit_notes_amount", - "pre_payment_credit_notes_amount", - "starting_balance", - "status_transitions", - "subtotal", - "total", - "total_tax_amounts" - ], - "title": "Invoice", + "required": ["deleted", "id", "object"], + "title": "deleted_tax_id", "type": "object", - "x-expandableFields": [ - "account_tax_ids", - "charge", - "custom_fields", - "customer", - "customer_address", - "customer_shipping", - "customer_tax_ids", - "default_payment_method", - "default_source", - "default_tax_rates", - "discount", - "discounts", - "last_finalization_error", - "lines", - "on_behalf_of", - "payment_intent", - "payment_settings", - "status_transitions", - "subscription", - "threshold_reason", - "total_discount_amounts", - "total_tax_amounts", - "transfer_data" - ], - "x-resourceId": "invoice" + "x-expandableFields": [], + "x-resourceId": "deleted_tax_id" }, - "invoice_item_threshold_reason": { + "deleted_terminal.configuration": { "description": "", "properties": { - "line_item_ids": { - "description": "The IDs of the line items that triggered the threshold invoice.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "usage_gte": { - "description": "The quantity threshold boundary that applied to the given line item.", - "type": "integer" + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["terminal.configuration"], + "type": "string" } }, - "required": ["line_item_ids", "usage_gte"], - "title": "InvoiceItemThresholdReason", + "required": ["deleted", "id", "object"], + "title": "TerminalConfigurationDeletedConfiguration", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [], + "x-resourceId": "deleted_terminal.configuration" }, - "invoice_line_item_period": { + "deleted_terminal.location": { "description": "", "properties": { - "end": { - "description": "End of the line item's billing period", - "format": "unix-time", - "type": "integer" + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" }, - "start": { - "description": "Start of the line item's billing period", - "format": "unix-time", - "type": "integer" + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["terminal.location"], + "type": "string" } }, - "required": ["end", "start"], - "title": "InvoiceLineItemPeriod", + "required": ["deleted", "id", "object"], + "title": "TerminalLocationDeletedLocation", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [], + "x-resourceId": "deleted_terminal.location" }, - "invoice_payment_method_options_bancontact": { + "deleted_terminal.reader": { "description": "", "properties": { - "preferred_language": { - "description": "Preferred language of the Bancontact authorization page that the customer is redirected to.", - "enum": ["de", "en", "fr", "nl"], + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["terminal.reader"], "type": "string" } }, - "required": ["preferred_language"], - "title": "invoice_payment_method_options_bancontact", + "required": ["deleted", "id", "object"], + "title": "TerminalReaderDeletedReader", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [], + "x-resourceId": "deleted_terminal.reader" }, - "invoice_payment_method_options_card": { + "deleted_test_helpers.test_clock": { "description": "", "properties": { - "request_three_d_secure": { - "description": "We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.", - "enum": ["any", "automatic"], - "nullable": true, + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["test_helpers.test_clock"], "type": "string" } }, - "title": "invoice_payment_method_options_card", + "required": ["deleted", "id", "object"], + "title": "DeletedTestClock", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [], + "x-resourceId": "deleted_test_helpers.test_clock" }, - "invoice_setting_custom_field": { + "deleted_webhook_endpoint": { "description": "", "properties": { - "name": { - "description": "The name of the custom field.", + "deleted": { + "description": "Always true for a deleted object", + "enum": [true], + "type": "boolean" + }, + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "value": { - "description": "The value of the custom field.", - "maxLength": 5000, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["webhook_endpoint"], "type": "string" } }, - "required": ["name", "value"], - "title": "InvoiceSettingCustomField", + "required": ["deleted", "id", "object"], + "title": "NotificationWebhookEndpointDeleted", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [], + "x-resourceId": "deleted_webhook_endpoint" }, - "invoice_setting_customer_setting": { + "destination_details_unimplemented": { "description": "", + "properties": {}, + "title": "destination_details_unimplemented", + "type": "object", + "x-expandableFields": [] + }, + "discount": { + "description": "A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).\nIt contains information about when the discount began, when it will end, and what it is applied to.\n\nRelated guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)", "properties": { - "custom_fields": { - "description": "Default custom fields to be displayed on invoices for this customer.", - "items": { - "$ref": "#/components/schemas/invoice_setting_custom_field" - }, + "checkout_session": { + "description": "The Checkout session that this coupon is applied to, if it is applied to a particular session in payment mode. Will not be present for subscription mode.", + "maxLength": 5000, "nullable": true, - "type": "array" + "type": "string" }, - "default_payment_method": { + "coupon": { + "$ref": "#/components/schemas/coupon" + }, + "customer": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" } ], - "description": "ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.", + "description": "The ID of the customer associated with this discount.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" } ] } }, - "footer": { - "description": "Default footer to be displayed on invoices for this customer.", + "end": { + "description": "If the coupon has a duration of `repeating`, the date that this discount will end. If the coupon has a duration of `once` or `forever`, this attribute will be null.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "id": { + "description": "The ID of the discount object. Discounts cannot be fetched by ID. Use `expand[]=discounts` in API calls to expand discount IDs in an array.", + "maxLength": 5000, + "type": "string" + }, + "invoice": { + "description": "The invoice that the discount's coupon was applied to, if it was applied directly to a particular invoice.", "maxLength": 5000, "nullable": true, "type": "string" - } - }, - "title": "InvoiceSettingCustomerSetting", - "type": "object", - "x-expandableFields": ["custom_fields", "default_payment_method"] - }, - "invoice_setting_subscription_schedule_setting": { - "description": "", - "properties": { - "days_until_due": { - "description": "Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.", + }, + "invoice_item": { + "description": "The invoice item `id` (or invoice line item `id` for invoice line items of type='subscription') that the discount's coupon was applied to, if it was applied directly to a particular invoice item or invoice line item.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["discount"], + "type": "string" + }, + "promotion_code": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/promotion_code" + } + ], + "description": "The promotion code applied to create this discount.", "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/promotion_code" + } + ] + } + }, + "start": { + "description": "Date that the coupon was applied.", + "format": "unix-time", "type": "integer" + }, + "subscription": { + "description": "The subscription that this coupon is applied to, if it is applied to a particular subscription.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "subscription_item": { + "description": "The subscription item that this coupon is applied to, if it is applied to a particular subscription item.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "title": "InvoiceSettingSubscriptionScheduleSetting", + "required": ["coupon", "id", "object", "start"], + "title": "Discount", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["coupon", "customer", "promotion_code"], + "x-resourceId": "discount" }, - "invoice_tax_amount": { + "discounts_resource_discount_amount": { "description": "", "properties": { "amount": { - "description": "The amount, in %s, of the tax.", + "description": "The amount, in cents (or local equivalent), of the discount.", "type": "integer" }, - "inclusive": { - "description": "Whether this tax amount is inclusive or exclusive.", - "type": "boolean" - }, - "tax_rate": { + "discount": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/tax_rate" + "$ref": "#/components/schemas/discount" + }, + { + "$ref": "#/components/schemas/deleted_discount" } ], - "description": "The tax rate that was applied to get this tax amount.", + "description": "The discount that was applied to get this discount amount.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/tax_rate" + "$ref": "#/components/schemas/discount" + }, + { + "$ref": "#/components/schemas/deleted_discount" } ] } } }, - "required": ["amount", "inclusive", "tax_rate"], - "title": "InvoiceTaxAmount", - "type": "object", - "x-expandableFields": ["tax_rate"] + "required": ["amount", "discount"], + "title": "DiscountsResourceDiscountAmount", + "type": "object", + "x-expandableFields": ["discount"] }, - "invoice_threshold_reason": { + "discounts_resource_stackable_discount": { "description": "", "properties": { - "amount_gte": { - "description": "The total invoice amount threshold boundary if it triggered the threshold invoice.", + "coupon": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/coupon" + } + ], + "description": "ID of the coupon to create a new discount for.", "nullable": true, - "type": "integer" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/coupon" + } + ] + } }, - "item_reasons": { - "description": "Indicates which line items triggered a threshold invoice.", - "items": { - "$ref": "#/components/schemas/invoice_item_threshold_reason" - }, - "type": "array" - } - }, - "required": ["item_reasons"], - "title": "InvoiceThresholdReason", - "type": "object", - "x-expandableFields": ["item_reasons"] - }, - "invoice_transfer_data": { - "description": "", - "properties": { - "amount": { - "description": "The amount in %s that will be transferred to the destination account when the invoice is paid. By default, the entire amount is transferred to the destination.", + "discount": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/discount" + } + ], + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", "nullable": true, - "type": "integer" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/discount" + } + ] + } }, - "destination": { + "promotion_code": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/promotion_code" } ], - "description": "The account where funds from the payment will be transferred to upon payment success.", + "description": "ID of the promotion code to create a new discount for.", + "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/promotion_code" } ] } } }, - "required": ["destination"], - "title": "InvoiceTransferData", + "title": "DiscountsResourceStackableDiscount", "type": "object", - "x-expandableFields": ["destination"] + "x-expandableFields": ["coupon", "discount", "promotion_code"] }, - "invoiceitem": { - "description": "Sometimes you want to add a charge or credit to a customer, but actually\ncharge or credit the customer's card only at the end of a regular billing\ncycle. This is useful for combining several charges (to minimize\nper-transaction fees), or for having Stripe tabulate your usage-based billing\ntotals.\n\nRelated guide: [Subscription Invoices](https://stripe.com/docs/billing/invoices/subscription#adding-upcoming-invoice-items).", + "dispute": { + "description": "A dispute occurs when a customer questions your charge with their card issuer.\nWhen this happens, you have the opportunity to respond to the dispute with\nevidence that shows that the charge is legitimate.\n\nRelated guide: [Disputes and fraud](https://stripe.com/docs/disputes)", "properties": { "amount": { - "description": "Amount (in the `currency` specified) of the invoice item. This should always be equal to `unit_amount * quantity`.", + "description": "Disputed amount. Usually the amount of the charge, but it can differ (usually because of currency fluctuation or because only part of the order is disputed).", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" + "balance_transactions": { + "description": "List of zero, one, or two balance transactions that show funds withdrawn and reinstated to your Stripe account as a result of this dispute.", + "items": { + "$ref": "#/components/schemas/balance_transaction" + }, + "type": "array" }, - "customer": { + "charge": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/charge" } ], - "description": "The ID of the customer who will be billed when this invoice item is billed.", + "description": "ID of the charge that's disputed.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/charge" } ] } }, - "date": { + "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 5000, - "nullable": true, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, - "discountable": { - "description": "If true, discounts will apply to this invoice item. Always false for prorations.", - "type": "boolean" + "evidence": { + "$ref": "#/components/schemas/dispute_evidence" }, - "discounts": { - "description": "The discounts which apply to the invoice item. Item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.", - "items": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/discount" - } - ], - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/discount" - } - ] - } - }, - "nullable": true, - "type": "array" + "evidence_details": { + "$ref": "#/components/schemas/dispute_evidence_details" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "invoice": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/invoice" - } - ], - "description": "The ID of the invoice this invoice item belongs to.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/invoice" - } - ] - } + "is_charge_refundable": { + "description": "If true, it's still possible to refund the disputed payment. After the payment has been fully refunded, no further funds are withdrawn from your Stripe account as a result of this dispute.", + "type": "boolean" }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", @@ -7418,812 +9891,632 @@ "type": "string" }, "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, "type": "object" }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["invoiceitem"], + "enum": ["dispute"], "type": "string" }, - "period": { - "$ref": "#/components/schemas/invoice_line_item_period" - }, - "price": { - "anyOf": [ - { - "$ref": "#/components/schemas/price" - } - ], - "description": "The price of the invoice item.", - "nullable": true - }, - "proration": { - "description": "Whether the invoice item was created automatically as a proration adjustment when the customer switched plans.", - "type": "boolean" - }, - "quantity": { - "description": "Quantity of units for the invoice item. If the invoice item is a proration, the quantity of the subscription that the proration was computed for.", - "type": "integer" - }, - "subscription": { + "payment_intent": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/subscription" + "$ref": "#/components/schemas/payment_intent" } ], - "description": "The subscription that this invoice item has been created for, if any.", + "description": "ID of the PaymentIntent that's disputed.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/subscription" + "$ref": "#/components/schemas/payment_intent" } ] } }, - "subscription_item": { - "description": "The subscription item that this invoice item has been created for, if any.", + "payment_method_details": { + "$ref": "#/components/schemas/dispute_payment_method_details" + }, + "reason": { + "description": "Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Learn more about [dispute reasons](https://stripe.com/docs/disputes/categories).", "maxLength": 5000, "type": "string" }, - "tax_rates": { - "description": "The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.", - "items": { - "$ref": "#/components/schemas/tax_rate" - }, - "nullable": true, - "type": "array" - }, - "unit_amount": { - "description": "Unit amount (in the `currency` specified) of the invoice item.", - "nullable": true, - "type": "integer" - }, - "unit_amount_decimal": { - "description": "Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.", - "format": "decimal", - "nullable": true, + "status": { + "description": "Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `won`, or `lost`.", + "enum": [ + "lost", + "needs_response", + "under_review", + "warning_closed", + "warning_needs_response", + "warning_under_review", + "won" + ], "type": "string" } }, "required": [ "amount", + "balance_transactions", + "charge", + "created", "currency", - "customer", - "date", - "discountable", + "evidence", + "evidence_details", "id", + "is_charge_refundable", "livemode", + "metadata", "object", - "period", - "proration", - "quantity" + "reason", + "status" ], - "title": "InvoiceItem", + "title": "Dispute", "type": "object", "x-expandableFields": [ - "customer", - "discounts", - "invoice", - "period", - "price", - "subscription", - "tax_rates" + "balance_transactions", + "charge", + "evidence", + "evidence_details", + "payment_intent", + "payment_method_details" ], - "x-resourceId": "invoiceitem" - }, - "invoices_payment_method_options": { - "description": "", - "properties": { - "bancontact": { - "anyOf": [ - { - "$ref": "#/components/schemas/invoice_payment_method_options_bancontact" - } - ], - "description": "If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.", - "nullable": true - }, - "card": { - "anyOf": [ - { - "$ref": "#/components/schemas/invoice_payment_method_options_card" - } - ], - "description": "If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.", - "nullable": true - } - }, - "title": "InvoicesPaymentMethodOptions", - "type": "object", - "x-expandableFields": ["bancontact", "card"] + "x-resourceId": "dispute" }, - "invoices_payment_settings": { + "dispute_evidence": { "description": "", "properties": { - "payment_method_options": { - "anyOf": [ - { - "$ref": "#/components/schemas/invoices_payment_method_options" - } - ], - "description": "Payment-method-specific configuration to provide to the invoice’s PaymentIntent.", - "nullable": true - }, - "payment_method_types": { - "description": "The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).", - "items": { - "enum": [ - "ach_credit_transfer", - "ach_debit", - "au_becs_debit", - "bacs_debit", - "bancontact", - "card", - "fpx", - "giropay", - "ideal", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true - }, + "access_activity_log": { + "description": "Any server or activity logs showing proof that the customer accessed or downloaded the purchased digital product. This information should include IP addresses, corresponding timestamps, and any detailed recorded activity.", + "maxLength": 150000, "nullable": true, - "type": "array" - } - }, - "title": "InvoicesPaymentSettings", - "type": "object", - "x-expandableFields": ["payment_method_options"] - }, - "invoices_resource_invoice_tax_id": { - "description": "", - "properties": { - "type": { - "description": "The type of the tax ID, one of `eu_vat`, `br_cnpj`, `br_cpf`, `gb_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, or `unknown`", - "enum": [ - "ae_trn", - "au_abn", - "br_cnpj", - "br_cpf", - "ca_bn", - "ca_qst", - "ch_vat", - "cl_tin", - "es_cif", - "eu_vat", - "gb_vat", - "hk_br", - "id_npwp", - "in_gst", - "jp_cn", - "jp_rn", - "kr_brn", - "li_uid", - "mx_rfc", - "my_frp", - "my_itn", - "my_sst", - "no_vat", - "nz_gst", - "ru_inn", - "ru_kpp", - "sa_vat", - "sg_gst", - "sg_uen", - "th_vat", - "tw_vat", - "unknown", - "us_ein", - "za_vat" - ], "type": "string" }, - "value": { - "description": "The value of the tax ID.", + "billing_address": { + "description": "The billing address provided by the customer.", "maxLength": 5000, "nullable": true, "type": "string" - } - }, - "required": ["type"], - "title": "InvoicesResourceInvoiceTaxID", - "type": "object", - "x-expandableFields": [] - }, - "invoices_status_transitions": { - "description": "", - "properties": { - "finalized_at": { - "description": "The time that the invoice draft was finalized.", - "format": "unix-time", - "nullable": true, - "type": "integer" }, - "marked_uncollectible_at": { - "description": "The time that the invoice was marked uncollectible.", - "format": "unix-time", + "cancellation_policy": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your subscription cancellation policy, as shown to the customer.", "nullable": true, - "type": "integer" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } }, - "paid_at": { - "description": "The time that the invoice was paid.", - "format": "unix-time", + "cancellation_policy_disclosure": { + "description": "An explanation of how and when the customer was shown your refund policy prior to purchase.", + "maxLength": 150000, "nullable": true, - "type": "integer" + "type": "string" }, - "voided_at": { - "description": "The time that the invoice was voided.", - "format": "unix-time", + "cancellation_rebuttal": { + "description": "A justification for why the customer's subscription was not canceled.", + "maxLength": 150000, "nullable": true, - "type": "integer" - } - }, - "title": "InvoicesStatusTransitions", - "type": "object", - "x-expandableFields": [] - }, - "issuer_fraud_record": { - "description": "This resource has been renamed to [Early Fraud\nWarning](#early_fraud_warning_object) and will be removed in a future API\nversion.", - "properties": { - "actionable": { - "description": "An IFR is actionable if it has not received a dispute and has not been fully refunded. You may wish to proactively refund a charge that receives an IFR, in order to avoid receiving a dispute later.", - "type": "boolean" + "type": "string" }, - "charge": { + "customer_communication": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/file" } ], - "description": "ID of the charge this issuer fraud record is for, optionally expanded.", + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any communication with the customer that you feel is relevant to your case. Examples include emails proving that the customer received the product or service, or demonstrating their use of or satisfaction with the product or service.", + "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/file" } ] } }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "fraud_type": { - "description": "The type of fraud labelled by the issuer. One of `card_never_received`, `fraudulent_card_application`, `made_with_counterfeit_card`, `made_with_lost_card`, `made_with_stolen_card`, `misc`, `unauthorized_use_of_card`.", + "customer_email_address": { + "description": "The email address of the customer.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "has_liability_shift": { - "description": "If true, the associated charge is subject to [liability shift](https://stripe.com/docs/payments/3d-secure#disputed-payments).", - "type": "boolean" - }, - "id": { - "description": "Unique identifier for the object.", + "customer_name": { + "description": "The name of the customer.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["issuer_fraud_record"], - "type": "string" - }, - "post_date": { - "description": "The timestamp at which the card issuer posted the issuer fraud record.", - "type": "integer" - } - }, - "required": [ - "actionable", - "charge", - "created", - "fraud_type", - "has_liability_shift", - "id", - "livemode", - "object", - "post_date" - ], - "title": "IssuerFraudRecord", - "type": "object", - "x-expandableFields": ["charge"], - "x-resourceId": "issuer_fraud_record" - }, - "issuing.authorization": { - "description": "When an [issued card](https://stripe.com/docs/issuing) is used to make a purchase, an Issuing `Authorization`\nobject is created. [Authorizations](https://stripe.com/docs/issuing/purchases/authorizations) must be approved for the\npurchase to be completed successfully.\n\nRelated guide: [Issued Card Authorizations](https://stripe.com/docs/issuing/purchases/authorizations).", - "properties": { - "amount": { - "description": "The total amount that was authorized or rejected. This amount is in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", - "type": "integer" - }, - "amount_details": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_authorization_amount_details" - } - ], - "description": "Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", - "nullable": true - }, - "approved": { - "description": "Whether the authorization has been approved.", - "type": "boolean" - }, - "authorization_method": { - "description": "How the card details were provided.", - "enum": ["chip", "contactless", "keyed_in", "online", "swipe"], + "customer_purchase_ip": { + "description": "The IP address that the customer used when making the purchase.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "balance_transactions": { - "description": "List of balance transactions associated with this authorization.", - "items": { - "$ref": "#/components/schemas/balance_transaction" - }, - "type": "array" - }, - "card": { - "$ref": "#/components/schemas/issuing.card" - }, - "cardholder": { + "customer_signature": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/issuing.cardholder" + "$ref": "#/components/schemas/file" } ], - "description": "The cardholder to whom this authorization belongs.", + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A relevant document or contract showing the customer's signature.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/issuing.cardholder" + "$ref": "#/components/schemas/file" } ] } }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" + "duplicate_charge_documentation": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation for the prior charge that can uniquely identify the charge, such as a receipt, shipping label, work order, etc. This document should be paired with a similar document from the disputed payment that proves the two payments are separate.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "duplicate_charge_explanation": { + "description": "An explanation of the difference between the disputed charge versus the prior charge that appears to be a duplicate.", + "maxLength": 150000, + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "merchant_amount": { - "description": "The total amount that was authorized or rejected. This amount is in the `merchant_currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", - "type": "integer" - }, - "merchant_currency": { - "description": "The currency that was presented to the cardholder for the authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "duplicate_charge_id": { + "description": "The Stripe ID for the prior charge which appears to be a duplicate of the disputed charge.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "merchant_data": { - "$ref": "#/components/schemas/issuing_authorization_merchant_data" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["issuing.authorization"], + "product_description": { + "description": "A description of the product or service that was sold.", + "maxLength": 150000, + "nullable": true, "type": "string" }, - "pending_request": { + "receipt": { "anyOf": [ { - "$ref": "#/components/schemas/issuing_authorization_pending_request" + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" } ], - "description": "The pending authorization request. This field will only be non-null during an `issuing_authorization.request` webhook.", - "nullable": true - }, - "request_history": { - "description": "History of every time `pending_request` was approved/denied, either by you directly or by Stripe (e.g. based on your `spending_controls`). If the merchant changes the authorization by performing an [incremental authorization](https://stripe.com/docs/issuing/purchases/authorizations), you can look at this field to see the previous requests for the authorization.", - "items": { - "$ref": "#/components/schemas/issuing_authorization_request" - }, - "type": "array" - }, - "status": { - "description": "The current status of the authorization in its lifecycle.", - "enum": ["closed", "pending", "reversed"], - "type": "string" - }, - "transactions": { - "description": "List of [transactions](https://stripe.com/docs/api/issuing/transactions) associated with this authorization.", - "items": { - "$ref": "#/components/schemas/issuing.transaction" - }, - "type": "array" - }, - "verification_data": { - "$ref": "#/components/schemas/issuing_authorization_verification_data" + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any receipt or message sent to the customer notifying them of the charge.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } }, - "wallet": { - "description": "What, if any, digital wallet was used for this authorization. One of `apple_pay`, `google_pay`, or `samsung_pay`.", - "maxLength": 5000, + "refund_policy": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your refund policy, as shown to the customer.", "nullable": true, - "type": "string" - } - }, - "required": [ - "amount", - "approved", - "authorization_method", - "balance_transactions", - "card", - "created", - "currency", - "id", - "livemode", - "merchant_amount", - "merchant_currency", - "merchant_data", - "metadata", - "object", - "request_history", - "status", - "transactions", - "verification_data" - ], - "title": "IssuingAuthorization", - "type": "object", - "x-expandableFields": [ - "amount_details", - "balance_transactions", - "card", - "cardholder", - "merchant_data", - "pending_request", - "request_history", - "transactions", - "verification_data" - ], - "x-resourceId": "issuing.authorization" - }, - "issuing.card": { - "description": "You can [create physical or virtual cards](https://stripe.com/docs/issuing/cards) that are issued to cardholders.", - "properties": { - "brand": { - "description": "The brand of the card.", - "maxLength": 5000, - "type": "string" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } }, - "cancellation_reason": { - "description": "The reason why the card was canceled.", - "enum": ["lost", "stolen"], + "refund_policy_disclosure": { + "description": "Documentation demonstrating that the customer was shown your refund policy prior to purchase.", + "maxLength": 150000, "nullable": true, "type": "string" }, - "cardholder": { - "$ref": "#/components/schemas/issuing.cardholder" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "refund_refusal_explanation": { + "description": "A justification for why the customer is not entitled to a refund.", + "maxLength": 150000, + "nullable": true, "type": "string" }, - "cvc": { - "description": "The card's CVC. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the [\"Retrieve a card\" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via \"List all cards\" or any other endpoint.", + "service_date": { + "description": "The date on which the customer received or began receiving the purchased service, in a clear human-readable format.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "exp_month": { - "description": "The expiration month of the card.", - "type": "integer" - }, - "exp_year": { - "description": "The expiration year of the card.", - "type": "integer" + "service_documentation": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a service was provided to the customer. This could include a copy of a signed contract, work order, or other form of written agreement.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } }, - "id": { - "description": "Unique identifier for the object.", + "shipping_address": { + "description": "The address to which a physical product was shipped. You should try to include as complete address information as possible.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "last4": { - "description": "The last 4 digits of the card number.", + "shipping_carrier": { + "description": "The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc. If multiple carriers were used for this purchase, please separate them with commas.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "number": { - "description": "The full unredacted card number. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the [\"Retrieve a card\" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via \"List all cards\" or any other endpoint.", + "shipping_date": { + "description": "The date on which a physical product began its route to the shipping address, in a clear human-readable format.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["issuing.card"], - "type": "string" - }, - "replaced_by": { + "shipping_documentation": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/issuing.card" + "$ref": "#/components/schemas/file" } ], - "description": "The latest card that replaces this card, if any.", + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a product was shipped to the customer at the same address the customer provided to you. This could include a copy of the shipment receipt, shipping label, etc. It should show the customer's full shipping address, if possible.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/issuing.card" + "$ref": "#/components/schemas/file" } ] } }, - "replacement_for": { + "shipping_tracking_number": { + "description": "The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "uncategorized_file": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/issuing.card" + "$ref": "#/components/schemas/file" } ], - "description": "The card this card replaces, if any.", + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any additional evidence or statements.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/issuing.card" + "$ref": "#/components/schemas/file" } ] } }, - "replacement_reason": { - "description": "The reason why the previous card needed to be replaced.", - "enum": ["damaged", "expired", "lost", "stolen"], + "uncategorized_text": { + "description": "Any additional evidence or statements.", + "maxLength": 150000, "nullable": true, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" + } + }, + "title": "DisputeEvidence", + "type": "object", + "x-expandableFields": [ + "cancellation_policy", + "customer_communication", + "customer_signature", + "duplicate_charge_documentation", + "receipt", + "refund_policy", + "service_documentation", + "shipping_documentation", + "uncategorized_file" + ] + }, + "dispute_evidence_details": { + "description": "", + "properties": { + "due_by": { + "description": "Date by which evidence must be submitted in order to successfully challenge dispute. Will be 0 if the customer's bank or credit card company doesn't allow a response for this particular dispute.", + "format": "unix-time", + "nullable": true, + "type": "integer" }, - "shipping": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_card_shipping" - } - ], - "description": "Where and how the card will be shipped.", - "nullable": true + "has_evidence": { + "description": "Whether evidence has been staged for this dispute.", + "type": "boolean" }, - "spending_controls": { - "$ref": "#/components/schemas/issuing_card_authorization_controls" + "past_due": { + "description": "Whether the last evidence submission was submitted past the due date. Defaults to `false` if no evidence submissions have occurred. If `true`, then delivery of the latest evidence is *not* guaranteed.", + "type": "boolean" }, - "status": { - "description": "Whether authorizations can be approved on this card.", - "enum": ["active", "canceled", "inactive"], + "submission_count": { + "description": "The number of times evidence has been submitted. Typically, you may only submit evidence once.", + "type": "integer" + } + }, + "required": ["has_evidence", "past_due", "submission_count"], + "title": "DisputeEvidenceDetails", + "type": "object", + "x-expandableFields": [] + }, + "dispute_payment_method_details": { + "description": "", + "properties": { + "card": { + "$ref": "#/components/schemas/dispute_payment_method_details_card" + }, + "klarna": { + "$ref": "#/components/schemas/dispute_payment_method_details_klarna" + }, + "paypal": { + "$ref": "#/components/schemas/dispute_payment_method_details_paypal" + }, + "type": { + "description": "Payment method type.", + "enum": ["card", "klarna", "paypal"], + "type": "string" + } + }, + "required": ["type"], + "title": "DisputePaymentMethodDetails", + "type": "object", + "x-expandableFields": ["card", "klarna", "paypal"] + }, + "dispute_payment_method_details_card": { + "description": "", + "properties": { + "brand": { + "description": "Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + "maxLength": 5000, + "type": "string" + }, + "case_type": { + "description": "The type of dispute opened. Different case types may have varying fees and financial impact.", + "enum": ["chargeback", "inquiry"], "type": "string", "x-stripeBypassValidation": true }, - "type": { - "description": "The type of the card.", - "enum": ["physical", "virtual"], + "network_reason_code": { + "description": "The card network's specific dispute reason code, which maps to one of Stripe's primary dispute categories to simplify response guidance. The [Network code map](https://stripe.com/docs/disputes/categories#network-code-map) lists all available dispute reason codes by network.", + "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": [ - "brand", - "cardholder", - "created", - "currency", - "exp_month", - "exp_year", - "id", - "last4", - "livemode", - "metadata", - "object", - "spending_controls", - "status", - "type" - ], - "title": "IssuingCard", + "required": ["brand", "case_type"], + "title": "DisputePaymentMethodDetailsCard", "type": "object", - "x-expandableFields": [ - "cardholder", - "replaced_by", - "replacement_for", - "shipping", - "spending_controls" - ], - "x-resourceId": "issuing.card" + "x-expandableFields": [] }, - "issuing.cardholder": { - "description": "An Issuing `Cardholder` object represents an individual or business entity who is [issued](https://stripe.com/docs/issuing) cards.\n\nRelated guide: [How to create a Cardholder](https://stripe.com/docs/issuing/cards#create-cardholder)", + "dispute_payment_method_details_klarna": { + "description": "", "properties": { - "billing": { - "$ref": "#/components/schemas/issuing_cardholder_address" + "reason_code": { + "description": "The reason for the dispute as defined by Klarna", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "DisputePaymentMethodDetailsKlarna", + "type": "object", + "x-expandableFields": [] + }, + "dispute_payment_method_details_paypal": { + "description": "", + "properties": { + "case_id": { + "description": "The ID of the dispute in PayPal.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "company": { + "reason_code": { + "description": "The reason for the dispute as defined by PayPal", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "DisputePaymentMethodDetailsPaypal", + "type": "object", + "x-expandableFields": [] + }, + "email_sent": { + "description": "", + "properties": { + "email_sent_at": { + "description": "The timestamp when the email was sent.", + "format": "unix-time", + "type": "integer" + }, + "email_sent_to": { + "description": "The recipient's email address.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["email_sent_at", "email_sent_to"], + "title": "EmailSent", + "type": "object", + "x-expandableFields": [] + }, + "entitlements.active_entitlement": { + "description": "An active entitlement describes access to a feature for a customer.", + "properties": { + "feature": { "anyOf": [ { - "$ref": "#/components/schemas/issuing_cardholder_company" + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/entitlements.feature" } ], - "description": "Additional information about a `company` cardholder.", - "nullable": true + "description": "The [Feature](https://stripe.com/docs/api/entitlements/feature) that the customer is entitled to.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/entitlements.feature" + } + ] + } }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" }, - "email": { - "description": "The cardholder's email address.", + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "lookup_key": { + "description": "A unique key you provide as your own system identifier. This may be up to 80 characters.", "maxLength": 5000, - "nullable": true, "type": "string" }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["entitlements.active_entitlement"], + "type": "string" + } + }, + "required": ["feature", "id", "livemode", "lookup_key", "object"], + "title": "ActiveEntitlement", + "type": "object", + "x-expandableFields": ["feature"], + "x-resourceId": "entitlements.active_entitlement" + }, + "entitlements.feature": { + "description": "A feature represents a monetizable ability or functionality in your system.\nFeatures can be assigned to products, and when those products are purchased, Stripe will create an entitlement to the feature for the purchasing customer.", + "properties": { + "active": { + "description": "Inactive features cannot be attached to new products and will not be returned from the features list endpoint.", + "type": "boolean" + }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "individual": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_cardholder_individual" - } - ], - "description": "Additional information about an `individual` cardholder.", - "nullable": true - }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, + "lookup_key": { + "description": "A unique key you provide as your own system identifier. This may be up to 80 characters.", + "maxLength": 5000, + "type": "string" + }, "metadata": { "additionalProperties": { "maxLength": 500, "type": "string" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "description": "Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", "type": "object" }, "name": { - "description": "The cardholder's name. This will be printed on cards issued to them.", - "maxLength": 5000, + "description": "The feature's name, for your own purpose, not meant to be displayable to the customer.", + "maxLength": 80, "type": "string" }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["issuing.cardholder"], - "type": "string" - }, - "phone_number": { - "description": "The cardholder's phone number.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "requirements": { - "$ref": "#/components/schemas/issuing_cardholder_requirements" - }, - "spending_controls": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_cardholder_authorization_controls" - } - ], - "description": "Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", - "nullable": true - }, - "status": { - "description": "Specifies whether to permit authorizations on this cardholder's cards.", - "enum": ["active", "blocked", "inactive"], + "enum": ["entitlements.feature"], "type": "string" - }, - "type": { - "description": "One of `individual` or `company`.", - "enum": ["company", "individual"], - "type": "string", - "x-stripeBypassValidation": true } }, "required": [ - "billing", - "created", + "active", "id", "livemode", + "lookup_key", "metadata", "name", - "object", - "requirements", - "status", - "type" + "object" ], - "title": "IssuingCardholder", + "title": "Feature", "type": "object", - "x-expandableFields": [ - "billing", - "company", - "individual", - "requirements", - "spending_controls" - ], - "x-resourceId": "issuing.cardholder" + "x-expandableFields": [], + "x-resourceId": "entitlements.feature" }, - "issuing.dispute": { - "description": "As a [card issuer](https://stripe.com/docs/issuing), you can dispute transactions that the cardholder does not recognize, suspects to be fraudulent, or has other issues with.\n\nRelated guide: [Disputing Transactions](https://stripe.com/docs/issuing/purchases/disputes)", + "ephemeral_key": { + "description": "", "properties": { - "amount": { - "description": "Disputed amount. Usually the amount of the `transaction`, but can differ (usually because of currency fluctuation).", - "type": "integer" - }, - "balance_transactions": { - "description": "List of balance transactions associated with the dispute.", - "items": { - "$ref": "#/components/schemas/balance_transaction" - }, - "nullable": true, - "type": "array" - }, "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, - "currency": { - "description": "The currency the `transaction` was made in.", - "type": "string" - }, - "evidence": { - "$ref": "#/components/schemas/issuing_dispute_evidence" + "expires": { + "description": "Time at which the key will expire. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" }, "id": { "description": "Unique identifier for the object.", @@ -8234,202 +10527,225 @@ "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["issuing.dispute"], + "enum": ["ephemeral_key"], "type": "string" }, - "status": { - "description": "Current status of the dispute.", - "enum": ["expired", "lost", "submitted", "unsubmitted", "won"], + "secret": { + "description": "The key's secret. You can use this value to make authorized requests to the Stripe API.", + "maxLength": 5000, "type": "string" - }, - "transaction": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/issuing.transaction" - } - ], - "description": "The transaction being disputed.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/issuing.transaction" - } - ] - } } }, - "required": [ - "amount", - "created", - "currency", - "evidence", - "id", - "livemode", - "metadata", - "object", - "status", - "transaction" - ], - "title": "IssuingDispute", + "required": ["created", "expires", "id", "livemode", "object"], + "title": "EphemeralKey", "type": "object", - "x-expandableFields": [ - "balance_transactions", - "evidence", - "transaction" - ], - "x-resourceId": "issuing.dispute" + "x-expandableFields": [], + "x-resourceId": "ephemeral_key" }, - "issuing.settlement": { - "description": "When a non-stripe BIN is used, any use of an [issued card](https://stripe.com/docs/issuing) must be settled directly with the card network. The net amount owed is represented by an Issuing `Settlement` object.", + "error": { + "description": "An error response from the Stripe API", "properties": { - "bin": { - "description": "The Bank Identification Number reflecting this settlement record.", + "error": { + "$ref": "#/components/schemas/api_errors" + } + }, + "required": ["error"], + "type": "object" + }, + "event": { + "description": "Events are our way of letting you know when something interesting happens in\nyour account. When an interesting event occurs, we create a new `Event`\nobject. For example, when a charge succeeds, we create a `charge.succeeded`\nevent, and when an invoice payment attempt fails, we create an\n`invoice.payment_failed` event. Certain API requests might create multiple\nevents. For example, if you create a new subscription for a\ncustomer, you receive both a `customer.subscription.created` event and a\n`charge.succeeded` event.\n\nEvents occur when the state of another API resource changes. The event's data\nfield embeds the resource's state at the time of the change. For\nexample, a `charge.succeeded` event contains a charge, and an\n`invoice.payment_failed` event contains an invoice.\n\nAs with other API resources, you can use endpoints to retrieve an\n[individual event](https://stripe.com/docs/api#retrieve_event) or a [list of events](https://stripe.com/docs/api#list_events)\nfrom the API. We also have a separate\n[webhooks](https://en.wikipedia.org/wiki/Webhook) system for sending the\n`Event` objects directly to an endpoint on your server. You can manage\nwebhooks in your\n[account settings](https://dashboard.stripe.com/account/webhooks). Learn how\nto [listen for events](https://docs.stripe.com/webhooks)\nso that your integration can automatically trigger reactions.\n\nWhen using [Connect](https://docs.stripe.com/connect), you can also receive event notifications\nthat occur in connected accounts. For these events, there's an\nadditional `account` attribute in the received `Event` object.\n\nWe only guarantee access to events through the [Retrieve Event API](https://stripe.com/docs/api#retrieve_event)\nfor 30 days.", + "properties": { + "account": { + "description": "The connected account that originates the event.", "maxLength": 5000, "type": "string" }, - "clearing_date": { - "description": "The date that the transactions are cleared and posted to user's accounts.", - "type": "integer" + "api_version": { + "description": "The Stripe API version used to render `data`. This property is populated only for events on or after October 31, 2014.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" + "data": { + "$ref": "#/components/schemas/notification_event_data" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "interchange_fees": { - "description": "The total interchange received as reimbursement for the transactions.", - "type": "integer" - }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "net_total": { - "description": "The total net amount required to settle with the network.", - "type": "integer" - }, - "network": { - "description": "The card network for this settlement report. One of [\"visa\"]", - "enum": ["visa"], + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["event"], "type": "string" }, - "network_fees": { - "description": "The total amount of fees owed to the network.", + "pending_webhooks": { + "description": "Number of webhooks that haven't been successfully delivered (for example, to return a 20x response) to the URLs you specify.", "type": "integer" }, - "network_settlement_identifier": { - "description": "The Settlement Identification Number assigned by the network.", - "maxLength": 5000, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["issuing.settlement"], - "type": "string" + "request": { + "anyOf": [ + { + "$ref": "#/components/schemas/notification_event_request" + } + ], + "description": "Information on the API request that triggers the event.", + "nullable": true }, - "settlement_service": { - "description": "One of `international` or `uk_national_net`.", + "type": { + "description": "Description of the event (for example, `invoice.created` or `charge.refunded`).", "maxLength": 5000, "type": "string" - }, - "transaction_count": { - "description": "The total number of transactions reflected in this settlement.", - "type": "integer" - }, - "transaction_volume": { - "description": "The total transaction amount reflected in this settlement.", - "type": "integer" } }, "required": [ - "bin", - "clearing_date", "created", - "currency", + "data", "id", - "interchange_fees", "livemode", - "metadata", - "net_total", - "network", - "network_fees", - "network_settlement_identifier", "object", - "settlement_service", - "transaction_count", - "transaction_volume" + "pending_webhooks", + "type" ], - "title": "IssuingSettlement", + "title": "NotificationEvent", + "type": "object", + "x-expandableFields": ["data", "request"], + "x-resourceId": "event" + }, + "exchange_rate": { + "description": "`ExchangeRate` objects allow you to determine the rates that Stripe is currently\nusing to convert from one currency to another. Since this number is variable\nthroughout the day, there are various reasons why you might want to know the current\nrate (for example, to dynamically price an item for a user with a default\npayment in a foreign currency).\n\nPlease refer to our [Exchange Rates API](https://stripe.com/docs/fx-rates) guide for more details.\n\n*[Note: this integration path is supported but no longer recommended]* Additionally,\nyou can guarantee that a charge is made with an exchange rate that you expect is\ncurrent. To do so, you must pass in the exchange_rate to charges endpoints. If the\nvalue is no longer up to date, the charge won't go through. Please refer to our\n[Using with charges](https://stripe.com/docs/exchange-rates) guide for more details.\n\n-----\n\n \n\n*This Exchange Rates API is a Beta Service and is subject to Stripe's terms of service. You may use the API solely for the purpose of transacting on Stripe. For example, the API may be queried in order to:*\n\n- *localize prices for processing payments on Stripe*\n- *reconcile Stripe transactions*\n- *determine how much money to send to a connected account*\n- *determine app fees to charge a connected account*\n\n*Using this Exchange Rates API beta for any purpose other than to transact on Stripe is strictly prohibited and constitutes a violation of Stripe's terms of service.*", + "properties": { + "id": { + "description": "Unique identifier for the object. Represented as the three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) in lowercase.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["exchange_rate"], + "type": "string" + }, + "rates": { + "additionalProperties": { + "type": "number" + }, + "description": "Hash where the keys are supported currencies and the values are the exchange rate at which the base id currency converts to the key currency.", + "type": "object" + } + }, + "required": ["id", "object", "rates"], + "title": "ExchangeRate", "type": "object", "x-expandableFields": [], - "x-resourceId": "issuing.settlement" + "x-resourceId": "exchange_rate" }, - "issuing.transaction": { - "description": "Any use of an [issued card](https://stripe.com/docs/issuing) that results in funds entering or leaving\nyour Stripe account, such as a completed purchase or refund, is represented by an Issuing\n`Transaction` object.\n\nRelated guide: [Issued Card Transactions](https://stripe.com/docs/issuing/purchases/transactions).", + "external_account": { + "anyOf": [ + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + } + ], + "title": "Polymorphic", + "x-resourceId": "external_account", + "x-stripeBypassValidation": true + }, + "external_account_requirements": { + "description": "", + "properties": { + "currently_due": { + "description": "Fields that need to be collected to keep the external account enabled. If not collected by `current_deadline`, these fields appear in `past_due` as well, and the account is disabled.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "errors": { + "description": "Fields that are `currently_due` and need to be collected again because validation or verification failed.", + "items": { + "$ref": "#/components/schemas/account_requirements_error" + }, + "nullable": true, + "type": "array" + }, + "past_due": { + "description": "Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the external account.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "pending_verification": { + "description": "Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + } + }, + "title": "ExternalAccountRequirements", + "type": "object", + "x-expandableFields": ["errors"] + }, + "fee": { + "description": "", "properties": { "amount": { - "description": "The transaction amount, which will be reflected in your balance. This amount is in your currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "description": "Amount of the fee, in cents.", "type": "integer" }, - "amount_details": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_transaction_amount_details" - } - ], - "description": "Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", - "nullable": true + "application": { + "description": "ID of the Connect application that earned the fee.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "authorization": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/issuing.authorization" - } - ], - "description": "The `Authorization` object that led to this transaction.", + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/issuing.authorization" - } - ] - } + "type": "string" + }, + "type": { + "description": "Type of the fee, one of: `application_fee`, `payment_method_passthrough_fee`, `stripe_fee` or `tax`.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["amount", "currency", "type"], + "title": "Fee", + "type": "object", + "x-expandableFields": [] + }, + "fee_refund": { + "description": "`Application Fee Refund` objects allow you to refund an application fee that\nhas previously been created but not yet refunded. Funds will be refunded to\nthe Stripe account from which the fee was originally collected.\n\nRelated guide: [Refunding application fees](https://stripe.com/docs/connect/destination-charges#refunding-app-fee)", + "properties": { + "amount": { + "description": "Amount, in cents (or local equivalent).", + "type": "integer" }, "balance_transaction": { "anyOf": [ @@ -8441,7 +10757,7 @@ "$ref": "#/components/schemas/balance_transaction" } ], - "description": "ID of the [balance transaction](https://stripe.com/docs/api/balance_transactions) associated with this transaction.", + "description": "Balance transaction that describes the impact on your account balance.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -8451,70 +10767,207 @@ ] } }, - "card": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "fee": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/issuing.card" + "$ref": "#/components/schemas/application_fee" } ], - "description": "The card used to make this transaction.", + "description": "ID of the application fee that was refunded.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/issuing.card" + "$ref": "#/components/schemas/application_fee" } ] } }, - "cardholder": { - "anyOf": [ - { - "maxLength": 5000, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["fee_refund"], + "type": "string" + } + }, + "required": ["amount", "created", "currency", "fee", "id", "object"], + "title": "FeeRefund", + "type": "object", + "x-expandableFields": ["balance_transaction", "fee"], + "x-resourceId": "fee_refund" + }, + "file": { + "description": "This object represents files hosted on Stripe's servers. You can upload\nfiles with the [create file](https://stripe.com/docs/api#create_file) request\n(for example, when uploading dispute evidence). Stripe also\ncreates files independently (for example, the results of a [Sigma scheduled\nquery](#scheduled_queries)).\n\nRelated guide: [File upload guide](https://stripe.com/docs/file-upload)", + "properties": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "expires_at": { + "description": "The file expires and isn't available at this time in epoch seconds.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "filename": { + "description": "The suitable name for saving the file to a filesystem.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "links": { + "description": "A list of [file links](https://stripe.com/docs/api#file_links) that point at this file.", + "nullable": true, + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/file_link" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], "type": "string" }, - { - "$ref": "#/components/schemas/issuing.cardholder" + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/file_links", + "type": "string" } + }, + "required": ["data", "has_more", "object", "url"], + "title": "FileResourceFileLinkList", + "type": "object", + "x-expandableFields": ["data"] + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["file"], + "type": "string" + }, + "purpose": { + "description": "The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.", + "enum": [ + "account_requirement", + "additional_verification", + "business_icon", + "business_logo", + "customer_signature", + "dispute_evidence", + "document_provider_identity_document", + "finance_report_run", + "identity_document", + "identity_document_downloadable", + "issuing_regulatory_reporting", + "pci_document", + "selfie", + "sigma_scheduled_query", + "tax_document_user_upload", + "terminal_reader_splashscreen" ], - "description": "The cardholder to whom this transaction belongs.", + "type": "string", + "x-stripeBypassValidation": true + }, + "size": { + "description": "The size of the file object in bytes.", + "type": "integer" + }, + "title": { + "description": "A suitable title for the document.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/issuing.cardholder" - } - ] - } + "type": "string" + }, + "type": { + "description": "The returned file type (for example, `csv`, `pdf`, `jpg`, or `png`).", + "maxLength": 5000, + "nullable": true, + "type": "string" }, + "url": { + "description": "Use your live secret API key to download the file from this URL.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["created", "id", "object", "purpose", "size"], + "title": "File", + "type": "object", + "x-expandableFields": ["links"], + "x-resourceId": "file" + }, + "file_link": { + "description": "To share the contents of a `File` object with non-Stripe users, you can\ncreate a `FileLink`. `FileLink`s contain a URL that you can use to\nretrieve the contents of the file without authentication.", + "properties": { "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" + "expired": { + "description": "Returns if the link is already expired.", + "type": "boolean" }, - "dispute": { + "expires_at": { + "description": "Time that the link expires.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "file": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/issuing.dispute" + "$ref": "#/components/schemas/file" } ], - "description": "If you've disputed the transaction, the ID of the dispute.", - "nullable": true, + "description": "The file object this link points to.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/issuing.dispute" + "$ref": "#/components/schemas/file" } ] } @@ -8528,17 +10981,6 @@ "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "merchant_amount": { - "description": "The amount that the merchant will receive, denominated in `merchant_currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). It will be different from `amount` if the merchant is taking payment in a different currency.", - "type": "integer" - }, - "merchant_currency": { - "description": "The currency with which the merchant is taking payment.", - "type": "string" - }, - "merchant_data": { - "$ref": "#/components/schemas/issuing_authorization_merchant_data" - }, "metadata": { "additionalProperties": { "maxLength": 500, @@ -8549,3562 +10991,3605 @@ }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["issuing.transaction"], + "enum": ["file_link"], "type": "string" }, - "purchase_details": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_transaction_purchase_details" - } - ], - "description": "Additional purchase information that is optionally provided by the merchant.", - "nullable": true - }, - "type": { - "description": "The nature of the transaction.", - "enum": ["capture", "refund"], - "type": "string", - "x-stripeBypassValidation": true + "url": { + "description": "The publicly accessible URL to download the file.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, "required": [ - "amount", - "card", "created", - "currency", + "expired", + "file", "id", "livemode", - "merchant_amount", - "merchant_currency", - "merchant_data", "metadata", - "object", - "type" + "object" ], - "title": "IssuingTransaction", + "title": "FileLink", "type": "object", - "x-expandableFields": [ - "amount_details", - "authorization", - "balance_transaction", - "card", - "cardholder", - "dispute", - "merchant_data", - "purchase_details" - ], - "x-resourceId": "issuing.transaction" + "x-expandableFields": ["file"], + "x-resourceId": "file_link" }, - "issuing_authorization_amount_details": { - "description": "", + "financial_connections.account": { + "description": "A Financial Connections Account represents an account that exists outside of Stripe, to which you have been granted some degree of access.", "properties": { - "atm_fee": { - "description": "The fee charged by the ATM for the cash withdrawal.", - "nullable": true, + "account_holder": { + "anyOf": [ + { + "$ref": "#/components/schemas/bank_connections_resource_accountholder" + } + ], + "description": "The account holder that this account belongs to.", + "nullable": true + }, + "balance": { + "anyOf": [ + { + "$ref": "#/components/schemas/bank_connections_resource_balance" + } + ], + "description": "The most recent information about the account's balance.", + "nullable": true + }, + "balance_refresh": { + "anyOf": [ + { + "$ref": "#/components/schemas/bank_connections_resource_balance_refresh" + } + ], + "description": "The state of the most recent attempt to refresh the account balance.", + "nullable": true + }, + "category": { + "description": "The type of the account. Account category is further divided in `subcategory`.", + "enum": ["cash", "credit", "investment", "other"], + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", "type": "integer" + }, + "display_name": { + "description": "A human-readable name that has been assigned to this account, either by the account holder or by the institution.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "institution_name": { + "description": "The name of the institution that holds this account.", + "maxLength": 5000, + "type": "string" + }, + "last4": { + "description": "The last 4 digits of the account number. If present, this will be 4 numeric characters.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["financial_connections.account"], + "type": "string" + }, + "ownership": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/financial_connections.account_ownership" + } + ], + "description": "The most recent information about the account's owners.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/financial_connections.account_ownership" + } + ] + } + }, + "ownership_refresh": { + "anyOf": [ + { + "$ref": "#/components/schemas/bank_connections_resource_ownership_refresh" + } + ], + "description": "The state of the most recent attempt to refresh the account owners.", + "nullable": true + }, + "permissions": { + "description": "The list of permissions granted by this account.", + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "status": { + "description": "The status of the link to the account.", + "enum": ["active", "disconnected", "inactive"], + "type": "string" + }, + "subcategory": { + "description": "If `category` is `cash`, one of:\n\n - `checking`\n - `savings`\n - `other`\n\nIf `category` is `credit`, one of:\n\n - `mortgage`\n - `line_of_credit`\n - `credit_card`\n - `other`\n\nIf `category` is `investment` or `other`, this will be `other`.", + "enum": [ + "checking", + "credit_card", + "line_of_credit", + "mortgage", + "other", + "savings" + ], + "type": "string" + }, + "subscriptions": { + "description": "The list of data refresh subscriptions requested on this account.", + "items": { + "enum": ["transactions"], + "type": "string", + "x-stripeBypassValidation": true + }, + "nullable": true, + "type": "array" + }, + "supported_payment_method_types": { + "description": "The [PaymentMethod type](https://stripe.com/docs/api/payment_methods/object#payment_method_object-type)(s) that can be created from this account.", + "items": { + "enum": ["link", "us_bank_account"], + "type": "string" + }, + "type": "array" + }, + "transaction_refresh": { + "anyOf": [ + { + "$ref": "#/components/schemas/bank_connections_resource_transaction_refresh" + } + ], + "description": "The state of the most recent attempt to refresh the account transactions.", + "nullable": true } }, - "title": "IssuingAuthorizationAmountDetails", + "required": [ + "category", + "created", + "id", + "institution_name", + "livemode", + "object", + "status", + "subcategory", + "supported_payment_method_types" + ], + "title": "BankConnectionsResourceLinkedAccount", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [ + "account_holder", + "balance", + "balance_refresh", + "ownership", + "ownership_refresh", + "transaction_refresh" + ], + "x-resourceId": "financial_connections.account" }, - "issuing_authorization_merchant_data": { - "description": "", + "financial_connections.account_owner": { + "description": "Describes an owner of an account.", "properties": { - "category": { - "description": "A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.", - "maxLength": 5000, - "type": "string" - }, - "city": { - "description": "City where the seller is located", + "email": { + "description": "The email address of the owner.", "maxLength": 5000, "nullable": true, "type": "string" }, - "country": { - "description": "Country where the seller is located", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, "name": { - "description": "Name of the seller", + "description": "The full name of the owner.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "network_id": { - "description": "Identifier assigned to the seller by the card brand", + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["financial_connections.account_owner"], + "type": "string" + }, + "ownership": { + "description": "The ownership object that this owner belongs to.", "maxLength": 5000, "type": "string" }, - "postal_code": { - "description": "Postal code where the seller is located", + "phone": { + "description": "The raw phone number of the owner.", "maxLength": 5000, "nullable": true, "type": "string" }, - "state": { - "description": "State where the seller is located", + "raw_address": { + "description": "The raw physical address of the owner.", "maxLength": 5000, "nullable": true, "type": "string" + }, + "refreshed_at": { + "description": "The timestamp of the refresh that updated this owner.", + "format": "unix-time", + "nullable": true, + "type": "integer" } }, - "required": ["category", "network_id"], - "title": "IssuingAuthorizationMerchantData", + "required": ["id", "name", "object", "ownership"], + "title": "BankConnectionsResourceOwner", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [], + "x-resourceId": "financial_connections.account_owner" }, - "issuing_authorization_pending_request": { - "description": "", + "financial_connections.account_ownership": { + "description": "Describes a snapshot of the owners of an account at a particular point in time.", "properties": { - "amount": { - "description": "The additional amount Stripe will hold if the authorization is approved, in the card's [currency](https://stripe.com/docs/api#issuing_authorization_object-pending-request-currency) and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", "type": "integer" }, - "amount_details": { + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["financial_connections.account_ownership"], + "type": "string" + }, + "owners": { + "description": "A paginated list of owners for this account.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/financial_connections.account_owner" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "BankConnectionsResourceOwnerList", + "type": "object", + "x-expandableFields": ["data"] + } + }, + "required": ["created", "id", "object", "owners"], + "title": "BankConnectionsResourceOwnership", + "type": "object", + "x-expandableFields": ["owners"] + }, + "financial_connections.session": { + "description": "A Financial Connections Session is the secure way to programmatically launch the client-side Stripe.js modal that lets your users link their accounts.", + "properties": { + "account_holder": { "anyOf": [ { - "$ref": "#/components/schemas/issuing_authorization_amount_details" + "$ref": "#/components/schemas/bank_connections_resource_accountholder" } ], - "description": "Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "description": "The account holder for whom accounts are collected in this session.", "nullable": true }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "accounts": { + "description": "The accounts that were collected as part of this Session.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/financial_connections.account" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/financial_connections/accounts", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "BankConnectionsResourceLinkedAccountList", + "type": "object", + "x-expandableFields": ["data"] + }, + "client_secret": { + "description": "A value that will be passed to the client to launch the authentication flow.", + "maxLength": 5000, "type": "string" }, - "is_amount_controllable": { - "description": "If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.", + "filters": { + "$ref": "#/components/schemas/bank_connections_resource_link_account_session_filters" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "merchant_amount": { - "description": "The amount the merchant is requesting to be authorized in the `merchant_currency`. The amount is in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", - "type": "integer" + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["financial_connections.session"], + "type": "string" }, - "merchant_currency": { - "description": "The local currency the merchant is requesting to authorize.", + "permissions": { + "description": "Permissions requested for accounts collected during this session.", + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "description": "Data features requested to be retrieved upon account creation.", + "items": { + "enum": ["balances", "ownership", "transactions"], + "type": "string", + "x-stripeBypassValidation": true + }, + "nullable": true, + "type": "array" + }, + "return_url": { + "description": "For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.", + "maxLength": 5000, "type": "string" } }, "required": [ - "amount", - "currency", - "is_amount_controllable", - "merchant_amount", - "merchant_currency" + "accounts", + "client_secret", + "id", + "livemode", + "object", + "permissions" ], - "title": "IssuingAuthorizationPendingRequest", + "title": "BankConnectionsResourceLinkAccountSession", "type": "object", - "x-expandableFields": ["amount_details"] + "x-expandableFields": ["account_holder", "accounts", "filters"], + "x-resourceId": "financial_connections.session" }, - "issuing_authorization_request": { - "description": "", + "financial_connections.transaction": { + "description": "A Transaction represents a real transaction that affects a Financial Connections Account balance.", "properties": { + "account": { + "description": "The ID of the Financial Connections Account this transaction belongs to.", + "maxLength": 5000, + "type": "string" + }, "amount": { - "description": "The `pending_request.amount` at the time of the request, presented in your card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). Stripe held this amount from your account to fund the authorization if the request was approved.", + "description": "The amount of this transaction, in cents (or local equivalent).", "type": "integer" }, - "amount_details": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_authorization_amount_details" - } - ], - "description": "Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", - "nullable": true + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "maxLength": 5000, + "type": "string" }, - "approved": { - "description": "Whether this request was approved.", + "description": { + "description": "The description of this transaction.", + "maxLength": 5000, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["financial_connections.transaction"], + "type": "string" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "maxLength": 5000, + "status": { + "description": "The status of the transaction.", + "enum": ["pending", "posted", "void"], "type": "string" }, - "merchant_amount": { - "description": "The `pending_request.merchant_amount` at the time of the request, presented in the `merchant_currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "status_transitions": { + "$ref": "#/components/schemas/bank_connections_resource_transaction_resource_status_transitions" + }, + "transacted_at": { + "description": "Time at which the transaction was transacted. Measured in seconds since the Unix epoch.", + "format": "unix-time", "type": "integer" }, - "merchant_currency": { - "description": "The currency that was collected by the merchant and presented to the cardholder for the authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "transaction_refresh": { + "description": "The token of the transaction refresh that last updated or created this transaction.", "maxLength": 5000, "type": "string" }, - "reason": { - "description": "The reason for the approval or decline.", - "enum": [ - "account_disabled", - "card_active", - "card_inactive", - "cardholder_inactive", - "cardholder_verification_required", - "insufficient_funds", - "not_allowed", - "spending_controls", - "suspected_fraud", - "verification_failed", - "webhook_approved", - "webhook_declined", - "webhook_timeout" - ], - "type": "string", - "x-stripeBypassValidation": true + "updated": { + "description": "Time at which the object was last updated. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" } }, "required": [ + "account", "amount", - "approved", - "created", "currency", - "merchant_amount", - "merchant_currency", - "reason" + "description", + "id", + "livemode", + "object", + "status", + "status_transitions", + "transacted_at", + "transaction_refresh", + "updated" ], - "title": "IssuingAuthorizationRequest", + "title": "BankConnectionsResourceTransaction", "type": "object", - "x-expandableFields": ["amount_details"] + "x-expandableFields": ["status_transitions"], + "x-resourceId": "financial_connections.transaction" }, - "issuing_authorization_verification_data": { + "financial_reporting_finance_report_run_run_parameters": { "description": "", "properties": { - "address_line1_check": { - "description": "Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`.", - "enum": ["match", "mismatch", "not_provided"], + "columns": { + "description": "The set of output columns requested for inclusion in the report run.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "connected_account": { + "description": "Connected account ID by which to filter the report run.", + "maxLength": 5000, "type": "string" }, - "address_postal_code_check": { - "description": "Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`.", - "enum": ["match", "mismatch", "not_provided"], + "currency": { + "description": "Currency of objects to be included in the report run.", "type": "string" }, - "cvc_check": { - "description": "Whether the cardholder provided a CVC and if it matched Stripe’s record.", - "enum": ["match", "mismatch", "not_provided"], + "interval_end": { + "description": "Ending timestamp of data to be included in the report run. Can be any UTC timestamp between 1 second after the user specified `interval_start` and 1 second before this report's last `data_available_end` value.", + "format": "unix-time", + "type": "integer" + }, + "interval_start": { + "description": "Starting timestamp of data to be included in the report run. Can be any UTC timestamp between 1 second after this report's `data_available_start` and 1 second before the user specified `interval_end` value.", + "format": "unix-time", + "type": "integer" + }, + "payout": { + "description": "Payout ID by which to filter the report run.", + "maxLength": 5000, "type": "string" }, - "expiry_check": { - "description": "Whether the cardholder provided an expiry date and if it matched Stripe’s record.", - "enum": ["match", "mismatch", "not_provided"], + "reporting_category": { + "description": "Category of balance transactions to be included in the report run.", + "maxLength": 5000, + "type": "string" + }, + "timezone": { + "description": "Defaults to `Etc/UTC`. The output timezone for all timestamps in the report. A list of possible time zone values is maintained at the [IANA Time Zone Database](https://www.iana.org/time-zones). Has no effect on `interval_start` or `interval_end`.", + "maxLength": 5000, "type": "string" } }, - "required": [ - "address_line1_check", - "address_postal_code_check", - "cvc_check", - "expiry_check" - ], - "title": "IssuingAuthorizationVerificationData", + "title": "FinancialReportingFinanceReportRunRunParameters", "type": "object", "x-expandableFields": [] }, - "issuing_card_authorization_controls": { - "description": "", + "forwarded_request_context": { + "description": "Metadata about the forwarded request.", "properties": { - "allowed_categories": { - "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.", + "destination_duration": { + "description": "The time it took in milliseconds for the destination endpoint to respond.", + "type": "integer" + }, + "destination_ip_address": { + "description": "The IP address of the destination.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["destination_duration", "destination_ip_address"], + "title": "ForwardedRequestContext", + "type": "object", + "x-expandableFields": [] + }, + "forwarded_request_details": { + "description": "Details about the request forwarded to the destination endpoint.", + "properties": { + "body": { + "description": "The body payload to send to the destination endpoint.", + "maxLength": 5000, + "type": "string" + }, + "headers": { + "description": "The headers to include in the forwarded request. Can be omitted if no additional headers (excluding Stripe-generated ones such as the Content-Type header) should be included.", "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" + "$ref": "#/components/schemas/forwarded_request_header" + }, + "type": "array" + }, + "http_method": { + "description": "The HTTP method used to call the destination endpoint.", + "enum": ["POST"], + "type": "string" + } + }, + "required": ["body", "headers", "http_method"], + "title": "ForwardedRequestDetails", + "type": "object", + "x-expandableFields": ["headers"] + }, + "forwarded_request_header": { + "description": "Header data.", + "properties": { + "name": { + "description": "The header name.", + "maxLength": 5000, + "type": "string" + }, + "value": { + "description": "The header value.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["name", "value"], + "title": "ForwardedRequestHeader", + "type": "object", + "x-expandableFields": [] + }, + "forwarded_response_details": { + "description": "Details about the response from the destination endpoint.", + "properties": { + "body": { + "description": "The response body from the destination endpoint to Stripe.", + "maxLength": 5000, + "type": "string" + }, + "headers": { + "description": "HTTP headers that the destination endpoint returned.", + "items": { + "$ref": "#/components/schemas/forwarded_request_header" + }, + "type": "array" + }, + "status": { + "description": "The HTTP status code that the destination endpoint returned.", + "type": "integer" + } + }, + "required": ["body", "headers", "status"], + "title": "ForwardedResponseDetails", + "type": "object", + "x-expandableFields": ["headers"] + }, + "forwarding.request": { + "description": "Instructs Stripe to make a request on your behalf using the destination URL. The destination URL\nis activated by Stripe at the time of onboarding. Stripe verifies requests with your credentials\nprovided during onboarding, and injects card details from the payment_method into the request.\n\nStripe redacts all sensitive fields and headers, including authentication credentials and card numbers,\nbefore storing the request and response data in the forwarding Request object, which are subject to a\n30-day retention period.\n\nYou can provide a Stripe idempotency key to make sure that requests with the same key result in only one\noutbound request. The Stripe idempotency key provided should be unique and different from any idempotency\nkeys provided on the underlying third-party request.\n\nForwarding Requests are synchronous requests that return a response or time out according to\nStripe’s limits.\n\nRelated guide: [Forward card details to third-party API endpoints](https://docs.stripe.com/payments/forwarding).", + "properties": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["forwarding.request"], + "type": "string" + }, + "payment_method": { + "description": "The PaymentMethod to insert into the forwarded request. Forwarding previously consumed PaymentMethods is allowed.", + "maxLength": 5000, + "type": "string" + }, + "replacements": { + "description": "The field kinds to be replaced in the forwarded request.", + "items": { + "enum": [ + "card_cvc", + "card_expiry", + "card_number", + "cardholder_name" ], "type": "string" }, + "type": "array" + }, + "request_context": { + "anyOf": [ + { + "$ref": "#/components/schemas/forwarded_request_context" + } + ], + "description": "Context about the request from Stripe's servers to the destination endpoint.", + "nullable": true + }, + "request_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/forwarded_request_details" + } + ], + "description": "The request that was sent to the destination endpoint. We redact any sensitive fields.", + "nullable": true + }, + "response_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/forwarded_response_details" + } + ], + "description": "The response that the destination endpoint returned to us. We redact any sensitive fields.", + "nullable": true + }, + "url": { + "description": "The destination URL for the forwarded request. Must be supported by the config.", + "maxLength": 5000, "nullable": true, + "type": "string" + } + }, + "required": [ + "created", + "id", + "livemode", + "object", + "payment_method", + "replacements" + ], + "title": "ForwardingRequest", + "type": "object", + "x-expandableFields": [ + "request_context", + "request_details", + "response_details" + ], + "x-resourceId": "forwarding.request" + }, + "funding_instructions": { + "description": "Each customer has a [`balance`](https://stripe.com/docs/api/customers/object#customer_object-balance) that is\nautomatically applied to future invoices and payments using the `customer_balance` payment method.\nCustomers can fund this balance by initiating a bank transfer to any account in the\n`financial_addresses` field.\nRelated guide: [Customer balance funding instructions](https://stripe.com/docs/payments/customer-balance/funding-instructions)", + "properties": { + "bank_transfer": { + "$ref": "#/components/schemas/funding_instructions_bank_transfer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "maxLength": 5000, + "type": "string" + }, + "funding_type": { + "description": "The `funding_type` of the returned instructions", + "enum": ["bank_transfer"], + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["funding_instructions"], + "type": "string" + } + }, + "required": [ + "bank_transfer", + "currency", + "funding_type", + "livemode", + "object" + ], + "title": "CustomerBalanceFundingInstructionsCustomerBalanceFundingInstructions", + "type": "object", + "x-expandableFields": ["bank_transfer"], + "x-resourceId": "funding_instructions" + }, + "funding_instructions_bank_transfer": { + "description": "", + "properties": { + "country": { + "description": "The country of the bank account to fund", + "maxLength": 5000, + "type": "string" + }, + "financial_addresses": { + "description": "A list of financial addresses that can be used to fund a particular balance", + "items": { + "$ref": "#/components/schemas/funding_instructions_bank_transfer_financial_address" + }, "type": "array" }, - "blocked_categories": { - "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.", + "type": { + "description": "The bank_transfer type", + "enum": ["eu_bank_transfer", "jp_bank_transfer"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["country", "financial_addresses", "type"], + "title": "FundingInstructionsBankTransfer", + "type": "object", + "x-expandableFields": ["financial_addresses"] + }, + "funding_instructions_bank_transfer_aba_record": { + "description": "ABA Records contain U.S. bank account details per the ABA format.", + "properties": { + "account_number": { + "description": "The ABA account number", + "maxLength": 5000, + "type": "string" + }, + "bank_name": { + "description": "The bank name", + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "description": "The ABA routing number", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "bank_name", "routing_number"], + "title": "FundingInstructionsBankTransferABARecord", + "type": "object", + "x-expandableFields": [] + }, + "funding_instructions_bank_transfer_financial_address": { + "description": "FinancialAddresses contain identifying information that resolves to a FinancialAccount.", + "properties": { + "aba": { + "$ref": "#/components/schemas/funding_instructions_bank_transfer_aba_record" + }, + "iban": { + "$ref": "#/components/schemas/funding_instructions_bank_transfer_iban_record" + }, + "sort_code": { + "$ref": "#/components/schemas/funding_instructions_bank_transfer_sort_code_record" + }, + "spei": { + "$ref": "#/components/schemas/funding_instructions_bank_transfer_spei_record" + }, + "supported_networks": { + "description": "The payment networks supported by this FinancialAddress", "items": { "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" + "ach", + "bacs", + "domestic_wire_us", + "fps", + "sepa", + "spei", + "swift", + "zengin" ], - "type": "string" + "type": "string", + "x-stripeBypassValidation": true }, - "nullable": true, "type": "array" }, - "spending_limits": { - "description": "Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).", - "items": { - "$ref": "#/components/schemas/issuing_card_spending_limit" - }, + "swift": { + "$ref": "#/components/schemas/funding_instructions_bank_transfer_swift_record" + }, + "type": { + "description": "The type of financial address", + "enum": ["aba", "iban", "sort_code", "spei", "swift", "zengin"], + "type": "string", + "x-stripeBypassValidation": true + }, + "zengin": { + "$ref": "#/components/schemas/funding_instructions_bank_transfer_zengin_record" + } + }, + "required": ["type"], + "title": "FundingInstructionsBankTransferFinancialAddress", + "type": "object", + "x-expandableFields": [ + "aba", + "iban", + "sort_code", + "spei", + "swift", + "zengin" + ] + }, + "funding_instructions_bank_transfer_iban_record": { + "description": "Iban Records contain E.U. bank account details per the SEPA format.", + "properties": { + "account_holder_name": { + "description": "The name of the person or business that owns the bank account", + "maxLength": 5000, + "type": "string" + }, + "bic": { + "description": "The BIC/SWIFT code of the account.", + "maxLength": 5000, + "type": "string" + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "iban": { + "description": "The IBAN of the account.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_holder_name", "bic", "country", "iban"], + "title": "FundingInstructionsBankTransferIbanRecord", + "type": "object", + "x-expandableFields": [] + }, + "funding_instructions_bank_transfer_sort_code_record": { + "description": "Sort Code Records contain U.K. bank account details per the sort code format.", + "properties": { + "account_holder_name": { + "description": "The name of the person or business that owns the bank account", + "maxLength": 5000, + "type": "string" + }, + "account_number": { + "description": "The account number", + "maxLength": 5000, + "type": "string" + }, + "sort_code": { + "description": "The six-digit sort code", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_holder_name", "account_number", "sort_code"], + "title": "FundingInstructionsBankTransferSortCodeRecord", + "type": "object", + "x-expandableFields": [] + }, + "funding_instructions_bank_transfer_spei_record": { + "description": "SPEI Records contain Mexico bank account details per the SPEI format.", + "properties": { + "bank_code": { + "description": "The three-digit bank code", + "maxLength": 5000, + "type": "string" + }, + "bank_name": { + "description": "The short banking institution name", + "maxLength": 5000, + "type": "string" + }, + "clabe": { + "description": "The CLABE number", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["bank_code", "bank_name", "clabe"], + "title": "FundingInstructionsBankTransferSpeiRecord", + "type": "object", + "x-expandableFields": [] + }, + "funding_instructions_bank_transfer_swift_record": { + "description": "SWIFT Records contain U.S. bank account details per the SWIFT format.", + "properties": { + "account_number": { + "description": "The account number", + "maxLength": 5000, + "type": "string" + }, + "bank_name": { + "description": "The bank name", + "maxLength": 5000, + "type": "string" + }, + "swift_code": { + "description": "The SWIFT code", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "bank_name", "swift_code"], + "title": "FundingInstructionsBankTransferSwiftRecord", + "type": "object", + "x-expandableFields": [] + }, + "funding_instructions_bank_transfer_zengin_record": { + "description": "Zengin Records contain Japan bank account details per the Zengin format.", + "properties": { + "account_holder_name": { + "description": "The account holder name", + "maxLength": 5000, "nullable": true, - "type": "array" + "type": "string" }, - "spending_limits_currency": { - "description": "Currency of the amounts within `spending_limits`. Always the same as the currency of the card.", + "account_number": { + "description": "The account number", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "account_type": { + "description": "The bank account type. In Japan, this can only be `futsu` or `toza`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "bank_code": { + "description": "The bank code of the account", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "bank_name": { + "description": "The bank name of the account", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "branch_code": { + "description": "The branch code of the account", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "branch_name": { + "description": "The branch name of the account", + "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "IssuingCardAuthorizationControls", + "title": "FundingInstructionsBankTransferZenginRecord", "type": "object", - "x-expandableFields": ["spending_limits"] + "x-expandableFields": [] }, - "issuing_card_shipping": { - "description": "", + "gelato_data_document_report_date_of_birth": { + "description": "Point in Time", "properties": { - "address": { - "$ref": "#/components/schemas/address" + "day": { + "description": "Numerical day between 1 and 31.", + "nullable": true, + "type": "integer" }, - "carrier": { - "description": "The delivery company that shipped a card.", - "enum": ["fedex", "usps"], + "month": { + "description": "Numerical month between 1 and 12.", "nullable": true, - "type": "string", - "x-stripeBypassValidation": true + "type": "integer" }, - "eta": { - "description": "A unix timestamp representing a best estimate of when the card will be delivered.", - "format": "unix-time", + "year": { + "description": "The four-digit year.", + "nullable": true, + "type": "integer" + } + }, + "title": "GelatoDataDocumentReportDateOfBirth", + "type": "object", + "x-expandableFields": [] + }, + "gelato_data_document_report_expiration_date": { + "description": "Point in Time", + "properties": { + "day": { + "description": "Numerical day between 1 and 31.", "nullable": true, "type": "integer" }, - "name": { - "description": "Recipient name.", + "month": { + "description": "Numerical month between 1 and 12.", + "nullable": true, + "type": "integer" + }, + "year": { + "description": "The four-digit year.", + "nullable": true, + "type": "integer" + } + }, + "title": "GelatoDataDocumentReportExpirationDate", + "type": "object", + "x-expandableFields": [] + }, + "gelato_data_document_report_issued_date": { + "description": "Point in Time", + "properties": { + "day": { + "description": "Numerical day between 1 and 31.", + "nullable": true, + "type": "integer" + }, + "month": { + "description": "Numerical month between 1 and 12.", + "nullable": true, + "type": "integer" + }, + "year": { + "description": "The four-digit year.", + "nullable": true, + "type": "integer" + } + }, + "title": "GelatoDataDocumentReportIssuedDate", + "type": "object", + "x-expandableFields": [] + }, + "gelato_data_id_number_report_date": { + "description": "Point in Time", + "properties": { + "day": { + "description": "Numerical day between 1 and 31.", + "nullable": true, + "type": "integer" + }, + "month": { + "description": "Numerical month between 1 and 12.", + "nullable": true, + "type": "integer" + }, + "year": { + "description": "The four-digit year.", + "nullable": true, + "type": "integer" + } + }, + "title": "GelatoDataIdNumberReportDate", + "type": "object", + "x-expandableFields": [] + }, + "gelato_data_verified_outputs_date": { + "description": "Point in Time", + "properties": { + "day": { + "description": "Numerical day between 1 and 31.", + "nullable": true, + "type": "integer" + }, + "month": { + "description": "Numerical month between 1 and 12.", + "nullable": true, + "type": "integer" + }, + "year": { + "description": "The four-digit year.", + "nullable": true, + "type": "integer" + } + }, + "title": "GelatoDataVerifiedOutputsDate", + "type": "object", + "x-expandableFields": [] + }, + "gelato_document_report": { + "description": "Result from a document check", + "properties": { + "address": { + "anyOf": [ + { + "$ref": "#/components/schemas/address" + } + ], + "description": "Address as it appears in the document.", + "nullable": true + }, + "dob": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_data_document_report_date_of_birth" + } + ], + "description": "Date of birth as it appears in the document.", + "nullable": true + }, + "error": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_document_report_error" + } + ], + "description": "Details on the verification error. Present when status is `unverified`.", + "nullable": true + }, + "expiration_date": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_data_document_report_expiration_date" + } + ], + "description": "Expiration date of the document.", + "nullable": true + }, + "files": { + "description": "Array of [File](https://stripe.com/docs/api/files) ids containing images for this document.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "first_name": { + "description": "First name as it appears in the document.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "service": { - "description": "Shipment service, such as `standard` or `express`.", - "enum": ["express", "priority", "standard"], - "type": "string", - "x-stripeBypassValidation": true - }, - "status": { - "description": "The delivery status of the card.", - "enum": [ - "canceled", - "delivered", - "failure", - "pending", - "returned", - "shipped" + "issued_date": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_data_document_report_issued_date" + } ], + "description": "Issued date of the document.", + "nullable": true + }, + "issuing_country": { + "description": "Issuing country of the document.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "tracking_number": { - "description": "A tracking number for a card shipment.", + "last_name": { + "description": "Last name as it appears in the document.", "maxLength": 5000, "nullable": true, "type": "string" }, - "tracking_url": { - "description": "A link to the shipping carrier's site where you can view detailed information about a card shipment.", + "number": { + "description": "Document ID number.", "maxLength": 5000, "nullable": true, "type": "string" }, + "status": { + "description": "Status of this `document` check.", + "enum": ["unverified", "verified"], + "type": "string", + "x-stripeBypassValidation": true + }, "type": { - "description": "Packaging options.", - "enum": ["bulk", "individual"], + "description": "Type of the document.", + "enum": ["driving_license", "id_card", "passport"], + "nullable": true, "type": "string" } }, - "required": ["address", "name", "service", "type"], - "title": "IssuingCardShipping", + "required": ["status"], + "title": "GelatoDocumentReport", "type": "object", - "x-expandableFields": ["address"] + "x-expandableFields": [ + "address", + "dob", + "error", + "expiration_date", + "issued_date" + ] }, - "issuing_card_spending_limit": { + "gelato_document_report_error": { "description": "", "properties": { - "amount": { - "description": "Maximum amount allowed to spend per interval.", - "type": "integer" + "code": { + "description": "A short machine-readable string giving the reason for the verification failure.", + "enum": [ + "document_expired", + "document_type_not_supported", + "document_unverified_other" + ], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true }, - "categories": { - "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.", - "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], - "type": "string" - }, + "reason": { + "description": "A human-readable message giving the reason for the failure. These messages can be shown to your users.", + "maxLength": 5000, "nullable": true, - "type": "array" + "type": "string" + } + }, + "title": "GelatoDocumentReportError", + "type": "object", + "x-expandableFields": [] + }, + "gelato_email_report": { + "description": "Result from a email check", + "properties": { + "email": { + "description": "Email to be verified.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "interval": { - "description": "Interval (or event) to which the amount applies.", + "error": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_email_report_error" + } + ], + "description": "Details on the verification error. Present when status is `unverified`.", + "nullable": true + }, + "status": { + "description": "Status of this `email` check.", + "enum": ["unverified", "verified"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["status"], + "title": "GelatoEmailReport", + "type": "object", + "x-expandableFields": ["error"] + }, + "gelato_email_report_error": { + "description": "", + "properties": { + "code": { + "description": "A short machine-readable string giving the reason for the verification failure.", + "enum": ["email_unverified_other", "email_verification_declined"], + "nullable": true, + "type": "string" + }, + "reason": { + "description": "A human-readable message giving the reason for the failure. These messages can be shown to your users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "GelatoEmailReportError", + "type": "object", + "x-expandableFields": [] + }, + "gelato_id_number_report": { + "description": "Result from an id_number check", + "properties": { + "dob": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_data_id_number_report_date" + } + ], + "description": "Date of birth.", + "nullable": true + }, + "error": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_id_number_report_error" + } + ], + "description": "Details on the verification error. Present when status is `unverified`.", + "nullable": true + }, + "first_name": { + "description": "First name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id_number": { + "description": "ID number. When `id_number_type` is `us_ssn`, only the last 4 digits are present.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id_number_type": { + "description": "Type of ID number.", + "enum": ["br_cpf", "sg_nric", "us_ssn"], + "nullable": true, + "type": "string" + }, + "last_name": { + "description": "Last name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "status": { + "description": "Status of this `id_number` check.", + "enum": ["unverified", "verified"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["status"], + "title": "GelatoIdNumberReport", + "type": "object", + "x-expandableFields": ["dob", "error"] + }, + "gelato_id_number_report_error": { + "description": "", + "properties": { + "code": { + "description": "A short machine-readable string giving the reason for the verification failure.", "enum": [ - "all_time", - "daily", - "monthly", - "per_authorization", - "weekly", - "yearly" + "id_number_insufficient_document_data", + "id_number_mismatch", + "id_number_unverified_other" ], + "nullable": true, + "type": "string" + }, + "reason": { + "description": "A human-readable message giving the reason for the failure. These messages can be shown to your users.", + "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["amount", "interval"], - "title": "IssuingCardSpendingLimit", + "title": "GelatoIdNumberReportError", "type": "object", "x-expandableFields": [] }, - "issuing_cardholder_address": { + "gelato_phone_report": { + "description": "Result from a phone check", + "properties": { + "error": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_phone_report_error" + } + ], + "description": "Details on the verification error. Present when status is `unverified`.", + "nullable": true + }, + "phone": { + "description": "Phone to be verified.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "status": { + "description": "Status of this `phone` check.", + "enum": ["unverified", "verified"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["status"], + "title": "GelatoPhoneReport", + "type": "object", + "x-expandableFields": ["error"] + }, + "gelato_phone_report_error": { "description": "", "properties": { - "address": { - "$ref": "#/components/schemas/address" + "code": { + "description": "A short machine-readable string giving the reason for the verification failure.", + "enum": ["phone_unverified_other", "phone_verification_declined"], + "nullable": true, + "type": "string" + }, + "reason": { + "description": "A human-readable message giving the reason for the failure. These messages can be shown to your users.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "required": ["address"], - "title": "IssuingCardholderAddress", + "title": "GelatoPhoneReportError", "type": "object", - "x-expandableFields": ["address"] + "x-expandableFields": [] }, - "issuing_cardholder_authorization_controls": { + "gelato_provided_details": { "description": "", "properties": { - "allowed_categories": { - "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.", + "email": { + "description": "Email of user being verified", + "maxLength": 5000, + "type": "string" + }, + "phone": { + "description": "Phone number of user being verified", + "maxLength": 5000, + "type": "string" + } + }, + "title": "GelatoProvidedDetails", + "type": "object", + "x-expandableFields": [] + }, + "gelato_report_document_options": { + "description": "", + "properties": { + "allowed_types": { + "description": "Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.", "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], + "enum": ["driving_license", "id_card", "passport"], "type": "string" }, - "nullable": true, "type": "array" }, - "blocked_categories": { - "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.", + "require_id_number": { + "description": "Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.", + "type": "boolean" + }, + "require_live_capture": { + "description": "Disable image uploads, identity document images have to be captured using the device’s camera.", + "type": "boolean" + }, + "require_matching_selfie": { + "description": "Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).", + "type": "boolean" + } + }, + "title": "GelatoReportDocumentOptions", + "type": "object", + "x-expandableFields": [] + }, + "gelato_report_id_number_options": { + "description": "", + "properties": {}, + "title": "GelatoReportIdNumberOptions", + "type": "object", + "x-expandableFields": [] + }, + "gelato_selfie_report": { + "description": "Result from a selfie check", + "properties": { + "document": { + "description": "ID of the [File](https://stripe.com/docs/api/files) holding the image of the identity document used in this check.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "error": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_selfie_report_error" + } + ], + "description": "Details on the verification error. Present when status is `unverified`.", + "nullable": true + }, + "selfie": { + "description": "ID of the [File](https://stripe.com/docs/api/files) holding the image of the selfie used in this check.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "status": { + "description": "Status of this `selfie` check.", + "enum": ["unverified", "verified"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["status"], + "title": "GelatoSelfieReport", + "type": "object", + "x-expandableFields": ["error"] + }, + "gelato_selfie_report_error": { + "description": "", + "properties": { + "code": { + "description": "A short machine-readable string giving the reason for the verification failure.", + "enum": [ + "selfie_document_missing_photo", + "selfie_face_mismatch", + "selfie_manipulated", + "selfie_unverified_other" + ], + "nullable": true, + "type": "string" + }, + "reason": { + "description": "A human-readable message giving the reason for the failure. These messages can be shown to your users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "GelatoSelfieReportError", + "type": "object", + "x-expandableFields": [] + }, + "gelato_session_document_options": { + "description": "", + "properties": { + "allowed_types": { + "description": "Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.", "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], + "enum": ["driving_license", "id_card", "passport"], "type": "string" }, - "nullable": true, "type": "array" }, - "spending_limits": { - "description": "Limit spending with amount-based rules that apply across this cardholder's cards.", - "items": { - "$ref": "#/components/schemas/issuing_cardholder_spending_limit" - }, + "require_id_number": { + "description": "Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.", + "type": "boolean" + }, + "require_live_capture": { + "description": "Disable image uploads, identity document images have to be captured using the device’s camera.", + "type": "boolean" + }, + "require_matching_selfie": { + "description": "Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).", + "type": "boolean" + } + }, + "title": "GelatoSessionDocumentOptions", + "type": "object", + "x-expandableFields": [] + }, + "gelato_session_email_options": { + "description": "", + "properties": { + "require_verification": { + "description": "Request one time password verification of `provided_details.email`.", + "type": "boolean" + } + }, + "title": "GelatoSessionEmailOptions", + "type": "object", + "x-expandableFields": [] + }, + "gelato_session_id_number_options": { + "description": "", + "properties": {}, + "title": "GelatoSessionIdNumberOptions", + "type": "object", + "x-expandableFields": [] + }, + "gelato_session_last_error": { + "description": "Shows last VerificationSession error", + "properties": { + "code": { + "description": "A short machine-readable string giving the reason for the verification or user-session failure.", + "enum": [ + "abandoned", + "consent_declined", + "country_not_supported", + "device_not_supported", + "document_expired", + "document_type_not_supported", + "document_unverified_other", + "email_unverified_other", + "email_verification_declined", + "id_number_insufficient_document_data", + "id_number_mismatch", + "id_number_unverified_other", + "phone_unverified_other", + "phone_verification_declined", + "selfie_document_missing_photo", + "selfie_face_mismatch", + "selfie_manipulated", + "selfie_unverified_other", + "under_supported_age" + ], "nullable": true, - "type": "array" + "type": "string", + "x-stripeBypassValidation": true }, - "spending_limits_currency": { - "description": "Currency of the amounts within `spending_limits`.", + "reason": { + "description": "A message that explains the reason for verification or user-session failure.", + "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "IssuingCardholderAuthorizationControls", + "title": "GelatoSessionLastError", "type": "object", - "x-expandableFields": ["spending_limits"] + "x-expandableFields": [] }, - "issuing_cardholder_company": { + "gelato_session_phone_options": { "description": "", "properties": { - "tax_id_provided": { - "description": "Whether the company's business ID number was provided.", + "require_verification": { + "description": "Request one time password verification of `provided_details.phone`.", "type": "boolean" } }, - "required": ["tax_id_provided"], - "title": "IssuingCardholderCompany", + "title": "GelatoSessionPhoneOptions", "type": "object", "x-expandableFields": [] }, - "issuing_cardholder_id_document": { + "gelato_verification_report_options": { "description": "", "properties": { - "back": { + "document": { + "$ref": "#/components/schemas/gelato_report_document_options" + }, + "id_number": { + "$ref": "#/components/schemas/gelato_report_id_number_options" + } + }, + "title": "GelatoVerificationReportOptions", + "type": "object", + "x-expandableFields": ["document", "id_number"] + }, + "gelato_verification_session_options": { + "description": "", + "properties": { + "document": { + "$ref": "#/components/schemas/gelato_session_document_options" + }, + "email": { + "$ref": "#/components/schemas/gelato_session_email_options" + }, + "id_number": { + "$ref": "#/components/schemas/gelato_session_id_number_options" + }, + "phone": { + "$ref": "#/components/schemas/gelato_session_phone_options" + } + }, + "title": "GelatoVerificationSessionOptions", + "type": "object", + "x-expandableFields": ["document", "email", "id_number", "phone"] + }, + "gelato_verified_outputs": { + "description": "", + "properties": { + "address": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, + "$ref": "#/components/schemas/address" + } + ], + "description": "The user's verified address.", + "nullable": true + }, + "dob": { + "anyOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/gelato_data_verified_outputs_date" } ], - "description": "The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.", + "description": "The user’s verified date of birth.", + "nullable": true + }, + "email": { + "description": "The user's verified email address", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/file" - } - ] - } + "type": "string" }, - "front": { + "first_name": { + "description": "The user's verified first name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id_number": { + "description": "The user's verified id number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id_number_type": { + "description": "The user's verified id number type.", + "enum": ["br_cpf", "sg_nric", "us_ssn"], + "nullable": true, + "type": "string" + }, + "last_name": { + "description": "The user's verified last name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "phone": { + "description": "The user's verified phone number", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "GelatoVerifiedOutputs", + "type": "object", + "x-expandableFields": ["address", "dob"] + }, + "identity.verification_report": { + "description": "A VerificationReport is the result of an attempt to collect and verify data from a user.\nThe collection of verification checks performed is determined from the `type` and `options`\nparameters used. You can find the result of each verification check performed in the\nappropriate sub-resource: `document`, `id_number`, `selfie`.\n\nEach VerificationReport contains a copy of any data collected by the user as well as\nreference IDs which can be used to access collected images through the [FileUpload](https://stripe.com/docs/api/files)\nAPI. To configure and create VerificationReports, use the\n[VerificationSession](https://stripe.com/docs/api/identity/verification_sessions) API.\n\nRelated guide: [Accessing verification results](https://stripe.com/docs/identity/verification-sessions#results).", + "properties": { + "client_reference_id": { + "description": "A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "document": { + "$ref": "#/components/schemas/gelato_document_report" + }, + "email": { + "$ref": "#/components/schemas/gelato_email_report" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "id_number": { + "$ref": "#/components/schemas/gelato_id_number_report" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["identity.verification_report"], + "type": "string" + }, + "options": { + "$ref": "#/components/schemas/gelato_verification_report_options" + }, + "phone": { + "$ref": "#/components/schemas/gelato_phone_report" + }, + "selfie": { + "$ref": "#/components/schemas/gelato_selfie_report" + }, + "type": { + "description": "Type of report.", + "enum": ["document", "id_number", "verification_flow"], + "type": "string", + "x-stripeBypassValidation": true + }, + "verification_flow": { + "description": "The configuration token of a Verification Flow from the dashboard.", + "maxLength": 5000, + "type": "string" + }, + "verification_session": { + "description": "ID of the VerificationSession that created this report.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["created", "id", "livemode", "object", "type"], + "title": "GelatoVerificationReport", + "type": "object", + "x-expandableFields": [ + "document", + "email", + "id_number", + "options", + "phone", + "selfie" + ], + "x-resourceId": "identity.verification_report" + }, + "identity.verification_session": { + "description": "A VerificationSession guides you through the process of collecting and verifying the identities\nof your users. It contains details about the type of verification, such as what [verification\ncheck](/docs/identity/verification-checks) to perform. Only create one VerificationSession for\neach verification in your system.\n\nA VerificationSession transitions through [multiple\nstatuses](/docs/identity/how-sessions-work) throughout its lifetime as it progresses through\nthe verification flow. The VerificationSession contains the user's verified data after\nverification checks are complete.\n\nRelated guide: [The Verification Sessions API](https://stripe.com/docs/identity/verification-sessions)", + "properties": { + "client_reference_id": { + "description": "A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "client_secret": { + "description": "The short-lived client secret used by Stripe.js to [show a verification modal](https://stripe.com/docs/js/identity/modal) inside your app. This client secret expires after 24 hours and can only be used once. Don’t store it, log it, embed it in a URL, or expose it to anyone other than the user. Make sure that you have TLS enabled on any page that includes the client secret. Refer to our docs on [passing the client secret to the frontend](https://stripe.com/docs/identity/verification-sessions#client-secret) to learn more.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "last_error": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_session_last_error" + } + ], + "description": "If present, this property tells you the last error encountered when processing the verification.", + "nullable": true + }, + "last_verification_report": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/identity.verification_report" } ], - "description": "The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.", + "description": "ID of the most recent VerificationReport. [Learn more about accessing detailed verification results.](https://stripe.com/docs/identity/verification-sessions#results)", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/identity.verification_report" } ] } - } - }, - "title": "IssuingCardholderIdDocument", - "type": "object", - "x-expandableFields": ["back", "front"] - }, - "issuing_cardholder_individual": { - "description": "", - "properties": { - "dob": { + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["identity.verification_session"], + "type": "string" + }, + "options": { "anyOf": [ { - "$ref": "#/components/schemas/issuing_cardholder_individual_dob" + "$ref": "#/components/schemas/gelato_verification_session_options" } ], - "description": "The date of birth of this cardholder.", + "description": "A set of options for the session’s verification checks.", "nullable": true }, - "first_name": { - "description": "The first name of this cardholder.", + "provided_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/gelato_provided_details" + } + ], + "description": "Details provided about the user being verified. These details may be shown to the user.", + "nullable": true + }, + "redaction": { + "anyOf": [ + { + "$ref": "#/components/schemas/verification_session_redaction" + } + ], + "description": "Redaction status of this VerificationSession. If the VerificationSession is not redacted, this field will be null.", + "nullable": true + }, + "related_customer": { + "description": "Token referencing a Customer resource.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "last_name": { - "description": "The last name of this cardholder.", + "status": { + "description": "Status of this VerificationSession. [Learn more about the lifecycle of sessions](https://stripe.com/docs/identity/how-sessions-work).", + "enum": ["canceled", "processing", "requires_input", "verified"], + "type": "string" + }, + "type": { + "description": "The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.", + "enum": ["document", "id_number", "verification_flow"], + "type": "string", + "x-stripeBypassValidation": true + }, + "url": { + "description": "The short-lived URL that you use to redirect a user to Stripe to submit their identity information. This URL expires after 48 hours and can only be used once. Don’t store it, log it, send it in emails or expose it to anyone other than the user. Refer to our docs on [verifying identity documents](https://stripe.com/docs/identity/verify-identity-documents?platform=web&type=redirect) to learn how to redirect users to Stripe.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "verification": { + "verification_flow": { + "description": "The configuration token of a Verification Flow from the dashboard.", + "maxLength": 5000, + "type": "string" + }, + "verified_outputs": { "anyOf": [ { - "$ref": "#/components/schemas/issuing_cardholder_verification" + "$ref": "#/components/schemas/gelato_verified_outputs" } ], - "description": "Government-issued ID document for this cardholder.", + "description": "The user’s verified data.", "nullable": true } }, - "required": ["first_name", "last_name"], - "title": "IssuingCardholderIndividual", + "required": [ + "created", + "id", + "livemode", + "metadata", + "object", + "status", + "type" + ], + "title": "GelatoVerificationSession", "type": "object", - "x-expandableFields": ["dob", "verification"] + "x-expandableFields": [ + "last_error", + "last_verification_report", + "options", + "provided_details", + "redaction", + "verified_outputs" + ], + "x-resourceId": "identity.verification_session" }, - "issuing_cardholder_individual_dob": { + "inbound_transfers": { "description": "", "properties": { - "day": { - "description": "The day of birth, between 1 and 31.", + "billing_details": { + "$ref": "#/components/schemas/treasury_shared_resource_billing_details" + }, + "type": { + "description": "The type of the payment method used in the InboundTransfer.", + "enum": ["us_bank_account"], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "$ref": "#/components/schemas/inbound_transfers_payment_method_details_us_bank_account" + } + }, + "required": ["billing_details", "type"], + "title": "InboundTransfers", + "type": "object", + "x-expandableFields": ["billing_details", "us_bank_account"] + }, + "inbound_transfers_payment_method_details_us_bank_account": { + "description": "", + "properties": { + "account_holder_type": { + "description": "Account holder type: individual or company.", + "enum": ["company", "individual"], "nullable": true, - "type": "integer" + "type": "string" }, - "month": { - "description": "The month of birth, between 1 and 12.", + "account_type": { + "description": "Account type: checkings or savings. Defaults to checking if omitted.", + "enum": ["checking", "savings"], "nullable": true, - "type": "integer" + "type": "string" }, - "year": { - "description": "The four-digit year of birth.", + "bank_name": { + "description": "Name of the bank associated with the bank account.", + "maxLength": 5000, "nullable": true, - "type": "integer" + "type": "string" + }, + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/mandate" + } + ], + "description": "ID of the mandate used to make this payment.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" + } + ] + } + }, + "network": { + "description": "The network rails used. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.", + "enum": ["ach"], + "type": "string" + }, + "routing_number": { + "description": "Routing number of the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "title": "IssuingCardholderIndividualDOB", + "required": ["network"], + "title": "inbound_transfers_payment_method_details_us_bank_account", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["mandate"] }, - "issuing_cardholder_requirements": { + "internal_card": { "description": "", "properties": { - "disabled_reason": { - "description": "If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason.", - "enum": ["listed", "rejected.listed", "under_review"], + "brand": { + "description": "Brand of the card used in the transaction", + "maxLength": 5000, "nullable": true, "type": "string" }, - "past_due": { - "description": "Array of fields that need to be collected in order to verify and re-enable the cardholder.", - "items": { - "enum": [ - "company.tax_id", - "individual.dob.day", - "individual.dob.month", - "individual.dob.year", - "individual.first_name", - "individual.last_name", - "individual.verification.document" - ], - "type": "string", - "x-stripeBypassValidation": true - }, + "country": { + "description": "Two-letter ISO code representing the country of the card", + "maxLength": 5000, "nullable": true, - "type": "array" + "type": "string" + }, + "exp_month": { + "description": "Two digit number representing the card's expiration month", + "nullable": true, + "type": "integer" + }, + "exp_year": { + "description": "Two digit number representing the card's expiration year", + "nullable": true, + "type": "integer" + }, + "last4": { + "description": "The last 4 digits of the card", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "title": "IssuingCardholderRequirements", + "title": "internal_card", "type": "object", "x-expandableFields": [] }, - "issuing_cardholder_spending_limit": { - "description": "", + "invoice": { + "description": "Invoices are statements of amounts owed by a customer, and are either\ngenerated one-off, or generated periodically from a subscription.\n\nThey contain [invoice items](https://stripe.com/docs/api#invoiceitems), and proration adjustments\nthat may be caused by subscription upgrades/downgrades (if necessary).\n\nIf your invoice is configured to be billed through automatic charges,\nStripe automatically finalizes your invoice and attempts payment. Note\nthat finalizing the invoice,\n[when automatic](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection), does\nnot happen immediately as the invoice is created. Stripe waits\nuntil one hour after the last webhook was successfully sent (or the last\nwebhook timed out after failing). If you (and the platforms you may have\nconnected to) have no webhooks configured, Stripe waits one hour after\ncreation to finalize the invoice.\n\nIf your invoice is configured to be billed by sending an email, then based on your\n[email settings](https://dashboard.stripe.com/account/billing/automatic),\nStripe will email the invoice to your customer and await payment. These\nemails can contain a link to a hosted page to pay the invoice.\n\nStripe applies any customer credit on the account before determining the\namount due for the invoice (i.e., the amount that will be actually\ncharged). If the amount due for the invoice is less than Stripe's [minimum allowed charge\nper currency](/docs/currencies#minimum-and-maximum-charge-amounts), the\ninvoice is automatically marked paid, and we add the amount due to the\ncustomer's credit balance which is applied to the next invoice.\n\nMore details on the customer's credit balance are\n[here](https://stripe.com/docs/billing/customer/balance).\n\nRelated guide: [Send invoices to customers](https://stripe.com/docs/billing/invoices/sending)", "properties": { - "amount": { - "description": "Maximum amount allowed to spend per interval.", - "type": "integer" + "account_country": { + "description": "The country of the business associated with this invoice, most often the business creating the invoice.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "categories": { - "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.", + "account_name": { + "description": "The public name of the business associated with this invoice, most often the business creating the invoice.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "account_tax_ids": { + "description": "The account tax IDs associated with the invoice. Only editable when the invoice is a draft.", "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } ], - "type": "string" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ] + } }, "nullable": true, "type": "array" }, - "interval": { - "description": "Interval (or event) to which the amount applies.", - "enum": [ - "all_time", - "daily", - "monthly", - "per_authorization", - "weekly", - "yearly" - ], - "type": "string" - } - }, - "required": ["amount", "interval"], - "title": "IssuingCardholderSpendingLimit", - "type": "object", - "x-expandableFields": [] - }, - "issuing_cardholder_verification": { - "description": "", - "properties": { - "document": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_cardholder_id_document" - } - ], - "description": "An identifying document, either a passport or local ID card.", - "nullable": true - } - }, - "title": "IssuingCardholderVerification", - "type": "object", - "x-expandableFields": ["document"] - }, - "issuing_dispute_canceled_evidence": { - "description": "", - "properties": { - "additional_documentation": { + "amount_due": { + "description": "Final amount due at this time for this invoice. If the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the `amount_due` may be 0. If there is a positive `starting_balance` for the invoice (the customer owes money), the `amount_due` will also take that into account. The charge that gets generated for the invoice will be for the amount specified in `amount_due`.", + "type": "integer" + }, + "amount_paid": { + "description": "The amount, in cents (or local equivalent), that was paid.", + "type": "integer" + }, + "amount_remaining": { + "description": "The difference between amount_due and amount_paid, in cents (or local equivalent).", + "type": "integer" + }, + "amount_shipping": { + "description": "This is the sum of all the shipping amounts.", + "type": "integer" + }, + "application": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "description": "ID of the Connect Application that created the invoice.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" } ] } }, - "canceled_at": { - "description": "Date when order was canceled.", - "format": "unix-time", + "application_fee_amount": { + "description": "The fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account when the invoice is paid.", "nullable": true, "type": "integer" }, - "cancellation_policy_provided": { - "description": "Whether the cardholder was provided with a cancellation policy.", - "nullable": true, - "type": "boolean" - }, - "cancellation_reason": { - "description": "Reason for canceling the order.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "expected_at": { - "description": "Date when the cardholder expected to receive the product.", - "format": "unix-time", - "nullable": true, + "attempt_count": { + "description": "Number of payment attempts made for this invoice, from the perspective of the payment retry schedule. Any payment attempt counts as the first attempt, and subsequently only automatic retries increment the attempt count. In other words, manual payment attempts after the first attempt do not affect the retry schedule. If a failure is returned with a non-retryable return code, the invoice can no longer be retried unless a new payment method is obtained. Retries will continue to be scheduled, and attempt_count will continue to increment, but retries will only be executed if a new payment method is obtained.", "type": "integer" }, - "explanation": { - "description": "Explanation of why the cardholder is disputing this transaction.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "attempted": { + "description": "Whether an attempt has been made to pay the invoice. An invoice is not attempted until 1 hour after the `invoice.created` webhook, for example, so you might not want to display that invoice as unpaid to your users.", + "type": "boolean" }, - "product_description": { - "description": "Description of the merchandise or service that was purchased.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "auto_advance": { + "description": "Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice. If `false`, the invoice's state doesn't automatically advance without an explicit action.", + "type": "boolean" }, - "product_type": { - "description": "Whether the product was a merchandise or service.", - "enum": ["merchandise", "service"], - "nullable": true, - "type": "string" + "automatic_tax": { + "$ref": "#/components/schemas/automatic_tax" }, - "return_status": { - "description": "Result of cardholder's attempt to return the product.", - "enum": ["merchant_rejected", "successful"], + "billing_reason": { + "description": "Indicates the reason why the invoice was created.\n\n* `manual`: Unrelated to a subscription, for example, created via the invoice editor.\n* `subscription`: No longer in use. Applies to subscriptions from before May 2018 where no distinction was made between updates, cycles, and thresholds.\n* `subscription_create`: A new subscription was created.\n* `subscription_cycle`: A subscription advanced into a new period.\n* `subscription_threshold`: A subscription reached a billing threshold.\n* `subscription_update`: A subscription was updated.\n* `upcoming`: Reserved for simulated invoices, per the upcoming invoice endpoint.", + "enum": [ + "automatic_pending_invoice_item_invoice", + "manual", + "quote_accept", + "subscription", + "subscription_create", + "subscription_cycle", + "subscription_threshold", + "subscription_update", + "upcoming" + ], "nullable": true, "type": "string" }, - "returned_at": { - "description": "Date when the product was returned or attempted to be returned.", - "format": "unix-time", - "nullable": true, - "type": "integer" - } - }, - "title": "IssuingDisputeCanceledEvidence", - "type": "object", - "x-expandableFields": ["additional_documentation"] - }, - "issuing_dispute_duplicate_evidence": { - "description": "", - "properties": { - "additional_documentation": { + "charge": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/charge" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "description": "ID of the latest charge generated for this invoice, if any.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/charge" } ] } }, - "card_statement": { + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "custom_fields": { + "description": "Custom fields displayed on the invoice.", + "items": { + "$ref": "#/components/schemas/invoice_setting_custom_field" + }, + "nullable": true, + "type": "array" + }, + "customer": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.", + "description": "The ID of the customer who will be billed.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" } ] } }, - "cash_receipt": { + "customer_address": { + "anyOf": [ + { + "$ref": "#/components/schemas/address" + } + ], + "description": "The customer's address. Until the invoice is finalized, this field will equal `customer.address`. Once the invoice is finalized, this field will no longer be updated.", + "nullable": true + }, + "customer_email": { + "description": "The customer's email. Until the invoice is finalized, this field will equal `customer.email`. Once the invoice is finalized, this field will no longer be updated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "customer_name": { + "description": "The customer's name. Until the invoice is finalized, this field will equal `customer.name`. Once the invoice is finalized, this field will no longer be updated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "customer_phone": { + "description": "The customer's phone number. Until the invoice is finalized, this field will equal `customer.phone`. Once the invoice is finalized, this field will no longer be updated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "customer_shipping": { + "anyOf": [ + { + "$ref": "#/components/schemas/shipping" + } + ], + "description": "The customer's shipping information. Until the invoice is finalized, this field will equal `customer.shipping`. Once the invoice is finalized, this field will no longer be updated.", + "nullable": true + }, + "customer_tax_exempt": { + "description": "The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated.", + "enum": ["exempt", "none", "reverse"], + "nullable": true, + "type": "string" + }, + "customer_tax_ids": { + "description": "The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated.", + "items": { + "$ref": "#/components/schemas/invoices_resource_invoice_tax_id" + }, + "nullable": true, + "type": "array" + }, + "default_payment_method": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/payment_method" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.", + "description": "ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/payment_method" } ] } }, - "check_image": { + "default_source": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/source" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.", + "description": "ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/source" } ] - } + }, + "x-stripeBypassValidation": true }, - "explanation": { - "description": "Explanation of why the cardholder is disputing this transaction.", + "default_tax_rates": { + "description": "The tax rates applied to this invoice, if any.", + "items": { + "$ref": "#/components/schemas/tax_rate" + }, + "type": "array" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.", "maxLength": 5000, "nullable": true, "type": "string" }, - "original_transaction": { - "description": "Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.", + "discount": { + "anyOf": [ + { + "$ref": "#/components/schemas/discount" + } + ], + "description": "Describes the current discount applied to this invoice, if there is one. Not populated if there are multiple discounts.", + "nullable": true + }, + "discounts": { + "description": "The discounts applied to the invoice. Line item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/discount" + }, + { + "$ref": "#/components/schemas/deleted_discount" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/discount" + }, + { + "$ref": "#/components/schemas/deleted_discount" + } + ] + } + }, + "type": "array" + }, + "due_date": { + "description": "The date on which payment for this invoice is due. This value will be `null` for invoices where `collection_method=charge_automatically`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "effective_at": { + "description": "The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "ending_balance": { + "description": "Ending customer balance after the invoice is finalized. Invoices are finalized approximately an hour after successful webhook delivery or when payment collection is attempted for the invoice. If the invoice has not been finalized yet, this will be null.", + "nullable": true, + "type": "integer" + }, + "footer": { + "description": "Footer displayed on the invoice.", "maxLength": 5000, "nullable": true, "type": "string" - } - }, - "title": "IssuingDisputeDuplicateEvidence", - "type": "object", - "x-expandableFields": [ - "additional_documentation", - "card_statement", - "cash_receipt", - "check_image" - ] - }, - "issuing_dispute_evidence": { - "description": "", - "properties": { - "canceled": { - "$ref": "#/components/schemas/issuing_dispute_canceled_evidence" }, - "duplicate": { - "$ref": "#/components/schemas/issuing_dispute_duplicate_evidence" + "from_invoice": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoices_resource_from_invoice" + } + ], + "description": "Details of the invoice that was cloned. See the [revision documentation](https://stripe.com/docs/invoicing/invoice-revisions) for more details.", + "nullable": true }, - "fraudulent": { - "$ref": "#/components/schemas/issuing_dispute_fraudulent_evidence" + "hosted_invoice_url": { + "description": "The URL for the hosted invoice page, which allows customers to view and pay an invoice. If the invoice has not been finalized yet, this will be null.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "merchandise_not_as_described": { - "$ref": "#/components/schemas/issuing_dispute_merchandise_not_as_described_evidence" + "id": { + "description": "Unique identifier for the object. This property is always present unless the invoice is an upcoming invoice. See [Retrieve an upcoming invoice](https://stripe.com/docs/api/invoices/upcoming) for more details.", + "maxLength": 5000, + "type": "string" }, - "not_received": { - "$ref": "#/components/schemas/issuing_dispute_not_received_evidence" + "invoice_pdf": { + "description": "The link to download the PDF for the invoice. If the invoice has not been finalized yet, this will be null.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "other": { - "$ref": "#/components/schemas/issuing_dispute_other_evidence" + "issuer": { + "$ref": "#/components/schemas/connect_account_reference" }, - "reason": { - "description": "The reason for filing the dispute. Its value will match the field containing the evidence.", - "enum": [ - "canceled", - "duplicate", - "fraudulent", - "merchandise_not_as_described", - "not_received", - "other", - "service_not_as_described" + "last_finalization_error": { + "anyOf": [ + { + "$ref": "#/components/schemas/api_errors" + } ], - "type": "string", - "x-stripeBypassValidation": true + "description": "The error encountered during the previous attempt to finalize the invoice. This field is cleared when the invoice is successfully finalized.", + "nullable": true }, - "service_not_as_described": { - "$ref": "#/components/schemas/issuing_dispute_service_not_as_described_evidence" - } - }, - "required": ["reason"], - "title": "IssuingDisputeEvidence", - "type": "object", - "x-expandableFields": [ - "canceled", - "duplicate", - "fraudulent", - "merchandise_not_as_described", - "not_received", - "other", - "service_not_as_described" - ] - }, - "issuing_dispute_fraudulent_evidence": { - "description": "", - "properties": { - "additional_documentation": { + "latest_revision": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/invoice" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "description": "The ID of the most recent non-draft revision of this invoice", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/invoice" } ] } }, - "explanation": { - "description": "Explanation of why the cardholder is disputing this transaction.", + "lines": { + "description": "The individual line items that make up the invoice. `lines` is sorted as follows: (1) pending invoice items (including prorations) in reverse chronological order, (2) subscription items in reverse chronological order, and (3) invoice items added after invoice creation in chronological order.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/line_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "InvoiceLinesList", + "type": "object", + "x-expandableFields": ["data"] + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "next_payment_attempt": { + "description": "The time at which payment will next be attempted. This value will be `null` for invoices where `collection_method=send_invoice`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "number": { + "description": "A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified.", "maxLength": 5000, "nullable": true, "type": "string" - } - }, - "title": "IssuingDisputeFraudulentEvidence", - "type": "object", - "x-expandableFields": ["additional_documentation"] - }, - "issuing_dispute_merchandise_not_as_described_evidence": { - "description": "", - "properties": { - "additional_documentation": { + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["invoice"], + "type": "string" + }, + "on_behalf_of": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/account" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/account" } ] } }, - "explanation": { - "description": "Explanation of why the cardholder is disputing this transaction.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "received_at": { - "description": "Date when the product was received.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "return_description": { - "description": "Description of the cardholder's attempt to return the product.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "paid": { + "description": "Whether payment was successfully collected for this invoice. An invoice can be paid (most commonly) with a charge or with credit from the customer's account balance.", + "type": "boolean" }, - "return_status": { - "description": "Result of cardholder's attempt to return the product.", - "enum": ["merchant_rejected", "successful"], - "nullable": true, - "type": "string" + "paid_out_of_band": { + "description": "Returns true if the invoice was manually marked paid, returns false if the invoice hasn't been paid yet or was paid on Stripe.", + "type": "boolean" }, - "returned_at": { - "description": "Date when the product was returned or attempted to be returned.", - "format": "unix-time", - "nullable": true, - "type": "integer" - } - }, - "title": "IssuingDisputeMerchandiseNotAsDescribedEvidence", - "type": "object", - "x-expandableFields": ["additional_documentation"] - }, - "issuing_dispute_not_received_evidence": { - "description": "", - "properties": { - "additional_documentation": { + "payment_intent": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/payment_intent" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "description": "The PaymentIntent associated with this invoice. The PaymentIntent is generated when the invoice is finalized, and can then be used to pay the invoice. Note that voiding an invoice will cancel the PaymentIntent.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/payment_intent" } ] } }, - "expected_at": { - "description": "Date when the cardholder expected to receive the product.", + "payment_settings": { + "$ref": "#/components/schemas/invoices_payment_settings" + }, + "period_end": { + "description": "End of the usage period during which invoice items were added to this invoice. This looks back one period for a subscription invoice. Use the [line item period](/api/invoices/line_item#invoice_line_item_object-period) to get the service period for each price.", "format": "unix-time", - "nullable": true, "type": "integer" }, - "explanation": { - "description": "Explanation of why the cardholder is disputing this transaction.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "period_start": { + "description": "Start of the usage period during which invoice items were added to this invoice. This looks back one period for a subscription invoice. Use the [line item period](/api/invoices/line_item#invoice_line_item_object-period) to get the service period for each price.", + "format": "unix-time", + "type": "integer" }, - "product_description": { - "description": "Description of the merchandise or service that was purchased.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "post_payment_credit_notes_amount": { + "description": "Total amount of all post-payment credit notes issued for this invoice.", + "type": "integer" }, - "product_type": { - "description": "Whether the product was a merchandise or service.", - "enum": ["merchandise", "service"], - "nullable": true, - "type": "string" - } - }, - "title": "IssuingDisputeNotReceivedEvidence", - "type": "object", - "x-expandableFields": ["additional_documentation"] - }, - "issuing_dispute_other_evidence": { - "description": "", - "properties": { - "additional_documentation": { + "pre_payment_credit_notes_amount": { + "description": "Total amount of all pre-payment credit notes issued for this invoice.", + "type": "integer" + }, + "quote": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/quote" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "description": "The quote this invoice was generated from.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/quote" } ] } }, - "explanation": { - "description": "Explanation of why the cardholder is disputing this transaction.", + "receipt_number": { + "description": "This is the transaction number that appears on email receipts sent for this invoice.", "maxLength": 5000, "nullable": true, "type": "string" }, - "product_description": { - "description": "Description of the merchandise or service that was purchased.", + "rendering": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoices_resource_invoice_rendering" + } + ], + "description": "The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.", + "nullable": true + }, + "shipping_cost": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoices_resource_shipping_cost" + } + ], + "description": "The details of the cost of shipping, including the ShippingRate applied on the invoice.", + "nullable": true + }, + "shipping_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/shipping" + } + ], + "description": "Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.", + "nullable": true + }, + "starting_balance": { + "description": "Starting customer balance before the invoice is finalized. If the invoice has not been finalized yet, this will be the current customer balance. For revision invoices, this also includes any customer balance that was applied to the original invoice.", + "type": "integer" + }, + "statement_descriptor": { + "description": "Extra information about an invoice for the customer's credit card statement.", "maxLength": 5000, "nullable": true, "type": "string" }, - "product_type": { - "description": "Whether the product was a merchandise or service.", - "enum": ["merchandise", "service"], + "status": { + "description": "The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)", + "enum": ["draft", "open", "paid", "uncollectible", "void"], "nullable": true, - "type": "string" - } - }, - "title": "IssuingDisputeOtherEvidence", - "type": "object", - "x-expandableFields": ["additional_documentation"] - }, - "issuing_dispute_service_not_as_described_evidence": { - "description": "", - "properties": { - "additional_documentation": { + "type": "string", + "x-stripeBypassValidation": true + }, + "status_transitions": { + "$ref": "#/components/schemas/invoices_resource_status_transitions" + }, + "subscription": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/subscription" } ], - "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "description": "The subscription that this invoice was prepared for, if any.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/subscription" } ] } }, - "canceled_at": { - "description": "Date when order was canceled.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "subscription_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_details_data" + } + ], + "description": "Details about the subscription that created this invoice.", + "nullable": true }, - "cancellation_reason": { - "description": "Reason for canceling the order.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "subscription_proration_date": { + "description": "Only set for upcoming invoices that preview prorations. The time used to calculate prorations.", + "type": "integer" }, - "explanation": { - "description": "Explanation of why the cardholder is disputing this transaction.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "subtotal": { + "description": "Total of all subscriptions, invoice items, and prorations on the invoice before any invoice level discount or exclusive tax is applied. Item discounts are already incorporated", + "type": "integer" }, - "received_at": { - "description": "Date when the product was received.", - "format": "unix-time", + "subtotal_excluding_tax": { + "description": "The integer amount in cents (or local equivalent) representing the subtotal of the invoice before any invoice level discount or tax is applied. Item discounts are already incorporated", "nullable": true, "type": "integer" - } - }, - "title": "IssuingDisputeServiceNotAsDescribedEvidence", - "type": "object", - "x-expandableFields": ["additional_documentation"] - }, - "issuing_transaction_amount_details": { - "description": "", - "properties": { - "atm_fee": { - "description": "The fee charged by the ATM for the cash withdrawal.", + }, + "tax": { + "description": "The amount of tax on this invoice. This is the sum of all the tax amounts on this invoice.", "nullable": true, "type": "integer" - } - }, - "title": "IssuingTransactionAmountDetails", - "type": "object", - "x-expandableFields": [] - }, - "issuing_transaction_flight_data": { - "description": "", - "properties": { - "departure_at": { - "description": "The time that the flight departed.", + }, + "test_clock": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ], + "description": "ID of the test clock this invoice belongs to.", "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ] + } + }, + "threshold_reason": { + "$ref": "#/components/schemas/invoice_threshold_reason" + }, + "total": { + "description": "Total after discounts and taxes.", "type": "integer" }, - "passenger_name": { - "description": "The name of the passenger.", - "maxLength": 5000, + "total_discount_amounts": { + "description": "The aggregate amounts calculated per discount across all line items.", + "items": { + "$ref": "#/components/schemas/discounts_resource_discount_amount" + }, "nullable": true, - "type": "string" + "type": "array" }, - "refundable": { - "description": "Whether the ticket is refundable.", + "total_excluding_tax": { + "description": "The integer amount in cents (or local equivalent) representing the total amount of the invoice including all discounts but excluding all tax.", "nullable": true, - "type": "boolean" + "type": "integer" }, - "segments": { - "description": "The legs of the trip.", + "total_tax_amounts": { + "description": "The aggregate amounts calculated per tax rate for all line items.", "items": { - "$ref": "#/components/schemas/issuing_transaction_flight_data_leg" + "$ref": "#/components/schemas/invoice_tax_amount" }, - "nullable": true, "type": "array" }, - "travel_agency": { - "description": "The travel agency that issued the ticket.", - "maxLength": 5000, + "transfer_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_transfer_data" + } + ], + "description": "The account (if any) the payment will be attributed to for tax reporting, and where funds from the payment will be transferred to for the invoice.", + "nullable": true + }, + "webhooks_delivered_at": { + "description": "Invoices are automatically paid or sent 1 hour after webhooks are delivered, or until all webhook delivery attempts have [been exhausted](https://stripe.com/docs/billing/webhooks#understand). This field tracks the time when webhooks for this invoice were successfully delivered. If the invoice had no webhooks to deliver, this will be set while the invoice is being created.", + "format": "unix-time", "nullable": true, - "type": "string" + "type": "integer" } }, - "title": "IssuingTransactionFlightData", - "type": "object", - "x-expandableFields": ["segments"] - }, - "issuing_transaction_flight_data_leg": { - "description": "", - "properties": { - "arrival_airport_code": { - "description": "The three-letter IATA airport code of the flight's destination.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "carrier": { - "description": "The airline carrier code.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "departure_airport_code": { - "description": "The three-letter IATA airport code that the flight departed from.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "flight_number": { - "description": "The flight number.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "service_class": { - "description": "The flight's service class.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "stopover_allowed": { - "description": "Whether a stopover is allowed on this flight.", + "required": [ + "amount_due", + "amount_paid", + "amount_remaining", + "amount_shipping", + "attempt_count", + "attempted", + "automatic_tax", + "collection_method", + "created", + "currency", + "default_tax_rates", + "discounts", + "issuer", + "lines", + "livemode", + "object", + "paid", + "paid_out_of_band", + "payment_settings", + "period_end", + "period_start", + "post_payment_credit_notes_amount", + "pre_payment_credit_notes_amount", + "starting_balance", + "status_transitions", + "subtotal", + "total", + "total_tax_amounts" + ], + "title": "Invoice", + "type": "object", + "x-expandableFields": [ + "account_tax_ids", + "application", + "automatic_tax", + "charge", + "custom_fields", + "customer", + "customer_address", + "customer_shipping", + "customer_tax_ids", + "default_payment_method", + "default_source", + "default_tax_rates", + "discount", + "discounts", + "from_invoice", + "issuer", + "last_finalization_error", + "latest_revision", + "lines", + "on_behalf_of", + "payment_intent", + "payment_settings", + "quote", + "rendering", + "shipping_cost", + "shipping_details", + "status_transitions", + "subscription", + "subscription_details", + "test_clock", + "threshold_reason", + "total_discount_amounts", + "total_tax_amounts", + "transfer_data" + ], + "x-resourceId": "invoice" + }, + "invoice_installments_card": { + "description": "", + "properties": { + "enabled": { + "description": "Whether Installments are enabled for this Invoice.", "nullable": true, "type": "boolean" } }, - "title": "IssuingTransactionFlightDataLeg", + "title": "invoice_installments_card", "type": "object", "x-expandableFields": [] }, - "issuing_transaction_fuel_data": { + "invoice_item_threshold_reason": { "description": "", "properties": { - "type": { - "description": "The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.", - "maxLength": 5000, - "type": "string" - }, - "unit": { - "description": "The units for `volume_decimal`. One of `us_gallon` or `liter`.", - "maxLength": 5000, - "type": "string" - }, - "unit_cost_decimal": { - "description": "The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.", - "format": "decimal", - "type": "string" + "line_item_ids": { + "description": "The IDs of the line items that triggered the threshold invoice.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "volume_decimal": { - "description": "The volume of the fuel that was pumped, represented as a decimal string with at most 12 decimal places.", - "format": "decimal", - "nullable": true, - "type": "string" + "usage_gte": { + "description": "The quantity threshold boundary that applied to the given line item.", + "type": "integer" } }, - "required": ["type", "unit", "unit_cost_decimal"], - "title": "IssuingTransactionFuelData", + "required": ["line_item_ids", "usage_gte"], + "title": "InvoiceItemThresholdReason", "type": "object", "x-expandableFields": [] }, - "issuing_transaction_lodging_data": { + "invoice_line_item_period": { "description": "", "properties": { - "check_in_at": { - "description": "The time of checking into the lodging.", - "nullable": true, + "end": { + "description": "The end of the period, which must be greater than or equal to the start. This value is inclusive.", + "format": "unix-time", "type": "integer" }, - "nights": { - "description": "The number of nights stayed at the lodging.", - "nullable": true, + "start": { + "description": "The start of the period. This value is inclusive.", + "format": "unix-time", "type": "integer" } }, - "title": "IssuingTransactionLodgingData", + "required": ["end", "start"], + "title": "InvoiceLineItemPeriod", "type": "object", "x-expandableFields": [] }, - "issuing_transaction_purchase_details": { + "invoice_mandate_options_card": { "description": "", "properties": { - "flight": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_transaction_flight_data" - } - ], - "description": "Information about the flight that was purchased with this transaction.", - "nullable": true - }, - "fuel": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_transaction_fuel_data" - } - ], - "description": "Information about fuel that was purchased with this transaction.", - "nullable": true - }, - "lodging": { - "anyOf": [ - { - "$ref": "#/components/schemas/issuing_transaction_lodging_data" - } - ], - "description": "Information about lodging that was purchased with this transaction.", - "nullable": true + "amount": { + "description": "Amount to be charged for future payments.", + "nullable": true, + "type": "integer" }, - "receipt": { - "description": "The line items in the purchase.", - "items": { - "$ref": "#/components/schemas/issuing_transaction_receipt_data" - }, + "amount_type": { + "description": "One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.", + "enum": ["fixed", "maximum"], "nullable": true, - "type": "array" + "type": "string" }, - "reference": { - "description": "A merchant-specific order number.", - "maxLength": 5000, + "description": { + "description": "A description of the mandate or subscription that is meant to be displayed to the customer.", + "maxLength": 200, "nullable": true, "type": "string" } }, - "title": "IssuingTransactionPurchaseDetails", + "title": "invoice_mandate_options_card", "type": "object", - "x-expandableFields": ["flight", "fuel", "lodging", "receipt"] + "x-expandableFields": [] }, - "issuing_transaction_receipt_data": { + "invoice_payment_method_options_acss_debit": { "description": "", "properties": { - "description": { - "description": "The description of the item. The maximum length of this field is 26 characters.", - "maxLength": 5000, + "mandate_options": { + "$ref": "#/components/schemas/invoice_payment_method_options_acss_debit_mandate_options" + }, + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_acss_debit", + "type": "object", + "x-expandableFields": ["mandate_options"] + }, + "invoice_payment_method_options_acss_debit_mandate_options": { + "description": "", + "properties": { + "transaction_type": { + "description": "Transaction type of the mandate.", + "enum": ["business", "personal"], "nullable": true, "type": "string" + } + }, + "title": "invoice_payment_method_options_acss_debit_mandate_options", + "type": "object", + "x-expandableFields": [] + }, + "invoice_payment_method_options_bancontact": { + "description": "", + "properties": { + "preferred_language": { + "description": "Preferred language of the Bancontact authorization page that the customer is redirected to.", + "enum": ["de", "en", "fr", "nl"], + "type": "string" + } + }, + "required": ["preferred_language"], + "title": "invoice_payment_method_options_bancontact", + "type": "object", + "x-expandableFields": [] + }, + "invoice_payment_method_options_card": { + "description": "", + "properties": { + "installments": { + "$ref": "#/components/schemas/invoice_installments_card" }, - "quantity": { - "description": "The quantity of the item.", + "request_three_d_secure": { + "description": "We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.", + "enum": ["any", "automatic", "challenge"], "nullable": true, - "type": "number" + "type": "string" + } + }, + "title": "invoice_payment_method_options_card", + "type": "object", + "x-expandableFields": ["installments"] + }, + "invoice_payment_method_options_customer_balance": { + "description": "", + "properties": { + "bank_transfer": { + "$ref": "#/components/schemas/invoice_payment_method_options_customer_balance_bank_transfer" }, - "total": { - "description": "The total for this line item in cents.", + "funding_type": { + "description": "The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.", + "enum": ["bank_transfer"], "nullable": true, - "type": "integer" + "type": "string" + } + }, + "title": "invoice_payment_method_options_customer_balance", + "type": "object", + "x-expandableFields": ["bank_transfer"] + }, + "invoice_payment_method_options_customer_balance_bank_transfer": { + "description": "", + "properties": { + "eu_bank_transfer": { + "$ref": "#/components/schemas/invoice_payment_method_options_customer_balance_bank_transfer_eu_bank_transfer" }, - "unit_cost": { - "description": "The unit cost of the item in cents.", + "type": { + "description": "The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.", "nullable": true, - "type": "integer" + "type": "string" } }, - "title": "IssuingTransactionReceiptData", + "title": "invoice_payment_method_options_customer_balance_bank_transfer", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["eu_bank_transfer"] }, - "item": { - "description": "A line item.", + "invoice_payment_method_options_customer_balance_bank_transfer_eu_bank_transfer": { + "description": "", "properties": { - "amount_subtotal": { - "description": "Total before any discounts or taxes are applied.", - "type": "integer" - }, - "amount_total": { - "description": "Total after discounts and taxes.", - "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "country": { + "description": "The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.", + "enum": ["BE", "DE", "ES", "FR", "IE", "NL"], "type": "string" + } + }, + "required": ["country"], + "title": "invoice_payment_method_options_customer_balance_bank_transfer_eu_bank_transfer", + "type": "object", + "x-expandableFields": [] + }, + "invoice_payment_method_options_konbini": { + "description": "", + "properties": {}, + "title": "invoice_payment_method_options_konbini", + "type": "object", + "x-expandableFields": [] + }, + "invoice_payment_method_options_sepa_debit": { + "description": "", + "properties": {}, + "title": "invoice_payment_method_options_sepa_debit", + "type": "object", + "x-expandableFields": [] + }, + "invoice_payment_method_options_us_bank_account": { + "description": "", + "properties": { + "financial_connections": { + "$ref": "#/components/schemas/invoice_payment_method_options_us_bank_account_linked_account_options" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users. Defaults to product name.", - "maxLength": 5000, - "type": "string" + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_us_bank_account", + "type": "object", + "x-expandableFields": ["financial_connections"] + }, + "invoice_payment_method_options_us_bank_account_linked_account_options": { + "description": "", + "properties": { + "filters": { + "$ref": "#/components/schemas/invoice_payment_method_options_us_bank_account_linked_account_options_filters" }, - "discounts": { - "description": "The discounts applied to the line item.", + "permissions": { + "description": "The list of permissions to request. The `payment_method` permission must be included.", "items": { - "$ref": "#/components/schemas/line_items_discount_amount" + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "type": "string" }, "type": "array" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["item"], - "type": "string" - }, - "price": { - "anyOf": [ - { - "$ref": "#/components/schemas/price" - } - ], - "description": "The price used to generate the line item.", - "nullable": true - }, - "quantity": { - "description": "The quantity of products being purchased.", + "prefetch": { + "description": "Data features requested to be retrieved upon account creation.", + "items": { + "enum": ["balances", "ownership", "transactions"], + "type": "string", + "x-stripeBypassValidation": true + }, "nullable": true, - "type": "integer" - }, - "taxes": { - "description": "The taxes applied to the line item.", + "type": "array" + } + }, + "title": "invoice_payment_method_options_us_bank_account_linked_account_options", + "type": "object", + "x-expandableFields": ["filters"] + }, + "invoice_payment_method_options_us_bank_account_linked_account_options_filters": { + "description": "", + "properties": { + "account_subcategories": { + "description": "The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.", "items": { - "$ref": "#/components/schemas/line_items_tax_amount" + "enum": ["checking", "savings"], + "type": "string" }, "type": "array" } }, - "required": [ - "amount_subtotal", - "amount_total", - "currency", - "description", - "id", - "object" - ], - "title": "LineItem", + "title": "invoice_payment_method_options_us_bank_account_linked_account_options_filters", "type": "object", - "x-expandableFields": ["discounts", "price", "taxes"], - "x-resourceId": "item" + "x-expandableFields": [] }, - "legal_entity_company": { + "invoice_rendering_pdf": { "description": "", "properties": { - "address": { - "$ref": "#/components/schemas/address" - }, - "address_kana": { - "anyOf": [ - { - "$ref": "#/components/schemas/legal_entity_japan_address" - } - ], - "description": "The Kana variation of the company's primary address (Japan only).", - "nullable": true - }, - "address_kanji": { - "anyOf": [ - { - "$ref": "#/components/schemas/legal_entity_japan_address" - } - ], - "description": "The Kanji variation of the company's primary address (Japan only).", - "nullable": true - }, - "directors_provided": { - "description": "Whether the company's directors have been provided. This Boolean will be `true` if you've manually indicated that all directors are provided via [the `directors_provided` parameter](https://stripe.com/docs/api/accounts/update#update_account-company-directors_provided).", - "type": "boolean" - }, - "executives_provided": { - "description": "Whether the company's executives have been provided. This Boolean will be `true` if you've manually indicated that all executives are provided via [the `executives_provided` parameter](https://stripe.com/docs/api/accounts/update#update_account-company-executives_provided), or if Stripe determined that sufficient executives were provided.", - "type": "boolean" - }, - "name": { - "description": "The company's legal name.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "name_kana": { - "description": "The Kana variation of the company's legal name (Japan only).", - "maxLength": 5000, + "page_size": { + "description": "Page size of invoice pdf. Options include a4, letter, and auto. If set to auto, page size will be switched to a4 or letter based on customer locale.", + "enum": ["a4", "auto", "letter"], "nullable": true, "type": "string" - }, - "name_kanji": { - "description": "The Kanji variation of the company's legal name (Japan only).", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "owners_provided": { - "description": "Whether the company's owners have been provided. This Boolean will be `true` if you've manually indicated that all owners are provided via [the `owners_provided` parameter](https://stripe.com/docs/api/accounts/update#update_account-company-owners_provided), or if Stripe determined that sufficient owners were provided. Stripe determines ownership requirements using both the number of owners provided and their total percent ownership (calculated by adding the `percent_ownership` of each owner together).", - "type": "boolean" - }, - "phone": { - "description": "The company's phone number (used for verification).", + } + }, + "title": "InvoiceRenderingPdf", + "type": "object", + "x-expandableFields": [] + }, + "invoice_setting_custom_field": { + "description": "", + "properties": { + "name": { + "description": "The name of the custom field.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "structure": { - "description": "The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details.", - "enum": [ - "government_instrumentality", - "governmental_unit", - "incorporated_non_profit", - "limited_liability_partnership", - "multi_member_llc", - "private_company", - "private_corporation", - "private_partnership", - "public_company", - "public_corporation", - "public_partnership", - "sole_proprietorship", - "tax_exempt_government_instrumentality", - "unincorporated_association", - "unincorporated_non_profit" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "tax_id_provided": { - "description": "Whether the company's business ID number was provided.", - "type": "boolean" - }, - "tax_id_registrar": { - "description": "The jurisdiction in which the `tax_id` is registered (Germany-based companies only).", + "value": { + "description": "The value of the custom field.", "maxLength": 5000, "type": "string" - }, - "vat_id_provided": { - "description": "Whether the company's business VAT number was provided.", - "type": "boolean" - }, - "verification": { - "anyOf": [ - { - "$ref": "#/components/schemas/legal_entity_company_verification" - } - ], - "description": "Information on the verification state of the company.", - "nullable": true } }, - "title": "LegalEntityCompany", + "required": ["name", "value"], + "title": "InvoiceSettingCustomField", "type": "object", - "x-expandableFields": [ - "address", - "address_kana", - "address_kanji", - "verification" - ] + "x-expandableFields": [] }, - "legal_entity_company_verification": { + "invoice_setting_customer_rendering_options": { "description": "", "properties": { - "document": { - "$ref": "#/components/schemas/legal_entity_company_verification_document" + "amount_tax_display": { + "description": "How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "required": ["document"], - "title": "LegalEntityCompanyVerification", + "title": "InvoiceSettingCustomerRenderingOptions", "type": "object", - "x-expandableFields": ["document"] + "x-expandableFields": [] }, - "legal_entity_company_verification_document": { + "invoice_setting_customer_setting": { "description": "", "properties": { - "back": { + "custom_fields": { + "description": "Default custom fields to be displayed on invoices for this customer.", + "items": { + "$ref": "#/components/schemas/invoice_setting_custom_field" + }, + "nullable": true, + "type": "array" + }, + "default_payment_method": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/payment_method" } ], - "description": "The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`.", + "description": "ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/payment_method" } ] } }, - "details": { - "description": "A user-displayable string describing the verification state of this document.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "details_code": { - "description": "One of `document_corrupt`, `document_expired`, `document_failed_copy`, `document_failed_greyscale`, `document_failed_other`, `document_failed_test_mode`, `document_fraudulent`, `document_incomplete`, `document_invalid`, `document_manipulated`, `document_not_readable`, `document_not_uploaded`, `document_type_not_supported`, or `document_too_large`. A machine-readable code specifying the verification state for this document.", + "footer": { + "description": "Default footer to be displayed on invoices for this customer.", "maxLength": 5000, "nullable": true, "type": "string" }, - "front": { + "rendering_options": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/invoice_setting_customer_rendering_options" } ], - "description": "The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/file" - } - ] - } + "description": "Default options for invoice PDF rendering for this customer.", + "nullable": true } }, - "title": "LegalEntityCompanyVerificationDocument", + "title": "InvoiceSettingCustomerSetting", "type": "object", - "x-expandableFields": ["back", "front"] - }, - "legal_entity_dob": { - "description": "", + "x-expandableFields": [ + "custom_fields", + "default_payment_method", + "rendering_options" + ] + }, + "invoice_setting_quote_setting": { + "description": "", "properties": { - "day": { - "description": "The day of birth, between 1 and 31.", - "nullable": true, - "type": "integer" - }, - "month": { - "description": "The month of birth, between 1 and 12.", + "days_until_due": { + "description": "Number of days within which a customer must pay invoices generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.", "nullable": true, "type": "integer" }, - "year": { - "description": "The four-digit year of birth.", - "nullable": true, - "type": "integer" + "issuer": { + "$ref": "#/components/schemas/connect_account_reference" } }, - "title": "LegalEntityDOB", + "required": ["issuer"], + "title": "InvoiceSettingQuoteSetting", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["issuer"] }, - "legal_entity_japan_address": { + "invoice_setting_rendering_options": { "description": "", "properties": { - "city": { - "description": "City/Ward.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "country": { - "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "line1": { - "description": "Block/Building number.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "line2": { - "description": "Building details.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "postal_code": { - "description": "ZIP or postal code.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "state": { - "description": "Prefecture.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "town": { - "description": "Town/cho-me.", + "amount_tax_display": { + "description": "How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "LegalEntityJapanAddress", + "title": "InvoiceSettingRenderingOptions", "type": "object", "x-expandableFields": [] }, - "legal_entity_person_verification": { + "invoice_setting_subscription_schedule_phase_setting": { "description": "", "properties": { - "additional_document": { + "account_tax_ids": { + "description": "The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ] + } + }, + "nullable": true, + "type": "array" + }, + "days_until_due": { + "description": "Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.", + "nullable": true, + "type": "integer" + }, + "issuer": { "anyOf": [ { - "$ref": "#/components/schemas/legal_entity_person_verification_document" + "$ref": "#/components/schemas/connect_account_reference" } ], - "description": "A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.", + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", "nullable": true - }, - "details": { - "description": "A user-displayable string describing the verification state for the person. For example, this may say \"Provided identity information could not be verified\".", - "maxLength": 5000, + } + }, + "title": "InvoiceSettingSubscriptionSchedulePhaseSetting", + "type": "object", + "x-expandableFields": ["account_tax_ids", "issuer"] + }, + "invoice_setting_subscription_schedule_setting": { + "description": "", + "properties": { + "account_tax_ids": { + "description": "The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ] + } + }, "nullable": true, - "type": "string" + "type": "array" }, - "details_code": { - "description": "One of `document_address_mismatch`, `document_dob_mismatch`, `document_duplicate_type`, `document_id_number_mismatch`, `document_name_mismatch`, `document_nationality_mismatch`, `failed_keyed_identity`, or `failed_other`. A machine-readable code specifying the verification state for the person.", - "maxLength": 5000, + "days_until_due": { + "description": "Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.", "nullable": true, - "type": "string" - }, - "document": { - "$ref": "#/components/schemas/legal_entity_person_verification_document" + "type": "integer" }, - "status": { - "description": "The state of verification for the person. Possible values are `unverified`, `pending`, or `verified`.", - "maxLength": 5000, - "type": "string" + "issuer": { + "$ref": "#/components/schemas/connect_account_reference" } }, - "required": ["status"], - "title": "LegalEntityPersonVerification", + "required": ["issuer"], + "title": "InvoiceSettingSubscriptionScheduleSetting", "type": "object", - "x-expandableFields": ["additional_document", "document"] + "x-expandableFields": ["account_tax_ids", "issuer"] }, - "legal_entity_person_verification_document": { + "invoice_tax_amount": { "description": "", "properties": { - "back": { + "amount": { + "description": "The amount, in cents (or local equivalent), of the tax.", + "type": "integer" + }, + "inclusive": { + "description": "Whether this tax amount is inclusive or exclusive.", + "type": "boolean" + }, + "tax_rate": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/tax_rate" } ], - "description": "The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.", - "nullable": true, + "description": "The tax rate that was applied to get this tax amount.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/tax_rate" } ] } }, - "details": { - "description": "A user-displayable string describing the verification state of this document. For example, if a document is uploaded and the picture is too fuzzy, this may say \"Identity document is too unclear to read\".", - "maxLength": 5000, + "taxability_reason": { + "description": "The reasoning behind this tax, for example, if the product is tax exempt. The possible values for this field may be extended as new tax rules are supported.", + "enum": [ + "customer_exempt", + "not_collecting", + "not_subject_to_tax", + "not_supported", + "portion_product_exempt", + "portion_reduced_rated", + "portion_standard_rated", + "product_exempt", + "product_exempt_holiday", + "proportionally_rated", + "reduced_rated", + "reverse_charge", + "standard_rated", + "taxable_basis_reduced", + "zero_rated" + ], "nullable": true, - "type": "string" + "type": "string", + "x-stripeBypassValidation": true }, - "details_code": { - "description": "One of `document_corrupt`, `document_country_not_supported`, `document_expired`, `document_failed_copy`, `document_failed_other`, `document_failed_test_mode`, `document_fraudulent`, `document_failed_greyscale`, `document_incomplete`, `document_invalid`, `document_manipulated`, `document_missing_back`, `document_missing_front`, `document_not_readable`, `document_not_uploaded`, `document_photo_mismatch`, `document_too_large`, or `document_type_not_supported`. A machine-readable code specifying the verification state for this document.", - "maxLength": 5000, + "taxable_amount": { + "description": "The amount on which tax is calculated, in cents (or local equivalent).", "nullable": true, - "type": "string" + "type": "integer" + } + }, + "required": ["amount", "inclusive", "tax_rate"], + "title": "InvoiceTaxAmount", + "type": "object", + "x-expandableFields": ["tax_rate"] + }, + "invoice_threshold_reason": { + "description": "", + "properties": { + "amount_gte": { + "description": "The total invoice amount threshold boundary if it triggered the threshold invoice.", + "nullable": true, + "type": "integer" }, - "front": { + "item_reasons": { + "description": "Indicates which line items triggered a threshold invoice.", + "items": { + "$ref": "#/components/schemas/invoice_item_threshold_reason" + }, + "type": "array" + } + }, + "required": ["item_reasons"], + "title": "InvoiceThresholdReason", + "type": "object", + "x-expandableFields": ["item_reasons"] + }, + "invoice_transfer_data": { + "description": "", + "properties": { + "amount": { + "description": "The amount in cents (or local equivalent) that will be transferred to the destination account when the invoice is paid. By default, the entire amount is transferred to the destination.", + "nullable": true, + "type": "integer" + }, + "destination": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/account" } ], - "description": "The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.", - "nullable": true, + "description": "The account where funds from the payment will be transferred to upon payment success.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/file" + "$ref": "#/components/schemas/account" } ] } } }, - "title": "LegalEntityPersonVerificationDocument", - "type": "object", - "x-expandableFields": ["back", "front"] - }, - "light_account_logout": { - "description": "", - "properties": {}, - "title": "LightAccountLogout", + "required": ["destination"], + "title": "InvoiceTransferData", "type": "object", - "x-expandableFields": [], - "x-resourceId": "light_account_logout" + "x-expandableFields": ["destination"] }, - "line_item": { - "description": "", + "invoiceitem": { + "description": "Invoice Items represent the component lines of an [invoice](https://stripe.com/docs/api/invoices). An invoice item is added to an\ninvoice by creating or updating it with an `invoice` field, at which point it will be included as\n[an invoice line item](https://stripe.com/docs/api/invoices/line_item) within\n[invoice.lines](https://stripe.com/docs/api/invoices/object#invoice_object-lines).\n\nInvoice Items can be created before you are ready to actually send the invoice. This can be particularly useful when combined\nwith a [subscription](https://stripe.com/docs/api/subscriptions). Sometimes you want to add a charge or credit to a customer, but actually charge\nor credit the customer’s card only at the end of a regular billing cycle. This is useful for combining several charges\n(to minimize per-transaction fees), or for having Stripe tabulate your usage-based billing totals.\n\nRelated guides: [Integrate with the Invoicing API](https://stripe.com/docs/invoicing/integration), [Subscription Invoices](https://stripe.com/docs/billing/invoices/subscription#adding-upcoming-invoice-items).", "properties": { "amount": { - "description": "The amount, in %s.", + "description": "Amount (in the `currency` specified) of the invoice item. This should always be equal to `unit_amount * quantity`.", "type": "integer" }, "currency": { "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ], + "description": "The ID of the customer who will be billed when this invoice item is billed.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ] + } + }, + "date": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, "description": { "description": "An arbitrary string attached to the object. Often useful for displaying to users.", "maxLength": 5000, "nullable": true, "type": "string" }, - "discount_amounts": { - "description": "The amount of discount calculated per discount for this line item.", - "items": { - "$ref": "#/components/schemas/discounts_resource_discount_amount" - }, - "nullable": true, - "type": "array" - }, "discountable": { - "description": "If true, discounts will apply to this line item. Always false for prorations.", + "description": "If true, discounts will apply to this invoice item. Always false for prorations.", "type": "boolean" }, "discounts": { - "description": "The discounts applied to the invoice line item. Line item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.", + "description": "The discounts which apply to the invoice item. Item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.", "items": { "anyOf": [ { @@ -12131,10 +14616,25 @@ "maxLength": 5000, "type": "string" }, - "invoice_item": { - "description": "The ID of the [invoice item](https://stripe.com/docs/api/invoiceitems) associated with this line item if any.", - "maxLength": 5000, - "type": "string" + "invoice": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/invoice" + } + ], + "description": "The ID of the invoice this invoice item belongs to.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/invoice" + } + ] + } }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", @@ -12145,12 +14645,13 @@ "maxLength": 500, "type": "string" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items with `type=subscription` this will reflect the metadata of the subscription that caused the line item to be created.", + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, "type": "object" }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["line_item"], + "enum": ["invoiceitem"], "type": "string" }, "period": { @@ -12162,448 +14663,573 @@ "$ref": "#/components/schemas/price" } ], - "description": "The price of the line item.", + "description": "The price of the invoice item.", "nullable": true }, "proration": { - "description": "Whether this is a proration.", + "description": "Whether the invoice item was created automatically as a proration adjustment when the customer switched plans.", "type": "boolean" }, "quantity": { - "description": "The quantity of the subscription, if the line item is a subscription or a proration.", - "nullable": true, + "description": "Quantity of units for the invoice item. If the invoice item is a proration, the quantity of the subscription that the proration was computed for.", "type": "integer" }, "subscription": { - "description": "The subscription that the invoice item pertains to, if any.", - "maxLength": 5000, + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/subscription" + } + ], + "description": "The subscription that this invoice item has been created for, if any.", "nullable": true, - "type": "string" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/subscription" + } + ] + } }, "subscription_item": { - "description": "The subscription item that generated this invoice item. Left empty if the line item is not an explicit result of a subscription.", + "description": "The subscription item that this invoice item has been created for, if any.", "maxLength": 5000, "type": "string" }, - "tax_amounts": { - "description": "The amount of tax calculated per tax rate for this line item", - "items": { - "$ref": "#/components/schemas/invoice_tax_amount" - }, - "type": "array" - }, "tax_rates": { - "description": "The tax rates which apply to the line item.", + "description": "The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.", "items": { "$ref": "#/components/schemas/tax_rate" }, + "nullable": true, "type": "array" }, - "type": { - "description": "A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`.", - "enum": ["invoiceitem", "subscription"], + "test_clock": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ], + "description": "ID of the test clock this invoice item belongs to.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ] + } + }, + "unit_amount": { + "description": "Unit amount (in the `currency` specified) of the invoice item.", + "nullable": true, + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.", + "format": "decimal", + "nullable": true, "type": "string" } }, "required": [ "amount", "currency", + "customer", + "date", "discountable", "id", "livemode", - "metadata", "object", "period", "proration", - "type" + "quantity" ], - "title": "InvoiceLineItem", + "title": "InvoiceItem", "type": "object", "x-expandableFields": [ - "discount_amounts", + "customer", "discounts", + "invoice", "period", "price", - "tax_amounts", - "tax_rates" + "subscription", + "tax_rates", + "test_clock" ], - "x-resourceId": "line_item" + "x-resourceId": "invoiceitem" }, - "line_items_discount_amount": { + "invoices_payment_method_options": { "description": "", "properties": { - "amount": { - "description": "The amount discounted.", - "type": "integer" + "acss_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_acss_debit" + } + ], + "description": "If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.", + "nullable": true }, - "discount": { - "$ref": "#/components/schemas/discount" + "bancontact": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_bancontact" + } + ], + "description": "If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.", + "nullable": true + }, + "card": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_card" + } + ], + "description": "If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.", + "nullable": true + }, + "customer_balance": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_customer_balance" + } + ], + "description": "If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.", + "nullable": true + }, + "konbini": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_konbini" + } + ], + "description": "If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.", + "nullable": true + }, + "sepa_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_sepa_debit" + } + ], + "description": "If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.", + "nullable": true + }, + "us_bank_account": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_us_bank_account" + } + ], + "description": "If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.", + "nullable": true } }, - "required": ["amount", "discount"], - "title": "LineItemsDiscountAmount", + "title": "InvoicesPaymentMethodOptions", "type": "object", - "x-expandableFields": ["discount"] + "x-expandableFields": [ + "acss_debit", + "bancontact", + "card", + "customer_balance", + "konbini", + "sepa_debit", + "us_bank_account" + ] }, - "line_items_tax_amount": { + "invoices_payment_settings": { "description": "", "properties": { - "amount": { - "description": "Amount of tax applied for this rate.", - "type": "integer" + "default_mandate": { + "description": "ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "rate": { - "$ref": "#/components/schemas/tax_rate" + "payment_method_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoices_payment_method_options" + } + ], + "description": "Payment-method-specific configuration to provide to the invoice’s PaymentIntent.", + "nullable": true + }, + "payment_method_types": { + "description": "The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).", + "items": { + "enum": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "konbini", + "link", + "multibanco", + "p24", + "paynow", + "paypal", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "us_bank_account", + "wechat_pay" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "nullable": true, + "type": "array" } }, - "required": ["amount", "rate"], - "title": "LineItemsTaxAmount", + "title": "InvoicesPaymentSettings", "type": "object", - "x-expandableFields": ["rate"] + "x-expandableFields": ["payment_method_options"] }, - "login_link": { + "invoices_resource_from_invoice": { "description": "", "properties": { - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["login_link"], - "type": "string" - }, - "url": { - "description": "The URL for the login link.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["created", "object", "url"], - "title": "LoginLink", - "type": "object", - "x-expandableFields": [], - "x-resourceId": "login_link" - }, - "mandate": { - "description": "A Mandate is a record of the permission a customer has given you to debit their payment method.", - "properties": { - "customer_acceptance": { - "$ref": "#/components/schemas/customer_acceptance" - }, - "id": { - "description": "Unique identifier for the object.", + "action": { + "description": "The relation between this invoice and the cloned invoice", "maxLength": 5000, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "multi_use": { - "$ref": "#/components/schemas/mandate_multi_use" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["mandate"], - "type": "string" - }, - "payment_method": { + "invoice": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/invoice" } ], - "description": "ID of the payment method associated with this mandate.", + "description": "The invoice that was cloned.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/invoice" } ] } - }, - "payment_method_details": { - "$ref": "#/components/schemas/mandate_payment_method_details" - }, - "single_use": { - "$ref": "#/components/schemas/mandate_single_use" - }, - "status": { - "description": "The status of the mandate, which indicates whether it can be used to initiate a payment.", - "enum": ["active", "inactive", "pending"], - "type": "string" - }, - "type": { - "description": "The type of the mandate.", - "enum": ["multi_use", "single_use"], - "type": "string" - } - }, - "required": [ - "customer_acceptance", - "id", - "livemode", - "object", - "payment_method", - "payment_method_details", - "status", - "type" - ], - "title": "Mandate", - "type": "object", - "x-expandableFields": [ - "customer_acceptance", - "multi_use", - "payment_method", - "payment_method_details", - "single_use" - ], - "x-resourceId": "mandate" - }, - "mandate_au_becs_debit": { - "description": "", - "properties": { - "url": { - "description": "The URL of the mandate. This URL generally contains sensitive information about the customer and should be shared with them exclusively.", - "maxLength": 5000, - "type": "string" } }, - "required": ["url"], - "title": "mandate_au_becs_debit", + "required": ["action", "invoice"], + "title": "InvoicesResourceFromInvoice", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["invoice"] }, - "mandate_bacs_debit": { + "invoices_resource_invoice_rendering": { "description": "", "properties": { - "network_status": { - "description": "The status of the mandate on the Bacs network. Can be one of `pending`, `revoked`, `refused`, or `accepted`.", - "enum": ["accepted", "pending", "refused", "revoked"], - "type": "string" - }, - "reference": { - "description": "The unique reference identifying the mandate on the Bacs network.", + "amount_tax_display": { + "description": "How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "url": { - "description": "The URL that will contain the mandate that the customer has signed.", - "maxLength": 5000, - "type": "string" + "pdf": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_rendering_pdf" + } + ], + "description": "Invoice pdf rendering options", + "nullable": true } }, - "required": ["network_status", "reference", "url"], - "title": "mandate_bacs_debit", + "title": "InvoicesResourceInvoiceRendering", "type": "object", - "x-expandableFields": [] - }, - "mandate_multi_use": { - "description": "", - "properties": {}, - "title": "mandate_multi_use", - "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["pdf"] }, - "mandate_payment_method_details": { + "invoices_resource_invoice_tax_id": { "description": "", "properties": { - "au_becs_debit": { - "$ref": "#/components/schemas/mandate_au_becs_debit" - }, - "bacs_debit": { - "$ref": "#/components/schemas/mandate_bacs_debit" - }, - "card": { - "$ref": "#/components/schemas/card_mandate_payment_method_details" - }, - "sepa_debit": { - "$ref": "#/components/schemas/mandate_sepa_debit" - }, "type": { - "description": "The type of the payment method associated with this mandate. An additional hash is included on `payment_method_details` with a name matching this value. It contains mandate information specific to the payment method.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["type"], - "title": "mandate_payment_method_details", - "type": "object", - "x-expandableFields": [ - "au_becs_debit", - "bacs_debit", - "card", - "sepa_debit" - ] - }, - "mandate_sepa_debit": { - "description": "", - "properties": { - "reference": { - "description": "The unique reference of the mandate.", - "maxLength": 5000, + "description": "The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, or `unknown`", + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "unknown", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], "type": "string" }, - "url": { - "description": "The URL of the mandate. This URL generally contains sensitive information about the customer and should be shared with them exclusively.", + "value": { + "description": "The value of the tax ID.", "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["reference", "url"], - "title": "mandate_sepa_debit", + "required": ["type"], + "title": "InvoicesResourceInvoiceTaxID", "type": "object", "x-expandableFields": [] }, - "mandate_single_use": { + "invoices_resource_line_items_credited_items": { "description": "", "properties": { - "amount": { - "description": "On a single use mandate, the amount of the payment.", - "type": "integer" - }, - "currency": { - "description": "On a single use mandate, the currency of the payment.", + "invoice": { + "description": "Invoice containing the credited invoice line items", + "maxLength": 5000, "type": "string" - } - }, - "required": ["amount", "currency"], - "title": "mandate_single_use", - "type": "object", - "x-expandableFields": [] - }, - "networks": { - "description": "", - "properties": { - "available": { - "description": "All available networks for the card.", + }, + "invoice_line_items": { + "description": "Credited invoice line items", "items": { "maxLength": 5000, "type": "string" }, "type": "array" - }, - "preferred": { - "description": "The preferred network for the card.", - "maxLength": 5000, - "nullable": true, - "type": "string" } }, - "required": ["available"], - "title": "networks", + "required": ["invoice", "invoice_line_items"], + "title": "InvoicesResourceLineItemsCreditedItems", "type": "object", "x-expandableFields": [] }, - "notification_event_data": { + "invoices_resource_line_items_proration_details": { "description": "", "properties": { - "object": { - "description": "Object containing the API resource relevant to the event. For example, an `invoice.created` event will have a full [invoice object](https://stripe.com/docs/api#invoice_object) as the value of the object key.", - "type": "object" - }, - "previous_attributes": { - "description": "Object containing the names of the attributes that have changed, and their previous values (sent along only with *.updated events).", - "type": "object" + "credited_items": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoices_resource_line_items_credited_items" + } + ], + "description": "For a credit proration `line_item`, the original debit line_items to which the credit proration applies.", + "nullable": true } }, - "required": ["object"], - "title": "NotificationEventData", + "title": "InvoicesResourceLineItemsProrationDetails", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["credited_items"] }, - "notification_event_request": { + "invoices_resource_shipping_cost": { "description": "", "properties": { - "id": { - "description": "ID of the API request that caused the event. If null, the event was automatic (e.g., Stripe's automatic subscription handling). Request logs are available in the [dashboard](https://dashboard.stripe.com/logs), but currently not in the API.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "amount_subtotal": { + "description": "Total shipping cost before any taxes are applied.", + "type": "integer" }, - "idempotency_key": { - "description": "The idempotency key transmitted during the request, if any. *Note: This property is populated only for events on or after May 23, 2017*.", - "maxLength": 5000, + "amount_tax": { + "description": "Total tax amount applied due to shipping costs. If no tax was applied, defaults to 0.", + "type": "integer" + }, + "amount_total": { + "description": "Total shipping cost after taxes are applied.", + "type": "integer" + }, + "shipping_rate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/shipping_rate" + } + ], + "description": "The ID of the ShippingRate for this invoice.", "nullable": true, - "type": "string" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/shipping_rate" + } + ] + } + }, + "taxes": { + "description": "The taxes applied to the shipping rate.", + "items": { + "$ref": "#/components/schemas/line_items_tax_amount" + }, + "type": "array" } }, - "title": "NotificationEventRequest", + "required": ["amount_subtotal", "amount_tax", "amount_total"], + "title": "InvoicesResourceShippingCost", "type": "object", - "x-expandableFields": [] - }, - "offline_acceptance": { - "description": "", - "properties": {}, - "title": "offline_acceptance", - "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["shipping_rate", "taxes"] }, - "online_acceptance": { + "invoices_resource_status_transitions": { "description": "", "properties": { - "ip_address": { - "description": "The IP address from which the Mandate was accepted by the customer.", - "maxLength": 5000, + "finalized_at": { + "description": "The time that the invoice draft was finalized.", + "format": "unix-time", "nullable": true, - "type": "string" + "type": "integer" }, - "user_agent": { - "description": "The user agent of the browser from which the Mandate was accepted by the customer.", - "maxLength": 5000, + "marked_uncollectible_at": { + "description": "The time that the invoice was marked uncollectible.", + "format": "unix-time", "nullable": true, - "type": "string" + "type": "integer" + }, + "paid_at": { + "description": "The time that the invoice was paid.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "voided_at": { + "description": "The time that the invoice was voided.", + "format": "unix-time", + "nullable": true, + "type": "integer" } }, - "title": "online_acceptance", + "title": "InvoicesResourceStatusTransitions", "type": "object", "x-expandableFields": [] }, - "order": { - "description": "Order objects are created to handle end customers' purchases of previously\ndefined [products](https://stripe.com/docs/api#products). You can create, retrieve, and pay individual orders, as well\nas list all orders. Orders are identified by a unique, random ID.\n\nRelated guide: [Tax, Shipping, and Inventory](https://stripe.com/docs/orders).", + "issuing.authorization": { + "description": "When an [issued card](https://stripe.com/docs/issuing) is used to make a purchase, an Issuing `Authorization`\nobject is created. [Authorizations](https://stripe.com/docs/issuing/purchases/authorizations) must be approved for the\npurchase to be completed successfully.\n\nRelated guide: [Issued card authorizations](https://stripe.com/docs/issuing/purchases/authorizations)", "properties": { "amount": { - "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount for the order.", + "description": "The total amount that was authorized or rejected. This amount is in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). `amount` should be the same as `merchant_amount`, unless `currency` and `merchant_currency` are different.", "type": "integer" }, - "amount_returned": { - "description": "The total amount that was returned to the customer.", - "nullable": true, - "type": "integer" + "amount_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_authorization_amount_details" + } + ], + "description": "Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "nullable": true }, - "application": { - "description": "ID of the Connect Application that created the order.", - "maxLength": 5000, - "nullable": true, + "approved": { + "description": "Whether the authorization has been approved.", + "type": "boolean" + }, + "authorization_method": { + "description": "How the card details were provided.", + "enum": ["chip", "contactless", "keyed_in", "online", "swipe"], "type": "string" }, - "application_fee": { - "description": "A fee in cents that will be applied to the order and transferred to the application owner’s Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees documentation.", - "nullable": true, - "type": "integer" + "balance_transactions": { + "description": "List of balance transactions associated with this authorization.", + "items": { + "$ref": "#/components/schemas/balance_transaction" + }, + "type": "array" }, - "charge": { + "card": { + "$ref": "#/components/schemas/issuing.card" + }, + "cardholder": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/issuing.cardholder" } ], - "description": "The ID of the payment used to pay for the order. Present if the order status is `paid`, `fulfilled`, or `refunded`.", + "description": "The cardholder to whom this authorization belongs.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/issuing.cardholder" } ] } @@ -12614,250 +15240,220 @@ "type": "integer" }, "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "description": "The currency of the cardholder. This currency can be different from the currency presented at authorization and the `merchant_currency` field on this authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, - "customer": { + "fleet": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/issuing_authorization_fleet_data" } ], - "description": "The customer used for the order.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ] - } - }, - "email": { - "description": "The email address of the customer placing the order.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "description": "Fleet-specific information for authorizations using Fleet cards.", + "nullable": true }, - "external_coupon_code": { - "description": "External coupon code to load for this order.", - "maxLength": 5000, - "type": "string" + "fuel": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_authorization_fuel_data" + } + ], + "description": "Information about fuel that was purchased with this transaction. Typically this information is received from the merchant after the authorization has been approved and the fuel dispensed.", + "nullable": true }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "items": { - "description": "List of items constituting the order. An order can have up to 25 items.", - "items": { - "$ref": "#/components/schemas/order_item" - }, - "type": "array" - }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, + "merchant_amount": { + "description": "The total amount that was authorized or rejected. This amount is in the `merchant_currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). `merchant_amount` should be the same as `amount`, unless `merchant_currency` and `currency` are different.", + "type": "integer" + }, + "merchant_currency": { + "description": "The local currency that was presented to the cardholder for the authorization. This currency can be different from the cardholder currency and the `currency` field on this authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "merchant_data": { + "$ref": "#/components/schemas/issuing_authorization_merchant_data" + }, "metadata": { "additionalProperties": { "maxLength": 500, "type": "string" }, "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, "type": "object" }, + "network_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_authorization_network_data" + } + ], + "description": "Details about the authorization, such as identifiers, set by the card network.", + "nullable": true + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["order"], + "enum": ["issuing.authorization"], "type": "string" }, - "returns": { - "description": "A list of returns that have taken place for this order.", - "nullable": true, - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/order_return" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" + "pending_request": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_authorization_pending_request" } + ], + "description": "The pending authorization request. This field will only be non-null during an `issuing_authorization.request` webhook.", + "nullable": true + }, + "request_history": { + "description": "History of every time a `pending_request` authorization was approved/declined, either by you directly or by Stripe (e.g. based on your spending_controls). If the merchant changes the authorization by performing an incremental authorization, you can look at this field to see the previous requests for the authorization. This field can be helpful in determining why a given authorization was approved/declined.", + "items": { + "$ref": "#/components/schemas/issuing_authorization_request" }, - "required": ["data", "has_more", "object", "url"], - "title": "OrdersResourceOrderReturnList", - "type": "object", - "x-expandableFields": ["data"] + "type": "array" }, - "selected_shipping_method": { - "description": "The shipping method that is currently selected for this order, if any. If present, it is equal to one of the `id`s of shipping methods in the `shipping_methods` array. At order creation time, if there are multiple shipping methods, Stripe will automatically selected the first method.", - "maxLength": 5000, - "nullable": true, + "status": { + "description": "The current status of the authorization in its lifecycle.", + "enum": ["closed", "pending", "reversed"], "type": "string" }, - "shipping": { + "token": { "anyOf": [ { - "$ref": "#/components/schemas/shipping" + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/issuing.token" } ], - "description": "The shipping address for the order. Present if the order is for goods to be shipped.", - "nullable": true + "description": "[Token](https://stripe.com/docs/api/issuing/tokens/object) object used for this authorization. If a network token was not used for this authorization, this field will be null.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/issuing.token" + } + ] + } }, - "shipping_methods": { - "description": "A list of supported shipping methods for this order. The desired shipping method can be specified either by updating the order, or when paying it.", + "transactions": { + "description": "List of [transactions](https://stripe.com/docs/api/issuing/transactions) associated with this authorization.", "items": { - "$ref": "#/components/schemas/shipping_method" + "$ref": "#/components/schemas/issuing.transaction" }, - "nullable": true, "type": "array" }, - "status": { - "description": "Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More details in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses).", - "maxLength": 5000, - "type": "string" - }, - "status_transitions": { + "treasury": { "anyOf": [ { - "$ref": "#/components/schemas/status_transitions" + "$ref": "#/components/schemas/issuing_authorization_treasury" } ], - "description": "The timestamps at which the order status was updated.", + "description": "[Treasury](https://stripe.com/docs/api/treasury) details related to this authorization if it was created on a [FinancialAccount](https://stripe.com/docs/api/treasury/financial_accounts).", "nullable": true }, - "updated": { - "description": "Time at which the object was last updated. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "verification_data": { + "$ref": "#/components/schemas/issuing_authorization_verification_data" }, - "upstream_id": { - "description": "The user's order ID if it is different from the Stripe order ID.", + "wallet": { + "description": "The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`. Will populate as `null` when no digital wallet was utilized.", "maxLength": 5000, + "nullable": true, "type": "string" } }, "required": [ "amount", + "approved", + "authorization_method", + "balance_transactions", + "card", "created", "currency", "id", - "items", "livemode", + "merchant_amount", + "merchant_currency", + "merchant_data", + "metadata", "object", - "status" + "request_history", + "status", + "transactions", + "verification_data" ], - "title": "Order", + "title": "IssuingAuthorization", "type": "object", "x-expandableFields": [ - "charge", - "customer", - "items", - "returns", - "shipping", - "shipping_methods", - "status_transitions" - ], - "x-resourceId": "order" + "amount_details", + "balance_transactions", + "card", + "cardholder", + "fleet", + "fuel", + "merchant_data", + "network_data", + "pending_request", + "request_history", + "token", + "transactions", + "treasury", + "verification_data" + ], + "x-resourceId": "issuing.authorization" }, - "order_item": { - "description": "A representation of the constituent items of any given order. Can be used to\nrepresent [SKUs](https://stripe.com/docs/api#skus), shipping costs, or taxes owed on the order.\n\nRelated guide: [Orders](https://stripe.com/docs/orders/guide).", + "issuing.card": { + "description": "You can [create physical or virtual cards](https://stripe.com/docs/issuing/cards) that are issued to cardholders.", "properties": { - "amount": { - "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount for the line item.", - "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "description": { - "description": "Description of the line item, meant to be displayable to the user (e.g., `\"Express shipping\"`).", + "brand": { + "description": "The brand of the card.", "maxLength": 5000, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["order_item"], - "type": "string" - }, - "parent": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/sku" - } - ], - "description": "The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU).", + "cancellation_reason": { + "description": "The reason why the card was canceled.", + "enum": ["design_rejected", "lost", "stolen"], "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/sku" - } - ] - } + "type": "string", + "x-stripeBypassValidation": true }, - "quantity": { - "description": "A positive integer representing the number of instances of `parent` that are included in this order item. Applicable/present only if `type` is `sku`.", - "nullable": true, + "cardholder": { + "$ref": "#/components/schemas/issuing.cardholder" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", "type": "integer" }, - "type": { - "description": "The type of line item. One of `sku`, `tax`, `shipping`, or `discount`.", + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Supported currencies are `usd` in the US, `eur` in the EU, and `gbp` in the UK.", + "type": "string" + }, + "cvc": { + "description": "The card's CVC. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the [\"Retrieve a card\" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via \"List all cards\" or any other endpoint.", "maxLength": 5000, "type": "string" - } - }, - "required": ["amount", "currency", "description", "object", "type"], - "title": "OrderItem", - "type": "object", - "x-expandableFields": ["parent"] - }, - "order_return": { - "description": "A return represents the full or partial return of a number of [order items](https://stripe.com/docs/api#order_items).\nReturns always belong to an order, and may optionally contain a refund.\n\nRelated guide: [Handling Returns](https://stripe.com/docs/orders/guide#handling-returns).", - "properties": { - "amount": { - "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount for the returned line item.", + }, + "exp_month": { + "description": "The expiration month of the card.", "type": "integer" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", + "exp_year": { + "description": "The expiration year of the card.", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "financial_account": { + "description": "The financial account this card is attached to.", + "maxLength": 5000, + "nullable": true, "type": "string" }, "id": { @@ -12865,271 +15461,184 @@ "maxLength": 5000, "type": "string" }, - "items": { - "description": "The items included in this order return.", - "items": { - "$ref": "#/components/schemas/order_item" - }, - "type": "array" + "last4": { + "description": "The last 4 digits of the card number.", + "maxLength": 5000, + "type": "string" }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "number": { + "description": "The full unredacted card number. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the [\"Retrieve a card\" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via \"List all cards\" or any other endpoint.", + "maxLength": 5000, + "type": "string" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["order_return"], + "enum": ["issuing.card"], "type": "string" }, - "order": { + "personalization_design": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/order" + "$ref": "#/components/schemas/issuing.personalization_design" } ], - "description": "The order that this return includes items from.", + "description": "The personalization design object belonging to this card.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/order" + "$ref": "#/components/schemas/issuing.personalization_design" } ] } }, - "refund": { + "replaced_by": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/refund" + "$ref": "#/components/schemas/issuing.card" } ], - "description": "The ID of the refund issued for this return.", + "description": "The latest card that replaces this card, if any.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/refund" + "$ref": "#/components/schemas/issuing.card" } ] } - } - }, - "required": [ - "amount", - "created", - "currency", - "id", - "items", - "livemode", - "object" - ], - "title": "OrderReturn", - "type": "object", - "x-expandableFields": ["items", "order", "refund"], - "x-resourceId": "order_return" - }, - "package_dimensions": { - "description": "", - "properties": { - "height": { - "description": "Height, in inches.", - "type": "number" - }, - "length": { - "description": "Length, in inches.", - "type": "number" - }, - "weight": { - "description": "Weight, in ounces.", - "type": "number" - }, - "width": { - "description": "Width, in inches.", - "type": "number" - } - }, - "required": ["height", "length", "weight", "width"], - "title": "PackageDimensions", - "type": "object", - "x-expandableFields": [] - }, - "payment_flows_private_payment_methods_alipay": { - "description": "", - "properties": {}, - "title": "PaymentFlowsPrivatePaymentMethodsAlipay", - "type": "object", - "x-expandableFields": [] - }, - "payment_flows_private_payment_methods_alipay_details": { - "description": "", - "properties": { - "fingerprint": { - "description": "Uniquely identifies this particular Alipay account. You can use this attribute to check whether two Alipay accounts are the same.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "transaction_id": { - "description": "Transaction ID of this particular Alipay transaction.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "PaymentFlowsPrivatePaymentMethodsAlipayDetails", - "type": "object", - "x-expandableFields": [] - }, - "payment_intent": { - "description": "A PaymentIntent guides you through the process of collecting a payment from your customer.\nWe recommend that you create exactly one PaymentIntent for each order or\ncustomer session in your system. You can reference the PaymentIntent later to\nsee the history of payment attempts for a particular session.\n\nA PaymentIntent transitions through\n[multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses)\nthroughout its lifetime as it interfaces with Stripe.js to perform\nauthentication flows and ultimately creates at most one successful charge.\n\nRelated guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents).", - "properties": { - "amount": { - "description": "Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", - "type": "integer" - }, - "amount_capturable": { - "description": "Amount that can be captured from this PaymentIntent.", - "type": "integer" - }, - "amount_received": { - "description": "Amount that was collected by this PaymentIntent.", - "type": "integer" }, - "application": { + "replacement_for": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/application" + "$ref": "#/components/schemas/issuing.card" } ], - "description": "ID of the Connect application that created the PaymentIntent.", + "description": "The card this card replaces, if any.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/application" + "$ref": "#/components/schemas/issuing.card" } ] } }, - "application_fee_amount": { - "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", - "nullable": true, - "type": "integer" - }, - "canceled_at": { - "description": "Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "cancellation_reason": { - "description": "Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`).", - "enum": [ - "abandoned", - "automatic", - "duplicate", - "failed_invoice", - "fraudulent", - "requested_by_customer", - "void_invoice" - ], + "replacement_reason": { + "description": "The reason why the previous card needed to be replaced.", + "enum": ["damaged", "expired", "lost", "stolen"], "nullable": true, - "type": "string" - }, - "capture_method": { - "description": "Controls when the funds will be captured from the customer's account.", - "enum": ["automatic", "manual"], - "type": "string" + "type": "string", + "x-stripeBypassValidation": true }, - "charges": { - "description": "Charges that were created by this PaymentIntent, if any.", - "properties": { - "data": { - "description": "This list only contains the latest charge, even if there were previously multiple unsuccessful charges. To view all previous charges for a PaymentIntent, you can filter the charges list using the `payment_intent` [parameter](https://stripe.com/docs/api/charges/list#list_charges-payment_intent).", - "items": { - "$ref": "#/components/schemas/charge" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" + "shipping": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_card_shipping" } - }, - "required": ["data", "has_more", "object", "url"], - "title": "PaymentFlowsPaymentIntentResourceChargeList", - "type": "object", - "x-expandableFields": ["data"] - }, - "client_secret": { - "description": "The client secret of this PaymentIntent. Used for client-side retrieval using a publishable key. \n\nThe client secret can be used to complete a payment from your frontend. It should not be stored, logged, embedded in URLs, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.\n\nRefer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment?integration=elements) and learn about how `client_secret` should be handled.", - "maxLength": 5000, - "nullable": true, - "type": "string" + ], + "description": "Where and how the card will be shipped.", + "nullable": true }, - "confirmation_method": { - "enum": ["automatic", "manual"], - "type": "string" + "spending_controls": { + "$ref": "#/components/schemas/issuing_card_authorization_controls" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "status": { + "description": "Whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`.", + "enum": ["active", "canceled", "inactive"], + "type": "string", + "x-stripeBypassValidation": true }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": { + "description": "The type of the card.", + "enum": ["physical", "virtual"], "type": "string" }, - "customer": { + "wallets": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/customer" - }, + "$ref": "#/components/schemas/issuing_card_wallets" + } + ], + "description": "Information relating to digital wallets (like Apple Pay and Google Pay).", + "nullable": true + } + }, + "required": [ + "brand", + "cardholder", + "created", + "currency", + "exp_month", + "exp_year", + "id", + "last4", + "livemode", + "metadata", + "object", + "spending_controls", + "status", + "type" + ], + "title": "IssuingCard", + "type": "object", + "x-expandableFields": [ + "cardholder", + "personalization_design", + "replaced_by", + "replacement_for", + "shipping", + "spending_controls", + "wallets" + ], + "x-resourceId": "issuing.card" + }, + "issuing.cardholder": { + "description": "An Issuing `Cardholder` object represents an individual or business entity who is [issued](https://stripe.com/docs/issuing) cards.\n\nRelated guide: [How to create a cardholder](https://stripe.com/docs/issuing/cards#create-cardholder)", + "properties": { + "billing": { + "$ref": "#/components/schemas/issuing_cardholder_address" + }, + "company": { + "anyOf": [ { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/issuing_cardholder_company" } ], - "description": "ID of the Customer this PaymentIntent belongs to, if one exists.\n\nPayment methods attached to other Customers cannot be used with this PaymentIntent.\n\nIf present in combination with [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage), this PaymentIntent's payment method will be attached to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ] - } + "description": "Additional information about a `company` cardholder.", + "nullable": true }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "email": { + "description": "The cardholder's email address.", "maxLength": 5000, "nullable": true, "type": "string" @@ -13139,33 +15648,13 @@ "maxLength": 5000, "type": "string" }, - "invoice": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/invoice" - } - ], - "description": "ID of the invoice that created this PaymentIntent, if it exists.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/invoice" - } - ] - } - }, - "last_payment_error": { + "individual": { "anyOf": [ { - "$ref": "#/components/schemas/api_errors" + "$ref": "#/components/schemas/issuing_cardholder_individual" } ], - "description": "The payment error encountered in the previous PaymentIntent confirmation. It will be cleared if the PaymentIntent is later updated for any reason.", + "description": "Additional information about an `individual` cardholder.", "nullable": true }, "livemode": { @@ -13177,6050 +15666,6538 @@ "maxLength": 500, "type": "string" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. For more information, see the [documentation](https://stripe.com/docs/payments/payment-intents/creating-payment-intents#storing-information-in-metadata).", + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", "type": "object" }, - "next_action": { + "name": { + "description": "The cardholder's name. This will be printed on cards issued to them.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["issuing.cardholder"], + "type": "string" + }, + "phone_number": { + "description": "The cardholder's phone number. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure#when-is-3d-secure-applied) for more details.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "preferred_locales": { + "description": "The cardholder’s preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.\n This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.", + "items": { + "enum": ["de", "en", "es", "fr", "it"], + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "requirements": { + "$ref": "#/components/schemas/issuing_cardholder_requirements" + }, + "spending_controls": { "anyOf": [ { - "$ref": "#/components/schemas/payment_intent_next_action" + "$ref": "#/components/schemas/issuing_cardholder_authorization_controls" } ], - "description": "If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source.", + "description": "Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", "nullable": true }, + "status": { + "description": "Specifies whether to permit authorizations on this cardholder's cards.", + "enum": ["active", "blocked", "inactive"], + "type": "string" + }, + "type": { + "description": "One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details.", + "enum": ["company", "individual"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "billing", + "created", + "id", + "livemode", + "metadata", + "name", + "object", + "requirements", + "status", + "type" + ], + "title": "IssuingCardholder", + "type": "object", + "x-expandableFields": [ + "billing", + "company", + "individual", + "requirements", + "spending_controls" + ], + "x-resourceId": "issuing.cardholder" + }, + "issuing.dispute": { + "description": "As a [card issuer](https://stripe.com/docs/issuing), you can dispute transactions that the cardholder does not recognize, suspects to be fraudulent, or has other issues with.\n\nRelated guide: [Issuing disputes](https://stripe.com/docs/issuing/purchases/disputes)", + "properties": { + "amount": { + "description": "Disputed amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). Usually the amount of the `transaction`, but can differ (usually because of currency fluctuation).", + "type": "integer" + }, + "balance_transactions": { + "description": "List of balance transactions associated with the dispute.", + "items": { + "$ref": "#/components/schemas/balance_transaction" + }, + "nullable": true, + "type": "array" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "The currency the `transaction` was made in.", + "type": "string" + }, + "evidence": { + "$ref": "#/components/schemas/issuing_dispute_evidence" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "loss_reason": { + "description": "The enum that describes the dispute loss outcome. If the dispute is not lost, this field will be absent. New enum values may be added in the future, so be sure to handle unknown values.", + "enum": [ + "cardholder_authentication_issuer_liability", + "eci5_token_transaction_with_tavv", + "excess_disputes_in_timeframe", + "has_not_met_the_minimum_dispute_amount_requirements", + "invalid_duplicate_dispute", + "invalid_incorrect_amount_dispute", + "invalid_no_authorization", + "invalid_use_of_disputes", + "merchandise_delivered_or_shipped", + "merchandise_or_service_as_described", + "not_cancelled", + "other", + "refund_issued", + "submitted_beyond_allowable_time_limit", + "transaction_3ds_required", + "transaction_approved_after_prior_fraud_dispute", + "transaction_authorized", + "transaction_electronically_read", + "transaction_qualifies_for_visa_easy_payment_service", + "transaction_unattended" + ], + "type": "string" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["payment_intent"], + "enum": ["issuing.dispute"], "type": "string" }, - "on_behalf_of": { + "status": { + "description": "Current status of the dispute.", + "enum": ["expired", "lost", "submitted", "unsubmitted", "won"], + "type": "string" + }, + "transaction": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/issuing.transaction" } ], - "description": "The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details.", - "nullable": true, + "description": "The transaction being disputed.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/issuing.transaction" } ] } }, - "payment_method": { + "treasury": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/issuing_dispute_treasury" } ], - "description": "ID of the payment method used in this PaymentIntent.", + "description": "[Treasury](https://stripe.com/docs/api/treasury) details related to this dispute if it was created on a [FinancialAccount](/docs/api/treasury/financial_accounts", + "nullable": true + } + }, + "required": [ + "amount", + "created", + "currency", + "evidence", + "id", + "livemode", + "metadata", + "object", + "status", + "transaction" + ], + "title": "IssuingDispute", + "type": "object", + "x-expandableFields": [ + "balance_transactions", + "evidence", + "transaction", + "treasury" + ], + "x-resourceId": "issuing.dispute" + }, + "issuing.personalization_design": { + "description": "A Personalization Design is a logical grouping of a Physical Bundle, card logo, and carrier text that represents a product line.", + "properties": { + "card_logo": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "The file for the card logo to use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/file" } ] } }, - "payment_method_options": { + "carrier_text": { "anyOf": [ { - "$ref": "#/components/schemas/payment_intent_payment_method_options" + "$ref": "#/components/schemas/issuing_personalization_design_carrier_text" } ], - "description": "Payment-method-specific configuration for this PaymentIntent.", + "description": "Hash containing carrier text, for use with physical bundles that support carrier text.", "nullable": true }, - "payment_method_types": { - "description": "The list of payment method types (e.g. card) that this PaymentIntent is allowed to use.", - "items": { - "maxLength": 5000, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "lookup_key": { + "description": "A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, "type": "string" }, - "type": "array" + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" }, - "receipt_email": { - "description": "Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).", + "name": { + "description": "Friendly display name.", "maxLength": 5000, "nullable": true, "type": "string" }, - "review": { + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["issuing.personalization_design"], + "type": "string" + }, + "physical_bundle": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/review" + "$ref": "#/components/schemas/issuing.physical_bundle" } ], - "description": "ID of the review associated with this PaymentIntent, if any.", - "nullable": true, + "description": "The physical bundle object belonging to this personalization design.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/review" + "$ref": "#/components/schemas/issuing.physical_bundle" } ] } }, - "setup_future_usage": { - "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", - "enum": ["off_session", "on_session"], - "nullable": true, - "type": "string" - }, - "shipping": { - "anyOf": [ - { - "$ref": "#/components/schemas/shipping" - } - ], - "description": "Shipping information for this PaymentIntent.", - "nullable": true - }, - "statement_descriptor": { - "description": "For non-card charges, you can use this value as the complete description that appears on your customers’ statements. Must contain at least one letter, maximum 22 characters.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "preferences": { + "$ref": "#/components/schemas/issuing_personalization_design_preferences" }, - "statement_descriptor_suffix": { - "description": "Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "rejection_reasons": { + "$ref": "#/components/schemas/issuing_personalization_design_rejection_reasons" }, "status": { - "description": "Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses).", - "enum": [ - "canceled", - "processing", - "requires_action", - "requires_capture", - "requires_confirmation", - "requires_payment_method", - "succeeded" - ], - "type": "string" - }, - "transfer_data": { - "anyOf": [ - { - "$ref": "#/components/schemas/transfer_data" - } - ], - "description": "The data with which to automatically create a Transfer when the payment is finalized. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details.", - "nullable": true - }, - "transfer_group": { - "description": "A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details.", - "maxLength": 5000, - "nullable": true, + "description": "Whether this personalization design can be used to create cards.", + "enum": ["active", "inactive", "rejected", "review"], "type": "string" } }, "required": [ - "amount", - "capture_method", - "confirmation_method", "created", - "currency", "id", "livemode", + "metadata", "object", - "payment_method_types", + "physical_bundle", + "preferences", + "rejection_reasons", "status" ], - "title": "PaymentIntent", + "title": "IssuingPersonalizationDesign", "type": "object", "x-expandableFields": [ - "application", - "charges", - "customer", - "invoice", - "last_payment_error", - "next_action", - "on_behalf_of", - "payment_method", - "payment_method_options", - "review", - "shipping", - "transfer_data" + "card_logo", + "carrier_text", + "physical_bundle", + "preferences", + "rejection_reasons" ], - "x-resourceId": "payment_intent" + "x-resourceId": "issuing.personalization_design" }, - "payment_intent_next_action": { - "description": "", + "issuing.physical_bundle": { + "description": "A Physical Bundle represents the bundle of physical items - card stock, carrier letter, and envelope - that is shipped to a cardholder when you create a physical card.", "properties": { - "alipay_handle_redirect": { - "$ref": "#/components/schemas/payment_intent_next_action_alipay_handle_redirect" - }, - "oxxo_display_details": { - "$ref": "#/components/schemas/payment_intent_next_action_display_oxxo_details" - }, - "redirect_to_url": { - "$ref": "#/components/schemas/payment_intent_next_action_redirect_to_url" + "features": { + "$ref": "#/components/schemas/issuing_physical_bundle_features" }, - "type": { - "description": "Type of the next action to perform, one of `redirect_to_url`, `use_stripe_sdk`, `alipay_handle_redirect`, or `oxxo_display_details`.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "use_stripe_sdk": { - "description": "When confirming a PaymentIntent with Stripe.js, Stripe.js depends on the contents of this dictionary to invoke authentication flows. The shape of the contents is subject to change and is only intended to be used by Stripe.js.", - "type": "object" - } - }, - "required": ["type"], - "title": "PaymentIntentNextAction", - "type": "object", - "x-expandableFields": [ - "alipay_handle_redirect", - "oxxo_display_details", - "redirect_to_url" - ] - }, - "payment_intent_next_action_alipay_handle_redirect": { - "description": "", - "properties": { - "native_data": { - "description": "The native data to be used with Alipay SDK you must redirect your customer to in order to authenticate the payment in an Android App.", + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "name": { + "description": "Friendly display name.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "native_url": { - "description": "The native URL you must redirect your customer to in order to authenticate the payment in an iOS App.", - "maxLength": 5000, - "nullable": true, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["issuing.physical_bundle"], "type": "string" }, - "return_url": { - "description": "If the customer does not exit their browser while authenticating, they will be redirected to this specified URL after completion.", - "maxLength": 5000, - "nullable": true, + "status": { + "description": "Whether this physical bundle can be used to create cards.", + "enum": ["active", "inactive", "review"], "type": "string" }, - "url": { - "description": "The URL you must redirect your customer to in order to authenticate the payment.", - "maxLength": 5000, - "nullable": true, + "type": { + "description": "Whether this physical bundle is a standard Stripe offering or custom-made for you.", + "enum": ["custom", "standard"], "type": "string" } }, - "title": "PaymentIntentNextActionAlipayHandleRedirect", + "required": [ + "features", + "id", + "livemode", + "name", + "object", + "status", + "type" + ], + "title": "IssuingPhysicalBundle", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["features"], + "x-resourceId": "issuing.physical_bundle" }, - "payment_intent_next_action_display_oxxo_details": { - "description": "", + "issuing.settlement": { + "description": "When a non-stripe BIN is used, any use of an [issued card](https://stripe.com/docs/issuing) must be settled directly with the card network. The net amount owed is represented by an Issuing `Settlement` object.", "properties": { - "expires_after": { - "description": "The timestamp after which the OXXO voucher expires.", + "bin": { + "description": "The Bank Identification Number reflecting this settlement record.", + "maxLength": 5000, + "type": "string" + }, + "clearing_date": { + "description": "The date that the transactions are cleared and posted to user's accounts.", + "type": "integer" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", - "nullable": true, "type": "integer" }, - "hosted_voucher_url": { - "description": "The URL for the hosted OXXO voucher page, which allows customers to view and print an OXXO voucher.", - "maxLength": 5000, - "nullable": true, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, - "number": { - "description": "OXXO reference number.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "PaymentIntentNextActionDisplayOxxoDetails", - "type": "object", - "x-expandableFields": [] - }, - "payment_intent_next_action_redirect_to_url": { - "description": "", - "properties": { - "return_url": { - "description": "If the customer does not exit their browser while authenticating, they will be redirected to this specified URL after completion.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "url": { - "description": "The URL you must redirect your customer to in order to authenticate the payment.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "PaymentIntentNextActionRedirectToUrl", - "type": "object", - "x-expandableFields": [] - }, - "payment_intent_payment_method_options": { - "description": "", - "properties": { - "alipay": { - "$ref": "#/components/schemas/payment_method_options_alipay" + "interchange_fees": { + "description": "The total interchange received as reimbursement for the transactions.", + "type": "integer" }, - "bancontact": { - "$ref": "#/components/schemas/payment_method_options_bancontact" + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" }, - "card": { - "$ref": "#/components/schemas/payment_intent_payment_method_options_card" + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" }, - "oxxo": { - "$ref": "#/components/schemas/payment_method_options_oxxo" + "net_total": { + "description": "The total net amount required to settle with the network.", + "type": "integer" }, - "p24": { - "$ref": "#/components/schemas/payment_method_options_p24" + "network": { + "description": "The card network for this settlement report. One of [\"visa\", \"maestro\"]", + "enum": ["maestro", "visa"], + "type": "string" }, - "sepa_debit": { - "$ref": "#/components/schemas/payment_intent_payment_method_options_sepa_debit" + "network_fees": { + "description": "The total amount of fees owed to the network.", + "type": "integer" }, - "sofort": { - "$ref": "#/components/schemas/payment_method_options_sofort" - } - }, - "title": "PaymentIntentPaymentMethodOptions", - "type": "object", - "x-expandableFields": [ - "alipay", - "bancontact", - "card", - "oxxo", - "p24", - "sepa_debit", - "sofort" - ] - }, - "payment_intent_payment_method_options_card": { - "description": "", - "properties": { - "installments": { - "anyOf": [ - { - "$ref": "#/components/schemas/payment_method_options_card_installments" - } - ], - "description": "Installment details for this payment (Mexico only).\n\nFor more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).", - "nullable": true + "network_settlement_identifier": { + "description": "The Settlement Identification Number assigned by the network.", + "maxLength": 5000, + "type": "string" }, - "network": { - "description": "Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.", - "enum": [ - "amex", - "cartes_bancaires", - "diners", - "discover", - "interac", - "jcb", - "mastercard", - "unionpay", - "unknown", - "visa" - ], - "nullable": true, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["issuing.settlement"], "type": "string" }, - "request_three_d_secure": { - "description": "We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.", - "enum": ["any", "automatic", "challenge_only"], - "nullable": true, + "settlement_service": { + "description": "One of `international` or `uk_national_net`.", + "maxLength": 5000, "type": "string" + }, + "status": { + "description": "The current processing status of this settlement.", + "enum": ["complete", "pending"], + "type": "string" + }, + "transaction_count": { + "description": "The total number of transactions reflected in this settlement.", + "type": "integer" + }, + "transaction_volume": { + "description": "The total transaction amount reflected in this settlement.", + "type": "integer" } }, - "title": "payment_intent_payment_method_options_card", - "type": "object", - "x-expandableFields": ["installments"] - }, - "payment_intent_payment_method_options_mandate_options_sepa_debit": { - "description": "", - "properties": {}, - "title": "payment_intent_payment_method_options_mandate_options_sepa_debit", - "type": "object", - "x-expandableFields": [] - }, - "payment_intent_payment_method_options_sepa_debit": { - "description": "", - "properties": { - "mandate_options": { - "$ref": "#/components/schemas/payment_intent_payment_method_options_mandate_options_sepa_debit" - } - }, - "title": "payment_intent_payment_method_options_sepa_debit", + "required": [ + "bin", + "clearing_date", + "created", + "currency", + "id", + "interchange_fees", + "livemode", + "metadata", + "net_total", + "network", + "network_fees", + "network_settlement_identifier", + "object", + "settlement_service", + "status", + "transaction_count", + "transaction_volume" + ], + "title": "IssuingSettlement", "type": "object", - "x-expandableFields": ["mandate_options"] + "x-expandableFields": [], + "x-resourceId": "issuing.settlement" }, - "payment_method": { - "description": "PaymentMethod objects represent your customer's payment instruments.\nThey can be used with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or saved to\nCustomer objects to store instrument details for future payments.\n\nRelated guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios).", + "issuing.token": { + "description": "An issuing token object is created when an issued card is added to a digital wallet. As a [card issuer](https://stripe.com/docs/issuing), you can [view and manage these tokens](https://stripe.com/docs/issuing/controls/token-management) through Stripe.", "properties": { - "afterpay_clearpay": { - "$ref": "#/components/schemas/payment_method_afterpay_clearpay" - }, - "alipay": { - "$ref": "#/components/schemas/payment_flows_private_payment_methods_alipay" - }, - "au_becs_debit": { - "$ref": "#/components/schemas/payment_method_au_becs_debit" - }, - "bacs_debit": { - "$ref": "#/components/schemas/payment_method_bacs_debit" - }, - "bancontact": { - "$ref": "#/components/schemas/payment_method_bancontact" - }, - "billing_details": { - "$ref": "#/components/schemas/billing_details" - }, "card": { - "$ref": "#/components/schemas/payment_method_card" - }, - "card_present": { - "$ref": "#/components/schemas/payment_method_card_present" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "customer": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/issuing.card" } ], - "description": "The ID of the Customer to which this PaymentMethod is saved. This will not be set when the PaymentMethod has not been saved to a Customer.", - "nullable": true, + "description": "Card associated with this token.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/issuing.card" } ] } }, - "eps": { - "$ref": "#/components/schemas/payment_method_eps" - }, - "fpx": { - "$ref": "#/components/schemas/payment_method_fpx" - }, - "giropay": { - "$ref": "#/components/schemas/payment_method_giropay" + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" }, - "grabpay": { - "$ref": "#/components/schemas/payment_method_grabpay" + "device_fingerprint": { + "description": "The hashed ID derived from the device ID from the card network associated with the token.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, - "ideal": { - "$ref": "#/components/schemas/payment_method_ideal" - }, - "interac_present": { - "$ref": "#/components/schemas/payment_method_interac_present" + "last4": { + "description": "The last four digits of the token.", + "maxLength": 5000, + "type": "string" }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, - "type": "object" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["payment_method"], + "network": { + "description": "The token service provider / card network associated with the token.", + "enum": ["mastercard", "visa"], "type": "string" }, - "oxxo": { - "$ref": "#/components/schemas/payment_method_oxxo" + "network_data": { + "$ref": "#/components/schemas/issuing_network_token_network_data" }, - "p24": { - "$ref": "#/components/schemas/payment_method_p24" + "network_updated_at": { + "description": "Time at which the token was last updated by the card network. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" }, - "sepa_debit": { - "$ref": "#/components/schemas/payment_method_sepa_debit" + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["issuing.token"], + "type": "string" }, - "sofort": { - "$ref": "#/components/schemas/payment_method_sofort" + "status": { + "description": "The usage state of the token.", + "enum": ["active", "deleted", "requested", "suspended"], + "type": "string" }, - "type": { - "description": "The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.", - "enum": [ - "afterpay_clearpay", - "alipay", - "au_becs_debit", - "bacs_debit", - "bancontact", - "card", - "card_present", - "eps", - "fpx", - "giropay", - "grabpay", - "ideal", - "interac_present", - "oxxo", - "p24", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true + "wallet_provider": { + "description": "The digital wallet for this token, if one was used.", + "enum": ["apple_pay", "google_pay", "samsung_pay"], + "type": "string" } }, "required": [ - "billing_details", + "card", "created", "id", "livemode", + "network", + "network_updated_at", "object", - "type" - ], - "title": "PaymentMethod", - "type": "object", - "x-expandableFields": [ - "afterpay_clearpay", - "alipay", - "au_becs_debit", - "bacs_debit", - "bancontact", - "billing_details", - "card", - "card_present", - "customer", - "eps", - "fpx", - "giropay", - "grabpay", - "ideal", - "interac_present", - "oxxo", - "p24", - "sepa_debit", - "sofort" + "status" ], - "x-resourceId": "payment_method" - }, - "payment_method_afterpay_clearpay": { - "description": "", - "properties": {}, - "title": "payment_method_afterpay_clearpay", + "title": "IssuingNetworkToken", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["card", "network_data"], + "x-resourceId": "issuing.token" }, - "payment_method_au_becs_debit": { - "description": "", + "issuing.transaction": { + "description": "Any use of an [issued card](https://stripe.com/docs/issuing) that results in funds entering or leaving\nyour Stripe account, such as a completed purchase or refund, is represented by an Issuing\n`Transaction` object.\n\nRelated guide: [Issued card transactions](https://stripe.com/docs/issuing/purchases/transactions)", "properties": { - "bsb_number": { - "description": "Six-digit number identifying bank and branch associated with this bank account.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "amount": { + "description": "The transaction amount, which will be reflected in your balance. This amount is in your currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" }, - "fingerprint": { - "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "amount_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_transaction_amount_details" + } + ], + "description": "Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "nullable": true }, - "last4": { - "description": "Last four digits of the bank account number.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "payment_method_au_becs_debit", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_bacs_debit": { - "description": "", - "properties": { - "fingerprint": { - "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", - "maxLength": 5000, + "authorization": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/issuing.authorization" + } + ], + "description": "The `Authorization` object that led to this transaction.", "nullable": true, - "type": "string" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/issuing.authorization" + } + ] + } }, - "last4": { - "description": "Last four digits of the bank account number.", - "maxLength": 5000, + "balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "ID of the [balance transaction](https://stripe.com/docs/api/balance_transactions) associated with this transaction.", "nullable": true, - "type": "string" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } }, - "sort_code": { - "description": "Sort code of the bank account. (e.g., `10-20-30`)", - "maxLength": 5000, + "card": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/issuing.card" + } + ], + "description": "The card used to make this transaction.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/issuing.card" + } + ] + } + }, + "cardholder": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/issuing.cardholder" + } + ], + "description": "The cardholder to whom this transaction belongs.", "nullable": true, - "type": "string" - } - }, - "title": "payment_method_bacs_debit", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_bancontact": { - "description": "", - "properties": {}, - "title": "payment_method_bancontact", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_card": { - "description": "", - "properties": { - "brand": { - "description": "Card brand. Can be `amex`, `diners`, `discover`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", - "maxLength": 5000, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/issuing.cardholder" + } + ] + } + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, - "checks": { + "dispute": { "anyOf": [ { - "$ref": "#/components/schemas/payment_method_card_checks" + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/issuing.dispute" } ], - "description": "Checks on Card address and CVC if provided.", - "nullable": true + "description": "If you've disputed the transaction, the ID of the dispute.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/issuing.dispute" + } + ] + } }, - "country": { - "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "exp_month": { - "description": "Two-digit number representing the card's expiration month.", - "type": "integer" + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" }, - "exp_year": { - "description": "Four-digit number representing the card's expiration year.", + "merchant_amount": { + "description": "The amount that the merchant will receive, denominated in `merchant_currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). It will be different from `amount` if the merchant is taking payment in a different currency.", "type": "integer" }, - "fingerprint": { - "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.", - "maxLength": 5000, - "nullable": true, + "merchant_currency": { + "description": "The currency with which the merchant is taking payment.", "type": "string" }, - "funding": { - "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", - "maxLength": 5000, - "type": "string" + "merchant_data": { + "$ref": "#/components/schemas/issuing_authorization_merchant_data" }, - "generated_from": { + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "network_data": { "anyOf": [ { - "$ref": "#/components/schemas/payment_method_card_generated_card" + "$ref": "#/components/schemas/issuing_transaction_network_data" } ], - "description": "Details of the original PaymentMethod that created this object.", + "description": "Details about the transaction, such as processing dates, set by the card network.", "nullable": true }, - "last4": { - "description": "The last four digits of the card.", - "maxLength": 5000, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["issuing.transaction"], "type": "string" }, - "networks": { + "purchase_details": { "anyOf": [ { - "$ref": "#/components/schemas/networks" + "$ref": "#/components/schemas/issuing_transaction_purchase_details" } ], - "description": "Contains information about card networks that can be used to process the payment.", + "description": "Additional purchase information that is optionally provided by the merchant.", "nullable": true }, - "three_d_secure_usage": { + "token": { "anyOf": [ { - "$ref": "#/components/schemas/three_d_secure_usage" + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/issuing.token" } ], - "description": "Contains details on how this Card maybe be used for 3D Secure authentication.", - "nullable": true + "description": "[Token](https://stripe.com/docs/api/issuing/tokens/object) object used for this transaction. If a network token was not used for this transaction, this field will be null.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/issuing.token" + } + ] + } }, - "wallet": { + "treasury": { "anyOf": [ { - "$ref": "#/components/schemas/payment_method_card_wallet" + "$ref": "#/components/schemas/issuing_transaction_treasury" } ], - "description": "If this Card is part of a card wallet, this contains the details of the card wallet.", + "description": "[Treasury](https://stripe.com/docs/api/treasury) details related to this transaction if it was created on a [FinancialAccount](/docs/api/treasury/financial_accounts", "nullable": true + }, + "type": { + "description": "The nature of the transaction.", + "enum": ["capture", "refund"], + "type": "string", + "x-stripeBypassValidation": true + }, + "wallet": { + "description": "The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`.", + "enum": ["apple_pay", "google_pay", "samsung_pay"], + "nullable": true, + "type": "string" } }, - "required": ["brand", "exp_month", "exp_year", "funding", "last4"], - "title": "payment_method_card", + "required": [ + "amount", + "card", + "created", + "currency", + "id", + "livemode", + "merchant_amount", + "merchant_currency", + "merchant_data", + "metadata", + "object", + "type" + ], + "title": "IssuingTransaction", "type": "object", "x-expandableFields": [ - "checks", - "generated_from", - "networks", - "three_d_secure_usage", - "wallet" - ] + "amount_details", + "authorization", + "balance_transaction", + "card", + "cardholder", + "dispute", + "merchant_data", + "network_data", + "purchase_details", + "token", + "treasury" + ], + "x-resourceId": "issuing.transaction" }, - "payment_method_card_checks": { + "issuing_authorization_amount_details": { "description": "", "properties": { - "address_line1_check": { - "description": "If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "address_postal_code_check": { - "description": "If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", - "maxLength": 5000, + "atm_fee": { + "description": "The fee charged by the ATM for the cash withdrawal.", "nullable": true, - "type": "string" + "type": "integer" }, - "cvc_check": { - "description": "If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", - "maxLength": 5000, + "cashback_amount": { + "description": "The amount of cash requested by the cardholder.", "nullable": true, - "type": "string" + "type": "integer" } }, - "title": "payment_method_card_checks", + "title": "IssuingAuthorizationAmountDetails", "type": "object", "x-expandableFields": [] }, - "payment_method_card_generated_card": { + "issuing_authorization_authentication_exemption": { "description": "", "properties": { - "charge": { - "description": "The charge that created this object.", - "maxLength": 5000, - "nullable": true, + "claimed_by": { + "description": "The entity that requested the exemption, either the acquiring merchant or the Issuing user.", + "enum": ["acquirer", "issuer"], "type": "string" }, - "payment_method_details": { - "anyOf": [ - { - "$ref": "#/components/schemas/card_generated_from_payment_method_details" - } - ], - "description": "Transaction-specific details of the payment method used in the payment.", - "nullable": true - }, - "setup_attempt": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/setup_attempt" - } + "type": { + "description": "The specific exemption claimed for this authorization.", + "enum": [ + "low_value_transaction", + "transaction_risk_analysis", + "unknown" ], - "description": "The ID of the SetupAttempt that generated this PaymentMethod, if any.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/setup_attempt" - } - ] - } + "type": "string", + "x-stripeBypassValidation": true } }, - "title": "payment_method_card_generated_card", - "type": "object", - "x-expandableFields": ["payment_method_details", "setup_attempt"] - }, - "payment_method_card_present": { - "description": "", - "properties": {}, - "title": "payment_method_card_present", + "required": ["claimed_by", "type"], + "title": "IssuingAuthorizationAuthenticationExemption", "type": "object", "x-expandableFields": [] }, - "payment_method_card_wallet": { + "issuing_authorization_fleet_cardholder_prompt_data": { "description": "", "properties": { - "amex_express_checkout": { - "$ref": "#/components/schemas/payment_method_card_wallet_amex_express_checkout" - }, - "apple_pay": { - "$ref": "#/components/schemas/payment_method_card_wallet_apple_pay" - }, - "dynamic_last4": { - "description": "(For tokenized numbers only.) The last four digits of the device account number.", + "alphanumeric_id": { + "description": "[Deprecated] An alphanumeric ID, though typical point of sales only support numeric entry. The card program can be configured to prompt for a vehicle ID, driver ID, or generic ID.", "maxLength": 5000, "nullable": true, "type": "string" }, - "google_pay": { - "$ref": "#/components/schemas/payment_method_card_wallet_google_pay" + "driver_id": { + "description": "Driver ID.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "masterpass": { - "$ref": "#/components/schemas/payment_method_card_wallet_masterpass" + "odometer": { + "description": "Odometer reading.", + "nullable": true, + "type": "integer" }, - "samsung_pay": { - "$ref": "#/components/schemas/payment_method_card_wallet_samsung_pay" + "unspecified_id": { + "description": "An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "type": { - "description": "The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type.", - "enum": [ - "amex_express_checkout", - "apple_pay", - "google_pay", - "masterpass", - "samsung_pay", - "visa_checkout" - ], + "user_id": { + "description": "User ID.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "visa_checkout": { - "$ref": "#/components/schemas/payment_method_card_wallet_visa_checkout" + "vehicle_number": { + "description": "Vehicle number.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "required": ["type"], - "title": "payment_method_card_wallet", - "type": "object", - "x-expandableFields": [ - "amex_express_checkout", - "apple_pay", - "google_pay", - "masterpass", - "samsung_pay", - "visa_checkout" - ] - }, - "payment_method_card_wallet_amex_express_checkout": { - "description": "", - "properties": {}, - "title": "payment_method_card_wallet_amex_express_checkout", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_card_wallet_apple_pay": { - "description": "", - "properties": {}, - "title": "payment_method_card_wallet_apple_pay", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_card_wallet_google_pay": { - "description": "", - "properties": {}, - "title": "payment_method_card_wallet_google_pay", + "title": "IssuingAuthorizationFleetCardholderPromptData", "type": "object", "x-expandableFields": [] }, - "payment_method_card_wallet_masterpass": { + "issuing_authorization_fleet_data": { "description": "", "properties": { - "billing_address": { + "cardholder_prompt_data": { "anyOf": [ { - "$ref": "#/components/schemas/address" + "$ref": "#/components/schemas/issuing_authorization_fleet_cardholder_prompt_data" } ], - "description": "Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "description": "Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.", "nullable": true }, - "email": { - "description": "Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "name": { - "description": "Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, + "purchase_type": { + "description": "The type of purchase.", + "enum": [ + "fuel_and_non_fuel_purchase", + "fuel_purchase", + "non_fuel_purchase" + ], "nullable": true, "type": "string" }, - "shipping_address": { + "reported_breakdown": { "anyOf": [ { - "$ref": "#/components/schemas/address" + "$ref": "#/components/schemas/issuing_authorization_fleet_reported_breakdown" } ], - "description": "Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "description": "More information about the total amount. Typically this information is received from the merchant after the authorization has been approved and the fuel dispensed. This information is not guaranteed to be accurate as some merchants may provide unreliable data.", "nullable": true + }, + "service_type": { + "description": "The type of fuel service.", + "enum": ["full_service", "non_fuel_transaction", "self_service"], + "nullable": true, + "type": "string" } }, - "title": "payment_method_card_wallet_masterpass", + "title": "IssuingAuthorizationFleetData", "type": "object", - "x-expandableFields": ["billing_address", "shipping_address"] + "x-expandableFields": ["cardholder_prompt_data", "reported_breakdown"] }, - "payment_method_card_wallet_samsung_pay": { + "issuing_authorization_fleet_fuel_price_data": { "description": "", - "properties": {}, - "title": "payment_method_card_wallet_samsung_pay", + "properties": { + "gross_amount_decimal": { + "description": "Gross fuel amount that should equal Fuel Quantity multiplied by Fuel Unit Cost, inclusive of taxes.", + "format": "decimal", + "nullable": true, + "type": "string" + } + }, + "title": "IssuingAuthorizationFleetFuelPriceData", "type": "object", "x-expandableFields": [] }, - "payment_method_card_wallet_visa_checkout": { + "issuing_authorization_fleet_non_fuel_price_data": { "description": "", "properties": { - "billing_address": { + "gross_amount_decimal": { + "description": "Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.", + "format": "decimal", + "nullable": true, + "type": "string" + } + }, + "title": "IssuingAuthorizationFleetNonFuelPriceData", + "type": "object", + "x-expandableFields": [] + }, + "issuing_authorization_fleet_reported_breakdown": { + "description": "", + "properties": { + "fuel": { "anyOf": [ { - "$ref": "#/components/schemas/address" + "$ref": "#/components/schemas/issuing_authorization_fleet_fuel_price_data" } ], - "description": "Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "description": "Breakdown of fuel portion of the purchase.", "nullable": true }, - "email": { - "description": "Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "name": { - "description": "Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "non_fuel": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_authorization_fleet_non_fuel_price_data" + } + ], + "description": "Breakdown of non-fuel portion of the purchase.", + "nullable": true }, - "shipping_address": { + "tax": { "anyOf": [ { - "$ref": "#/components/schemas/address" + "$ref": "#/components/schemas/issuing_authorization_fleet_tax_data" } ], - "description": "Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "description": "Information about tax included in this transaction.", "nullable": true } }, - "title": "payment_method_card_wallet_visa_checkout", + "title": "IssuingAuthorizationFleetReportedBreakdown", "type": "object", - "x-expandableFields": ["billing_address", "shipping_address"] + "x-expandableFields": ["fuel", "non_fuel", "tax"] }, - "payment_method_details": { + "issuing_authorization_fleet_tax_data": { "description": "", "properties": { - "ach_credit_transfer": { - "$ref": "#/components/schemas/payment_method_details_ach_credit_transfer" - }, - "ach_debit": { - "$ref": "#/components/schemas/payment_method_details_ach_debit" - }, - "afterpay_clearpay": { - "$ref": "#/components/schemas/payment_method_details_afterpay_clearpay" - }, - "alipay": { - "$ref": "#/components/schemas/payment_flows_private_payment_methods_alipay_details" - }, - "au_becs_debit": { - "$ref": "#/components/schemas/payment_method_details_au_becs_debit" - }, - "bacs_debit": { - "$ref": "#/components/schemas/payment_method_details_bacs_debit" - }, - "bancontact": { - "$ref": "#/components/schemas/payment_method_details_bancontact" - }, - "card": { - "$ref": "#/components/schemas/payment_method_details_card" - }, - "card_present": { - "$ref": "#/components/schemas/payment_method_details_card_present" - }, - "eps": { - "$ref": "#/components/schemas/payment_method_details_eps" - }, - "fpx": { - "$ref": "#/components/schemas/payment_method_details_fpx" - }, - "giropay": { - "$ref": "#/components/schemas/payment_method_details_giropay" - }, - "grabpay": { - "$ref": "#/components/schemas/payment_method_details_grabpay" - }, - "ideal": { - "$ref": "#/components/schemas/payment_method_details_ideal" - }, - "interac_present": { - "$ref": "#/components/schemas/payment_method_details_interac_present" - }, - "klarna": { - "$ref": "#/components/schemas/payment_method_details_klarna" - }, - "multibanco": { - "$ref": "#/components/schemas/payment_method_details_multibanco" - }, - "oxxo": { - "$ref": "#/components/schemas/payment_method_details_oxxo" - }, - "p24": { - "$ref": "#/components/schemas/payment_method_details_p24" - }, - "sepa_debit": { - "$ref": "#/components/schemas/payment_method_details_sepa_debit" - }, - "sofort": { - "$ref": "#/components/schemas/payment_method_details_sofort" - }, - "stripe_account": { - "$ref": "#/components/schemas/payment_method_details_stripe_account" - }, - "type": { - "description": "The type of transaction-specific details of the payment method used in the payment, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `au_becs_debit`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `klarna`, `multibanco`, `p24`, `sepa_debit`, `sofort`, `stripe_account`, or `wechat`.\nAn additional hash is included on `payment_method_details` with a name matching this value.\nIt contains information specific to the payment method.", - "maxLength": 5000, + "local_amount_decimal": { + "description": "Amount of state or provincial Sales Tax included in the transaction amount. `null` if not reported by merchant or not subject to tax.", + "format": "decimal", + "nullable": true, "type": "string" }, - "wechat": { - "$ref": "#/components/schemas/payment_method_details_wechat" + "national_amount_decimal": { + "description": "Amount of national Sales Tax or VAT included in the transaction amount. `null` if not reported by merchant or not subject to tax.", + "format": "decimal", + "nullable": true, + "type": "string" } }, - "required": ["type"], - "title": "payment_method_details", + "title": "IssuingAuthorizationFleetTaxData", "type": "object", - "x-expandableFields": [ - "ach_credit_transfer", - "ach_debit", - "afterpay_clearpay", - "alipay", - "au_becs_debit", - "bacs_debit", - "bancontact", - "card", - "card_present", - "eps", - "fpx", - "giropay", - "grabpay", - "ideal", - "interac_present", - "klarna", - "multibanco", - "oxxo", - "p24", - "sepa_debit", - "sofort", - "stripe_account", - "wechat" - ] + "x-expandableFields": [] }, - "payment_method_details_ach_credit_transfer": { + "issuing_authorization_fuel_data": { "description": "", "properties": { - "account_number": { - "description": "Account number to transfer funds to.", + "industry_product_code": { + "description": "[Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.", "maxLength": 5000, "nullable": true, "type": "string" }, - "bank_name": { - "description": "Name of the bank associated with the routing number.", - "maxLength": 5000, + "quantity_decimal": { + "description": "The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.", + "format": "decimal", "nullable": true, "type": "string" }, - "routing_number": { - "description": "Routing transit number for the bank account to transfer funds to.", - "maxLength": 5000, + "type": { + "description": "The type of fuel that was purchased.", + "enum": [ + "diesel", + "other", + "unleaded_plus", + "unleaded_regular", + "unleaded_super" + ], "nullable": true, "type": "string" }, - "swift_code": { - "description": "SWIFT code of the bank associated with the routing number.", - "maxLength": 5000, + "unit": { + "description": "The units for `quantity_decimal`.", + "enum": [ + "charging_minute", + "imperial_gallon", + "kilogram", + "kilowatt_hour", + "liter", + "other", + "pound", + "us_gallon" + ], + "nullable": true, + "type": "string" + }, + "unit_cost_decimal": { + "description": "The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.", + "format": "decimal", "nullable": true, "type": "string" } }, - "title": "payment_method_details_ach_credit_transfer", + "title": "IssuingAuthorizationFuelData", "type": "object", "x-expandableFields": [] }, - "payment_method_details_ach_debit": { + "issuing_authorization_merchant_data": { "description": "", "properties": { - "account_holder_type": { - "description": "Type of entity that holds the account. This can be either `individual` or `company`.", - "enum": ["company", "individual"], - "nullable": true, + "category": { + "description": "A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.", + "maxLength": 5000, "type": "string" }, - "bank_name": { - "description": "Name of the bank associated with the bank account.", + "category_code": { + "description": "The merchant category code for the seller’s business", "maxLength": 5000, - "nullable": true, "type": "string" }, - "country": { - "description": "Two-letter ISO code representing the country the bank account is located in.", + "city": { + "description": "City where the seller is located", "maxLength": 5000, "nullable": true, "type": "string" }, - "fingerprint": { - "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "country": { + "description": "Country where the seller is located", "maxLength": 5000, "nullable": true, "type": "string" }, - "last4": { - "description": "Last four digits of the bank account number.", + "name": { + "description": "Name of the seller", "maxLength": 5000, "nullable": true, "type": "string" }, - "routing_number": { - "description": "Routing transit number of the bank account.", + "network_id": { + "description": "Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.", "maxLength": 5000, - "nullable": true, "type": "string" - } - }, - "title": "payment_method_details_ach_debit", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_afterpay_clearpay": { - "description": "", - "properties": {}, - "title": "payment_method_details_afterpay_clearpay", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_au_becs_debit": { - "description": "", - "properties": { - "bsb_number": { - "description": "Bank-State-Branch number of the bank account.", + }, + "postal_code": { + "description": "Postal code where the seller is located", "maxLength": 5000, "nullable": true, "type": "string" }, - "fingerprint": { - "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "state": { + "description": "State where the seller is located", "maxLength": 5000, "nullable": true, "type": "string" }, - "last4": { - "description": "Last four digits of the bank account number.", + "terminal_id": { + "description": "An ID assigned by the seller to the location of the sale.", "maxLength": 5000, "nullable": true, "type": "string" }, - "mandate": { - "description": "ID of the mandate used to make this payment.", + "url": { + "description": "URL provided by the merchant on a 3DS request", "maxLength": 5000, + "nullable": true, "type": "string" } }, - "title": "payment_method_details_au_becs_debit", + "required": ["category", "category_code", "network_id"], + "title": "IssuingAuthorizationMerchantData", "type": "object", "x-expandableFields": [] }, - "payment_method_details_bacs_debit": { + "issuing_authorization_network_data": { "description": "", "properties": { - "fingerprint": { - "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "last4": { - "description": "Last four digits of the bank account number.", + "acquiring_institution_id": { + "description": "Identifier assigned to the acquirer by the card network. Sometimes this value is not provided by the network; in this case, the value will be `null`.", "maxLength": 5000, "nullable": true, "type": "string" }, - "mandate": { - "description": "ID of the mandate used to make this payment.", + "system_trace_audit_number": { + "description": "The System Trace Audit Number (STAN) is a 6-digit identifier assigned by the acquirer. Prefer `network_data.transaction_id` if present, unless you have special requirements.", "maxLength": 5000, "nullable": true, "type": "string" }, - "sort_code": { - "description": "Sort code of the bank account. (e.g., `10-20-30`)", + "transaction_id": { + "description": "Unique identifier for the authorization assigned by the card network used to match subsequent messages, disputes, and transactions.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "payment_method_details_bacs_debit", + "title": "IssuingAuthorizationNetworkData", "type": "object", "x-expandableFields": [] }, - "payment_method_details_bancontact": { + "issuing_authorization_pending_request": { "description": "", "properties": { - "bank_code": { - "description": "Bank code of bank associated with the bank account.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "bank_name": { - "description": "Name of the bank associated with the bank account.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "bic": { - "description": "Bank Identifier Code of the bank associated with the bank account.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "generated_sepa_debit": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" - } - ], - "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } + "amount": { + "description": "The additional amount Stripe will hold if the authorization is approved, in the card's [currency](https://stripe.com/docs/api#issuing_authorization_object-pending-request-currency) and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" }, - "generated_sepa_debit_mandate": { + "amount_details": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/mandate" + "$ref": "#/components/schemas/issuing_authorization_amount_details" } ], - "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/mandate" - } - ] - } + "description": "Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "nullable": true }, - "iban_last4": { - "description": "Last four characters of the IBAN.", - "maxLength": 5000, - "nullable": true, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, - "preferred_language": { - "description": "Preferred language of the Bancontact authorization page that the customer is redirected to.\nCan be one of `en`, `de`, `fr`, or `nl`", - "enum": ["de", "en", "fr", "nl"], - "nullable": true, + "is_amount_controllable": { + "description": "If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.", + "type": "boolean" + }, + "merchant_amount": { + "description": "The amount the merchant is requesting to be authorized in the `merchant_currency`. The amount is in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "merchant_currency": { + "description": "The local currency the merchant is requesting to authorize.", "type": "string" }, - "verified_name": { - "description": "Owner's verified full name. Values are verified or provided by Bancontact directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, + "network_risk_score": { + "description": "The card network's estimate of the likelihood that an authorization is fraudulent. Takes on values between 1 and 99.", "nullable": true, - "type": "string" + "type": "integer" } }, - "title": "payment_method_details_bancontact", + "required": [ + "amount", + "currency", + "is_amount_controllable", + "merchant_amount", + "merchant_currency" + ], + "title": "IssuingAuthorizationPendingRequest", "type": "object", - "x-expandableFields": [ - "generated_sepa_debit", - "generated_sepa_debit_mandate" - ] + "x-expandableFields": ["amount_details"] }, - "payment_method_details_card": { + "issuing_authorization_request": { "description": "", "properties": { - "brand": { - "description": "Card brand. Can be `amex`, `diners`, `discover`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "amount": { + "description": "The `pending_request.amount` at the time of the request, presented in your card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). Stripe held this amount from your account to fund the authorization if the request was approved.", + "type": "integer" }, - "checks": { + "amount_details": { "anyOf": [ { - "$ref": "#/components/schemas/payment_method_details_card_checks" + "$ref": "#/components/schemas/issuing_authorization_amount_details" } ], - "description": "Check results by Card networks on Card address and CVC at time of payment.", + "description": "Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", "nullable": true }, - "country": { - "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", + "approved": { + "description": "Whether this request was approved.", + "type": "boolean" + }, + "authorization_code": { + "description": "A code created by Stripe which is shared with the merchant to validate the authorization. This field will be populated if the authorization message was approved. The code typically starts with the letter \"S\", followed by a six-digit number. For example, \"S498162\". Please note that the code is not guaranteed to be unique across authorizations.", "maxLength": 5000, "nullable": true, "type": "string" }, - "exp_month": { - "description": "Two-digit number representing the card's expiration month.", + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", "type": "integer" }, - "exp_year": { - "description": "Four-digit number representing the card's expiration year.", + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "maxLength": 5000, + "type": "string" + }, + "merchant_amount": { + "description": "The `pending_request.merchant_amount` at the time of the request, presented in the `merchant_currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", "type": "integer" }, - "fingerprint": { - "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.", + "merchant_currency": { + "description": "The currency that was collected by the merchant and presented to the cardholder for the authorization. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "maxLength": 5000, - "nullable": true, "type": "string" }, - "funding": { - "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", - "maxLength": 5000, + "network_risk_score": { + "description": "The card network's estimate of the likelihood that an authorization is fraudulent. Takes on values between 1 and 99.", "nullable": true, - "type": "string" + "type": "integer" }, - "installments": { - "anyOf": [ - { - "$ref": "#/components/schemas/payment_method_details_card_installments" - } + "reason": { + "description": "When an authorization is approved or declined by you or by Stripe, this field provides additional detail on the reason for the outcome.", + "enum": [ + "account_disabled", + "card_active", + "card_canceled", + "card_expired", + "card_inactive", + "cardholder_blocked", + "cardholder_inactive", + "cardholder_verification_required", + "insecure_authorization_method", + "insufficient_funds", + "not_allowed", + "pin_blocked", + "spending_controls", + "suspected_fraud", + "verification_failed", + "webhook_approved", + "webhook_declined", + "webhook_error", + "webhook_timeout" ], - "description": "Installment details for this payment (Mexico only).\n\nFor more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).", - "nullable": true + "type": "string", + "x-stripeBypassValidation": true }, - "last4": { - "description": "The last four digits of the card.", + "reason_message": { + "description": "If the `request_history.reason` is `webhook_error` because the direct webhook response is invalid (for example, parsing errors or missing parameters), we surface a more detailed error message via this field.", "maxLength": 5000, "nullable": true, "type": "string" }, - "network": { - "description": "Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", - "maxLength": 5000, + "requested_at": { + "description": "Time when the card network received an authorization request from the acquirer in UTC. Referred to by networks as transmission time.", + "format": "unix-time", "nullable": true, - "type": "string" - }, - "three_d_secure": { - "anyOf": [ - { - "$ref": "#/components/schemas/three_d_secure_details" - } - ], - "description": "Populated if this transaction used 3D Secure authentication.", - "nullable": true - }, - "wallet": { - "anyOf": [ - { - "$ref": "#/components/schemas/payment_method_details_card_wallet" - } + "type": "integer" + } + }, + "required": [ + "amount", + "approved", + "created", + "currency", + "merchant_amount", + "merchant_currency", + "reason" + ], + "title": "IssuingAuthorizationRequest", + "type": "object", + "x-expandableFields": ["amount_details"] + }, + "issuing_authorization_three_d_secure": { + "description": "", + "properties": { + "result": { + "description": "The outcome of the 3D Secure authentication request.", + "enum": [ + "attempt_acknowledged", + "authenticated", + "failed", + "required" ], - "description": "If this Card is part of a card wallet, this contains the details of the card wallet.", - "nullable": true + "type": "string", + "x-stripeBypassValidation": true } }, - "required": ["exp_month", "exp_year"], - "title": "payment_method_details_card", + "required": ["result"], + "title": "IssuingAuthorizationThreeDSecure", "type": "object", - "x-expandableFields": [ - "checks", - "installments", - "three_d_secure", - "wallet" - ] + "x-expandableFields": [] }, - "payment_method_details_card_checks": { + "issuing_authorization_treasury": { "description": "", "properties": { - "address_line1_check": { - "description": "If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "received_credits": { + "description": "The array of [ReceivedCredits](https://stripe.com/docs/api/treasury/received_credits) associated with this authorization", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "address_postal_code_check": { - "description": "If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "received_debits": { + "description": "The array of [ReceivedDebits](https://stripe.com/docs/api/treasury/received_debits) associated with this authorization", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "cvc_check": { - "description": "If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "transaction": { + "description": "The Treasury [Transaction](https://stripe.com/docs/api/treasury/transactions) associated with this authorization", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "payment_method_details_card_checks", + "required": ["received_credits", "received_debits"], + "title": "IssuingAuthorizationTreasury", "type": "object", "x-expandableFields": [] }, - "payment_method_details_card_installments": { + "issuing_authorization_verification_data": { "description": "", "properties": { - "plan": { + "address_line1_check": { + "description": "Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`.", + "enum": ["match", "mismatch", "not_provided"], + "type": "string" + }, + "address_postal_code_check": { + "description": "Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`.", + "enum": ["match", "mismatch", "not_provided"], + "type": "string" + }, + "authentication_exemption": { "anyOf": [ { - "$ref": "#/components/schemas/payment_method_details_card_installments_plan" + "$ref": "#/components/schemas/issuing_authorization_authentication_exemption" } ], - "description": "Installment plan selected for the payment.", + "description": "The exemption applied to this authorization.", "nullable": true - } - }, - "title": "payment_method_details_card_installments", - "type": "object", - "x-expandableFields": ["plan"] - }, - "payment_method_details_card_installments_plan": { - "description": "", - "properties": { - "count": { - "description": "For `fixed_count` installment plans, this is the number of installment payments your customer will make to their credit card.", - "nullable": true, - "type": "integer" }, - "interval": { - "description": "For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card.\nOne of `month`.", - "enum": ["month"], - "nullable": true, + "cvc_check": { + "description": "Whether the cardholder provided a CVC and if it matched Stripe’s record.", + "enum": ["match", "mismatch", "not_provided"], "type": "string" }, - "type": { - "description": "Type of installment plan, one of `fixed_count`.", - "enum": ["fixed_count"], + "expiry_check": { + "description": "Whether the cardholder provided an expiry date and if it matched Stripe’s record.", + "enum": ["match", "mismatch", "not_provided"], "type": "string" - } - }, - "required": ["type"], - "title": "payment_method_details_card_installments_plan", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_card_present": { - "description": "", - "properties": { - "brand": { - "description": "Card brand. Can be `amex`, `diners`, `discover`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + }, + "postal_code": { + "description": "The postal code submitted as part of the authorization used for postal code verification.", "maxLength": 5000, "nullable": true, "type": "string" }, - "cardholder_name": { - "description": "The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`).", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "country": { - "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "emv_auth_data": { - "description": "Authorization response cryptogram.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "exp_month": { - "description": "Two-digit number representing the card's expiration month.", - "type": "integer" - }, - "exp_year": { - "description": "Four-digit number representing the card's expiration year.", - "type": "integer" - }, - "fingerprint": { - "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "funding": { - "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "generated_card": { - "description": "ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "last4": { - "description": "The last four digits of the card.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "network": { - "description": "Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "read_method": { - "description": "How card details were read in this transaction.", - "enum": [ - "contact_emv", - "contactless_emv", - "contactless_magstripe_mode", - "magnetic_stripe_fallback", - "magnetic_stripe_track2" - ], - "nullable": true, - "type": "string" - }, - "receipt": { + "three_d_secure": { "anyOf": [ { - "$ref": "#/components/schemas/payment_method_details_card_present_receipt" + "$ref": "#/components/schemas/issuing_authorization_three_d_secure" } ], - "description": "A collection of fields required to be displayed on receipts. Only required for EMV transactions.", + "description": "3D Secure details.", "nullable": true } }, - "required": ["exp_month", "exp_year"], - "title": "payment_method_details_card_present", + "required": [ + "address_line1_check", + "address_postal_code_check", + "cvc_check", + "expiry_check" + ], + "title": "IssuingAuthorizationVerificationData", "type": "object", - "x-expandableFields": ["receipt"] + "x-expandableFields": ["authentication_exemption", "three_d_secure"] }, - "payment_method_details_card_present_receipt": { + "issuing_card_apple_pay": { "description": "", "properties": { - "account_type": { - "description": "The type of account being debited or credited", - "enum": ["checking", "credit", "prepaid", "unknown"], - "type": "string", - "x-stripeBypassValidation": true - }, - "application_cryptogram": { - "description": "EMV tag 9F26, cryptogram generated by the integrated circuit chip.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "application_preferred_name": { - "description": "Mnenomic of the Application Identifier.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "authorization_code": { - "description": "Identifier for this transaction.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "authorization_response_code": { - "description": "EMV tag 8A. A code returned by the card issuer.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "cardholder_verification_method": { - "description": "How the cardholder verified ownership of the card.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "dedicated_file_name": { - "description": "EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "terminal_verification_results": { - "description": "The outcome of a series of EMV functions performed by the card reader.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "eligible": { + "description": "Apple Pay Eligibility", + "type": "boolean" }, - "transaction_status_information": { - "description": "An indication of various EMV functions performed during the transaction.", - "maxLength": 5000, + "ineligible_reason": { + "description": "Reason the card is ineligible for Apple Pay", + "enum": [ + "missing_agreement", + "missing_cardholder_contact", + "unsupported_region" + ], "nullable": true, "type": "string" } }, - "title": "payment_method_details_card_present_receipt", + "required": ["eligible"], + "title": "IssuingCardApplePay", "type": "object", "x-expandableFields": [] }, - "payment_method_details_card_wallet": { + "issuing_card_authorization_controls": { "description": "", "properties": { - "amex_express_checkout": { - "$ref": "#/components/schemas/payment_method_details_card_wallet_amex_express_checkout" - }, - "apple_pay": { - "$ref": "#/components/schemas/payment_method_details_card_wallet_apple_pay" - }, - "dynamic_last4": { - "description": "(For tokenized numbers only.) The last four digits of the device account number.", - "maxLength": 5000, + "allowed_categories": { + "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.", + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "type": "string" + }, "nullable": true, - "type": "string" - }, - "google_pay": { - "$ref": "#/components/schemas/payment_method_details_card_wallet_google_pay" - }, - "masterpass": { - "$ref": "#/components/schemas/payment_method_details_card_wallet_masterpass" - }, - "samsung_pay": { - "$ref": "#/components/schemas/payment_method_details_card_wallet_samsung_pay" + "type": "array" }, - "type": { - "description": "The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type.", - "enum": [ - "amex_express_checkout", - "apple_pay", - "google_pay", - "masterpass", - "samsung_pay", - "visa_checkout" - ], - "type": "string" + "allowed_merchant_countries": { + "description": "Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" }, - "visa_checkout": { - "$ref": "#/components/schemas/payment_method_details_card_wallet_visa_checkout" - } - }, - "required": ["type"], - "title": "payment_method_details_card_wallet", - "type": "object", - "x-expandableFields": [ - "amex_express_checkout", - "apple_pay", - "google_pay", - "masterpass", - "samsung_pay", - "visa_checkout" - ] - }, - "payment_method_details_card_wallet_amex_express_checkout": { - "description": "", - "properties": {}, - "title": "payment_method_details_card_wallet_amex_express_checkout", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_card_wallet_apple_pay": { - "description": "", - "properties": {}, - "title": "payment_method_details_card_wallet_apple_pay", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_card_wallet_google_pay": { - "description": "", - "properties": {}, - "title": "payment_method_details_card_wallet_google_pay", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_card_wallet_masterpass": { - "description": "", - "properties": { - "billing_address": { - "anyOf": [ - { - "$ref": "#/components/schemas/address" - } - ], - "description": "Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "nullable": true + "blocked_categories": { + "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.", + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "type": "string" + }, + "nullable": true, + "type": "array" }, - "email": { - "description": "Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, + "blocked_merchant_countries": { + "description": "Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.", + "items": { + "maxLength": 5000, + "type": "string" + }, "nullable": true, - "type": "string" + "type": "array" }, - "name": { - "description": "Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, + "spending_limits": { + "description": "Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).", + "items": { + "$ref": "#/components/schemas/issuing_card_spending_limit" + }, "nullable": true, - "type": "string" + "type": "array" }, - "shipping_address": { - "anyOf": [ - { - "$ref": "#/components/schemas/address" - } - ], - "description": "Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "nullable": true + "spending_limits_currency": { + "description": "Currency of the amounts within `spending_limits`. Always the same as the currency of the card.", + "nullable": true, + "type": "string" } }, - "title": "payment_method_details_card_wallet_masterpass", + "title": "IssuingCardAuthorizationControls", "type": "object", - "x-expandableFields": ["billing_address", "shipping_address"] + "x-expandableFields": ["spending_limits"] }, - "payment_method_details_card_wallet_samsung_pay": { + "issuing_card_google_pay": { "description": "", - "properties": {}, - "title": "payment_method_details_card_wallet_samsung_pay", + "properties": { + "eligible": { + "description": "Google Pay Eligibility", + "type": "boolean" + }, + "ineligible_reason": { + "description": "Reason the card is ineligible for Google Pay", + "enum": [ + "missing_agreement", + "missing_cardholder_contact", + "unsupported_region" + ], + "nullable": true, + "type": "string" + } + }, + "required": ["eligible"], + "title": "IssuingCardGooglePay", "type": "object", "x-expandableFields": [] }, - "payment_method_details_card_wallet_visa_checkout": { + "issuing_card_shipping": { "description": "", "properties": { - "billing_address": { + "address": { + "$ref": "#/components/schemas/address" + }, + "address_validation": { "anyOf": [ { - "$ref": "#/components/schemas/address" + "$ref": "#/components/schemas/issuing_card_shipping_address_validation" } ], - "description": "Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "description": "Address validation details for the shipment.", "nullable": true }, - "email": { - "description": "Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "name": { - "description": "Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, + "carrier": { + "description": "The delivery company that shipped a card.", + "enum": ["dhl", "fedex", "royal_mail", "usps"], "nullable": true, "type": "string" }, - "shipping_address": { + "customs": { "anyOf": [ { - "$ref": "#/components/schemas/address" + "$ref": "#/components/schemas/issuing_card_shipping_customs" } ], - "description": "Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "description": "Additional information that may be required for clearing customs.", "nullable": true - } - }, - "title": "payment_method_details_card_wallet_visa_checkout", - "type": "object", - "x-expandableFields": ["billing_address", "shipping_address"] - }, - "payment_method_details_eps": { - "description": "", - "properties": { - "bank": { - "description": "The customer's bank. Should be one of `arzte_und_apotheker_bank`, `austrian_anadi_bank_ag`, `bank_austria`, `bankhaus_carl_spangler`, `bankhaus_schelhammer_und_schattera_ag`, `bawag_psk_ag`, `bks_bank_ag`, `brull_kallmus_bank_ag`, `btv_vier_lander_bank`, `capital_bank_grawe_gruppe_ag`, `dolomitenbank`, `easybank_ag`, `erste_bank_und_sparkassen`, `hypo_alpeadriabank_international_ag`, `hypo_noe_lb_fur_niederosterreich_u_wien`, `hypo_oberosterreich_salzburg_steiermark`, `hypo_tirol_bank_ag`, `hypo_vorarlberg_bank_ag`, `hypo_bank_burgenland_aktiengesellschaft`, `marchfelder_bank`, `oberbank_ag`, `raiffeisen_bankengruppe_osterreich`, `schoellerbank_ag`, `sparda_bank_wien`, `volksbank_gruppe`, `volkskreditbank_ag`, or `vr_bank_braunau`.", + }, + "eta": { + "description": "A unix timestamp representing a best estimate of when the card will be delivered.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "name": { + "description": "Recipient name.", + "maxLength": 5000, + "type": "string" + }, + "phone_number": { + "description": "The phone number of the receiver of the shipment. Our courier partners will use this number to contact you in the event of card delivery issues. For individual shipments to the EU/UK, if this field is empty, we will provide them with the phone number provided when the cardholder was initially created.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "require_signature": { + "description": "Whether a signature is required for card delivery. This feature is only supported for US users. Standard shipping service does not support signature on delivery. The default value for standard shipping service is false and for express and priority services is true.", + "nullable": true, + "type": "boolean" + }, + "service": { + "description": "Shipment service, such as `standard` or `express`.", + "enum": ["express", "priority", "standard"], + "type": "string", + "x-stripeBypassValidation": true + }, + "status": { + "description": "The delivery status of the card.", "enum": [ - "arzte_und_apotheker_bank", - "austrian_anadi_bank_ag", - "bank_austria", - "bankhaus_carl_spangler", - "bankhaus_schelhammer_und_schattera_ag", - "bawag_psk_ag", - "bks_bank_ag", - "brull_kallmus_bank_ag", - "btv_vier_lander_bank", - "capital_bank_grawe_gruppe_ag", - "dolomitenbank", - "easybank_ag", - "erste_bank_und_sparkassen", - "hypo_alpeadriabank_international_ag", - "hypo_bank_burgenland_aktiengesellschaft", - "hypo_noe_lb_fur_niederosterreich_u_wien", - "hypo_oberosterreich_salzburg_steiermark", - "hypo_tirol_bank_ag", - "hypo_vorarlberg_bank_ag", - "marchfelder_bank", - "oberbank_ag", - "raiffeisen_bankengruppe_osterreich", - "schoellerbank_ag", - "sparda_bank_wien", - "volksbank_gruppe", - "volkskreditbank_ag", - "vr_bank_braunau" + "canceled", + "delivered", + "failure", + "pending", + "returned", + "shipped" ], "nullable": true, "type": "string" }, - "verified_name": { - "description": "Owner's verified full name. Values are verified or provided by EPS directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.\nEPS rarely provides this information so the attribute is usually empty.", + "tracking_number": { + "description": "A tracking number for a card shipment.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "tracking_url": { + "description": "A link to the shipping carrier's site where you can view detailed information about a card shipment.", "maxLength": 5000, "nullable": true, "type": "string" + }, + "type": { + "description": "Packaging options.", + "enum": ["bulk", "individual"], + "type": "string" } }, - "title": "payment_method_details_eps", + "required": ["address", "name", "service", "type"], + "title": "IssuingCardShipping", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["address", "address_validation", "customs"] }, - "payment_method_details_fpx": { + "issuing_card_shipping_address_validation": { "description": "", "properties": { - "bank": { - "description": "The customer's bank. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`.", + "mode": { + "description": "The address validation capabilities to use.", "enum": [ - "affin_bank", - "alliance_bank", - "ambank", - "bank_islam", - "bank_muamalat", - "bank_rakyat", - "bsn", - "cimb", - "deutsche_bank", - "hong_leong_bank", - "hsbc", - "kfh", - "maybank2e", - "maybank2u", - "ocbc", - "pb_enterprise", - "public_bank", - "rhb", - "standard_chartered", - "uob" + "disabled", + "normalization_only", + "validation_and_normalization" ], "type": "string" }, - "transaction_id": { - "description": "Unique transaction id generated by FPX for every request from the merchant", - "maxLength": 5000, + "normalized_address": { + "anyOf": [ + { + "$ref": "#/components/schemas/address" + } + ], + "description": "The normalized shipping address.", + "nullable": true + }, + "result": { + "description": "The validation result for the shipping address.", + "enum": [ + "indeterminate", + "likely_deliverable", + "likely_undeliverable" + ], "nullable": true, "type": "string" } }, - "required": ["bank"], - "title": "payment_method_details_fpx", + "required": ["mode"], + "title": "IssuingCardShippingAddressValidation", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["normalized_address"] }, - "payment_method_details_giropay": { + "issuing_card_shipping_customs": { "description": "", "properties": { - "bank_code": { - "description": "Bank code of bank associated with the bank account.", + "eori_number": { + "description": "A registration number used for customs in Europe. See [https://www.gov.uk/eori](https://www.gov.uk/eori) for the UK and [https://ec.europa.eu/taxation_customs/business/customs-procedures-import-and-export/customs-procedures/economic-operators-registration-and-identification-number-eori_en](https://ec.europa.eu/taxation_customs/business/customs-procedures-import-and-export/customs-procedures/economic-operators-registration-and-identification-number-eori_en) for the EU.", "maxLength": 5000, "nullable": true, "type": "string" + } + }, + "title": "IssuingCardShippingCustoms", + "type": "object", + "x-expandableFields": [] + }, + "issuing_card_spending_limit": { + "description": "", + "properties": { + "amount": { + "description": "Maximum amount allowed to spend per interval. This amount is in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" }, - "bank_name": { - "description": "Name of the bank associated with the bank account.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "bic": { - "description": "Bank Identifier Code of the bank associated with the bank account.", - "maxLength": 5000, + "categories": { + "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.", + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "type": "string" + }, "nullable": true, - "type": "string" + "type": "array" }, - "verified_name": { - "description": "Owner's verified full name. Values are verified or provided by Giropay directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.\nGiropay rarely provides this information so the attribute is usually empty.", - "maxLength": 5000, - "nullable": true, + "interval": { + "description": "Interval (or event) to which the amount applies.", + "enum": [ + "all_time", + "daily", + "monthly", + "per_authorization", + "weekly", + "yearly" + ], "type": "string" } }, - "title": "payment_method_details_giropay", + "required": ["amount", "interval"], + "title": "IssuingCardSpendingLimit", "type": "object", "x-expandableFields": [] }, - "payment_method_details_grabpay": { + "issuing_card_wallets": { "description": "", "properties": { - "transaction_id": { - "description": "Unique transaction id generated by GrabPay", + "apple_pay": { + "$ref": "#/components/schemas/issuing_card_apple_pay" + }, + "google_pay": { + "$ref": "#/components/schemas/issuing_card_google_pay" + }, + "primary_account_identifier": { + "description": "Unique identifier for a card used with digital wallets", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "payment_method_details_grabpay", + "required": ["apple_pay", "google_pay"], + "title": "IssuingCardWallets", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["apple_pay", "google_pay"] }, - "payment_method_details_ideal": { + "issuing_cardholder_address": { "description": "", "properties": { - "bank": { - "description": "The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, or `van_lanschot`.", - "enum": [ - "abn_amro", - "asn_bank", - "bunq", - "handelsbanken", - "ing", - "knab", - "moneyou", - "rabobank", - "regiobank", - "revolut", - "sns_bank", - "triodos_bank", - "van_lanschot" - ], - "nullable": true, - "type": "string" - }, - "bic": { - "description": "The Bank Identifier Code of the customer's bank.", - "enum": [ - "ABNANL2A", - "ASNBNL21", - "BUNQNL2A", - "FVLBNL22", - "HANDNL2A", - "INGBNL2A", - "KNABNL2H", - "MOYONL21", - "RABONL2U", - "RBRBNL21", - "REVOLT21", - "SNSBNL2A", - "TRIONL2U" - ], - "nullable": true, - "type": "string" - }, - "generated_sepa_debit": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" - } - ], - "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } - }, - "generated_sepa_debit_mandate": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/mandate" - } - ], - "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/mandate" - } - ] - } - }, - "iban_last4": { - "description": "Last four characters of the IBAN.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "verified_name": { - "description": "Owner's verified full name. Values are verified or provided by iDEAL directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "address": { + "$ref": "#/components/schemas/address" } }, - "title": "payment_method_details_ideal", + "required": ["address"], + "title": "IssuingCardholderAddress", "type": "object", - "x-expandableFields": [ - "generated_sepa_debit", - "generated_sepa_debit_mandate" - ] + "x-expandableFields": ["address"] }, - "payment_method_details_interac_present": { + "issuing_cardholder_authorization_controls": { "description": "", "properties": { - "brand": { - "description": "Card brand. Can be `interac`, `mastercard` or `visa`.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "cardholder_name": { - "description": "The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`).", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "country": { - "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "emv_auth_data": { - "description": "Authorization response cryptogram.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "exp_month": { - "description": "Two-digit number representing the card's expiration month.", - "type": "integer" - }, - "exp_year": { - "description": "Four-digit number representing the card's expiration year.", - "type": "integer" - }, - "fingerprint": { - "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "funding": { - "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "generated_card": { - "description": "ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "last4": { - "description": "The last four digits of the card.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "network": { - "description": "Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "preferred_locales": { - "description": "EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.", + "allowed_categories": { + "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.", "items": { - "maxLength": 5000, - "type": "string" - }, - "nullable": true, - "type": "array" - }, - "read_method": { - "description": "How card details were read in this transaction.", - "enum": [ - "contact_emv", - "contactless_emv", - "contactless_magstripe_mode", - "magnetic_stripe_fallback", - "magnetic_stripe_track2" - ], - "nullable": true, - "type": "string" - }, - "receipt": { - "anyOf": [ - { - "$ref": "#/components/schemas/payment_method_details_interac_present_receipt" - } - ], - "description": "A collection of fields required to be displayed on receipts. Only required for EMV transactions.", - "nullable": true - } - }, - "required": ["exp_month", "exp_year"], - "title": "payment_method_details_interac_present", - "type": "object", - "x-expandableFields": ["receipt"] - }, - "payment_method_details_interac_present_receipt": { - "description": "", - "properties": { - "account_type": { - "description": "The type of account being debited or credited", - "enum": ["checking", "savings", "unknown"], - "type": "string", - "x-stripeBypassValidation": true - }, - "application_cryptogram": { - "description": "EMV tag 9F26, cryptogram generated by the integrated circuit chip.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "application_preferred_name": { - "description": "Mnenomic of the Application Identifier.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "authorization_code": { - "description": "Identifier for this transaction.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "authorization_response_code": { - "description": "EMV tag 8A. A code returned by the card issuer.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "cardholder_verification_method": { - "description": "How the cardholder verified ownership of the card.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "dedicated_file_name": { - "description": "EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "terminal_verification_results": { - "description": "The outcome of a series of EMV functions performed by the card reader.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "transaction_status_information": { - "description": "An indication of various EMV functions performed during the transaction.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "payment_method_details_interac_present_receipt", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_klarna": { - "description": "", - "properties": {}, - "title": "payment_method_details_klarna", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_multibanco": { - "description": "", - "properties": { - "entity": { - "description": "Entity number associated with this Multibanco payment.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "reference": { - "description": "Reference number associated with this Multibanco payment.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "payment_method_details_multibanco", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_oxxo": { - "description": "", - "properties": { - "number": { - "description": "OXXO reference number", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "payment_method_details_oxxo", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_p24": { - "description": "", - "properties": { - "bank": { - "description": "The customer's bank. Can be one of `ing`, `citi_handlowy`, `tmobile_usbugi_bankowe`, `plus_bank`, `etransfer_pocztowy24`, `banki_spbdzielcze`, `bank_nowy_bfg_sa`, `getin_bank`, `blik`, `noble_pay`, `ideabank`, `envelobank`, `santander_przelew24`, `nest_przelew`, `mbank_mtransfer`, `inteligo`, `pbac_z_ipko`, `bnp_paribas`, `credit_agricole`, `toyota_bank`, `bank_pekao_sa`, `volkswagen_bank`, `bank_millennium`, `alior_bank`, or `boz`.", - "enum": [ - "alior_bank", - "bank_millennium", - "bank_nowy_bfg_sa", - "bank_pekao_sa", - "banki_spbdzielcze", - "blik", - "bnp_paribas", - "boz", - "citi_handlowy", - "credit_agricole", - "envelobank", - "etransfer_pocztowy24", - "getin_bank", - "ideabank", - "ing", - "inteligo", - "mbank_mtransfer", - "nest_przelew", - "noble_pay", - "pbac_z_ipko", - "plus_bank", - "santander_przelew24", - "tmobile_usbugi_bankowe", - "toyota_bank", - "volkswagen_bank" - ], - "nullable": true, - "type": "string" - }, - "reference": { - "description": "Unique reference for this Przelewy24 payment.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "verified_name": { - "description": "Owner's verified full name. Values are verified or provided by Przelewy24 directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.\nPrzelewy24 rarely provides this information so the attribute is usually empty.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "payment_method_details_p24", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_sepa_debit": { - "description": "", - "properties": { - "bank_code": { - "description": "Bank code of bank associated with the bank account.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "branch_code": { - "description": "Branch code of bank associated with the bank account.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "country": { - "description": "Two-letter ISO code representing the country the bank account is located in.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "fingerprint": { - "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", - "maxLength": 5000, + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "type": "string" + }, "nullable": true, - "type": "string" + "type": "array" }, - "last4": { - "description": "Last four characters of the IBAN.", - "maxLength": 5000, + "allowed_merchant_countries": { + "description": "Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.", + "items": { + "maxLength": 5000, + "type": "string" + }, "nullable": true, - "type": "string" + "type": "array" }, - "mandate": { - "description": "ID of the mandate used to make this payment.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "payment_method_details_sepa_debit", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_details_sofort": { - "description": "", - "properties": { - "bank_code": { - "description": "Bank code of bank associated with the bank account.", - "maxLength": 5000, + "blocked_categories": { + "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.", + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "type": "string" + }, "nullable": true, - "type": "string" + "type": "array" }, - "bank_name": { - "description": "Name of the bank associated with the bank account.", - "maxLength": 5000, + "blocked_merchant_countries": { + "description": "Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.", + "items": { + "maxLength": 5000, + "type": "string" + }, "nullable": true, - "type": "string" + "type": "array" }, - "bic": { - "description": "Bank Identifier Code of the bank associated with the bank account.", - "maxLength": 5000, + "spending_limits": { + "description": "Limit spending with amount-based rules that apply across this cardholder's cards.", + "items": { + "$ref": "#/components/schemas/issuing_cardholder_spending_limit" + }, "nullable": true, - "type": "string" + "type": "array" }, - "country": { - "description": "Two-letter ISO code representing the country the bank account is located in.", - "maxLength": 5000, + "spending_limits_currency": { + "description": "Currency of the amounts within `spending_limits`.", "nullable": true, "type": "string" - }, - "generated_sepa_debit": { + } + }, + "title": "IssuingCardholderAuthorizationControls", + "type": "object", + "x-expandableFields": ["spending_limits"] + }, + "issuing_cardholder_card_issuing": { + "description": "", + "properties": { + "user_terms_acceptance": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_cardholder_user_terms_acceptance" + } + ], + "description": "Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.", + "nullable": true + } + }, + "title": "IssuingCardholderCardIssuing", + "type": "object", + "x-expandableFields": ["user_terms_acceptance"] + }, + "issuing_cardholder_company": { + "description": "", + "properties": { + "tax_id_provided": { + "description": "Whether the company's business ID number was provided.", + "type": "boolean" + } + }, + "required": ["tax_id_provided"], + "title": "IssuingCardholderCompany", + "type": "object", + "x-expandableFields": [] + }, + "issuing_cardholder_id_document": { + "description": "", + "properties": { + "back": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/file" } ], - "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.", + "description": "The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/file" } ] } }, - "generated_sepa_debit_mandate": { + "front": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/mandate" + "$ref": "#/components/schemas/file" } ], - "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.", + "description": "The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/mandate" + "$ref": "#/components/schemas/file" } ] } + } + }, + "title": "IssuingCardholderIdDocument", + "type": "object", + "x-expandableFields": ["back", "front"] + }, + "issuing_cardholder_individual": { + "description": "", + "properties": { + "card_issuing": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_cardholder_card_issuing" + } + ], + "description": "Information related to the card_issuing program for this cardholder.", + "nullable": true }, - "iban_last4": { - "description": "Last four characters of the IBAN.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "dob": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_cardholder_individual_dob" + } + ], + "description": "The date of birth of this cardholder.", + "nullable": true }, - "preferred_language": { - "description": "Preferred language of the SOFORT authorization page that the customer is redirected to.\nCan be one of `de`, `en`, `es`, `fr`, `it`, `nl`, or `pl`", - "enum": ["de", "en", "es", "fr", "it", "nl", "pl"], + "first_name": { + "description": "The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "verified_name": { - "description": "Owner's verified full name. Values are verified or provided by SOFORT directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "last_name": { + "description": "The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.", "maxLength": 5000, "nullable": true, "type": "string" + }, + "verification": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_cardholder_verification" + } + ], + "description": "Government-issued ID document for this cardholder.", + "nullable": true } }, - "title": "payment_method_details_sofort", - "type": "object", - "x-expandableFields": [ - "generated_sepa_debit", - "generated_sepa_debit_mandate" - ] - }, - "payment_method_details_stripe_account": { - "description": "", - "properties": {}, - "title": "payment_method_details_stripe_account", + "title": "IssuingCardholderIndividual", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["card_issuing", "dob", "verification"] }, - "payment_method_details_wechat": { + "issuing_cardholder_individual_dob": { "description": "", - "properties": {}, - "title": "payment_method_details_wechat", + "properties": { + "day": { + "description": "The day of birth, between 1 and 31.", + "nullable": true, + "type": "integer" + }, + "month": { + "description": "The month of birth, between 1 and 12.", + "nullable": true, + "type": "integer" + }, + "year": { + "description": "The four-digit year of birth.", + "nullable": true, + "type": "integer" + } + }, + "title": "IssuingCardholderIndividualDOB", "type": "object", "x-expandableFields": [] }, - "payment_method_eps": { + "issuing_cardholder_requirements": { "description": "", "properties": { - "bank": { - "description": "The customer's bank. Should be one of `arzte_und_apotheker_bank`, `austrian_anadi_bank_ag`, `bank_austria`, `bankhaus_carl_spangler`, `bankhaus_schelhammer_und_schattera_ag`, `bawag_psk_ag`, `bks_bank_ag`, `brull_kallmus_bank_ag`, `btv_vier_lander_bank`, `capital_bank_grawe_gruppe_ag`, `dolomitenbank`, `easybank_ag`, `erste_bank_und_sparkassen`, `hypo_alpeadriabank_international_ag`, `hypo_noe_lb_fur_niederosterreich_u_wien`, `hypo_oberosterreich_salzburg_steiermark`, `hypo_tirol_bank_ag`, `hypo_vorarlberg_bank_ag`, `hypo_bank_burgenland_aktiengesellschaft`, `marchfelder_bank`, `oberbank_ag`, `raiffeisen_bankengruppe_osterreich`, `schoellerbank_ag`, `sparda_bank_wien`, `volksbank_gruppe`, `volkskreditbank_ag`, or `vr_bank_braunau`.", + "disabled_reason": { + "description": "If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason.", "enum": [ - "arzte_und_apotheker_bank", - "austrian_anadi_bank_ag", - "bank_austria", - "bankhaus_carl_spangler", - "bankhaus_schelhammer_und_schattera_ag", - "bawag_psk_ag", - "bks_bank_ag", - "brull_kallmus_bank_ag", - "btv_vier_lander_bank", - "capital_bank_grawe_gruppe_ag", - "dolomitenbank", - "easybank_ag", - "erste_bank_und_sparkassen", - "hypo_alpeadriabank_international_ag", - "hypo_bank_burgenland_aktiengesellschaft", - "hypo_noe_lb_fur_niederosterreich_u_wien", - "hypo_oberosterreich_salzburg_steiermark", - "hypo_tirol_bank_ag", - "hypo_vorarlberg_bank_ag", - "marchfelder_bank", - "oberbank_ag", - "raiffeisen_bankengruppe_osterreich", - "schoellerbank_ag", - "sparda_bank_wien", - "volksbank_gruppe", - "volkskreditbank_ag", - "vr_bank_braunau" + "listed", + "rejected.listed", + "requirements.past_due", + "under_review" ], "nullable": true, "type": "string" + }, + "past_due": { + "description": "Array of fields that need to be collected in order to verify and re-enable the cardholder.", + "items": { + "enum": [ + "company.tax_id", + "individual.card_issuing.user_terms_acceptance.date", + "individual.card_issuing.user_terms_acceptance.ip", + "individual.dob.day", + "individual.dob.month", + "individual.dob.year", + "individual.first_name", + "individual.last_name", + "individual.verification.document" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "nullable": true, + "type": "array" } }, - "title": "payment_method_eps", + "title": "IssuingCardholderRequirements", "type": "object", "x-expandableFields": [] }, - "payment_method_fpx": { + "issuing_cardholder_spending_limit": { "description": "", "properties": { - "bank": { - "description": "The customer's bank, if provided. Can be one of `affin_bank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `pb_enterprise`.", - "enum": [ - "affin_bank", - "alliance_bank", - "ambank", - "bank_islam", - "bank_muamalat", - "bank_rakyat", - "bsn", - "cimb", - "deutsche_bank", - "hong_leong_bank", - "hsbc", - "kfh", - "maybank2e", - "maybank2u", - "ocbc", - "pb_enterprise", - "public_bank", - "rhb", - "standard_chartered", - "uob" + "amount": { + "description": "Maximum amount allowed to spend per interval. This amount is in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "categories": { + "description": "Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.", + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "interval": { + "description": "Interval (or event) to which the amount applies.", + "enum": [ + "all_time", + "daily", + "monthly", + "per_authorization", + "weekly", + "yearly" ], "type": "string" } }, - "required": ["bank"], - "title": "payment_method_fpx", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_giropay": { - "description": "", - "properties": {}, - "title": "payment_method_giropay", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_grabpay": { - "description": "", - "properties": {}, - "title": "payment_method_grabpay", + "required": ["amount", "interval"], + "title": "IssuingCardholderSpendingLimit", "type": "object", "x-expandableFields": [] }, - "payment_method_ideal": { + "issuing_cardholder_user_terms_acceptance": { "description": "", "properties": { - "bank": { - "description": "The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, or `van_lanschot`.", - "enum": [ - "abn_amro", - "asn_bank", - "bunq", - "handelsbanken", - "ing", - "knab", - "moneyou", - "rabobank", - "regiobank", - "revolut", - "sns_bank", - "triodos_bank", - "van_lanschot" - ], + "date": { + "description": "The Unix timestamp marking when the cardholder accepted the Authorized User Terms.", + "format": "unix-time", "nullable": true, - "type": "string" + "type": "integer" }, - "bic": { - "description": "The Bank Identifier Code of the customer's bank, if the bank was provided.", - "enum": [ - "ABNANL2A", - "ASNBNL21", - "BUNQNL2A", - "FVLBNL22", - "HANDNL2A", - "INGBNL2A", - "KNABNL2H", - "MOYONL21", - "RABONL2U", - "RBRBNL21", - "REVOLT21", - "SNSBNL2A", - "TRIONL2U" - ], + "ip": { + "description": "The IP address from which the cardholder accepted the Authorized User Terms.", + "maxLength": 5000, "nullable": true, "type": "string" - } - }, - "title": "payment_method_ideal", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_interac_present": { - "description": "", - "properties": {}, - "title": "payment_method_interac_present", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_options_alipay": { - "description": "", - "properties": {}, - "title": "payment_method_options_alipay", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_options_bancontact": { - "description": "", - "properties": { - "preferred_language": { - "description": "Preferred language of the Bancontact authorization page that the customer is redirected to.", - "enum": ["de", "en", "fr", "nl"], + }, + "user_agent": { + "description": "The user agent of the browser from which the cardholder accepted the Authorized User Terms.", + "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["preferred_language"], - "title": "payment_method_options_bancontact", + "title": "IssuingCardholderUserTermsAcceptance", "type": "object", "x-expandableFields": [] }, - "payment_method_options_card_installments": { + "issuing_cardholder_verification": { "description": "", "properties": { - "available_plans": { - "description": "Installment plans that may be selected for this PaymentIntent.", - "items": { - "$ref": "#/components/schemas/payment_method_details_card_installments_plan" - }, - "nullable": true, - "type": "array" - }, - "enabled": { - "description": "Whether Installments are enabled for this PaymentIntent.", - "type": "boolean" - }, - "plan": { + "document": { "anyOf": [ { - "$ref": "#/components/schemas/payment_method_details_card_installments_plan" + "$ref": "#/components/schemas/issuing_cardholder_id_document" } ], - "description": "Installment plan selected for this PaymentIntent.", + "description": "An identifying document, either a passport or local ID card.", "nullable": true } }, - "required": ["enabled"], - "title": "payment_method_options_card_installments", + "title": "IssuingCardholderVerification", "type": "object", - "x-expandableFields": ["available_plans", "plan"] + "x-expandableFields": ["document"] }, - "payment_method_options_oxxo": { + "issuing_dispute_canceled_evidence": { "description": "", "properties": { - "expires_after_days": { - "description": "The number of calendar days before an OXXO invoice expires. For example, if you create an OXXO invoice on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.", + "additional_documentation": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } + }, + "canceled_at": { + "description": "Date when order was canceled.", + "format": "unix-time", + "nullable": true, "type": "integer" - } - }, - "required": ["expires_after_days"], - "title": "payment_method_options_oxxo", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_options_p24": { - "description": "", - "properties": {}, - "title": "payment_method_options_p24", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_options_sofort": { - "description": "", - "properties": { - "preferred_language": { - "description": "Preferred language of the SOFORT authorization page that the customer is redirected to.", - "enum": ["de", "en", "es", "fr", "it", "nl", "pl"], + }, + "cancellation_policy_provided": { + "description": "Whether the cardholder was provided with a cancellation policy.", + "nullable": true, + "type": "boolean" + }, + "cancellation_reason": { + "description": "Reason for canceling the order.", + "maxLength": 5000, "nullable": true, "type": "string" - } - }, - "title": "payment_method_options_sofort", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_oxxo": { - "description": "", - "properties": {}, - "title": "payment_method_oxxo", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_p24": { - "description": "", - "properties": { - "bank": { - "description": "The customer's bank, if provided.", - "enum": [ - "alior_bank", - "bank_millennium", - "bank_nowy_bfg_sa", - "bank_pekao_sa", - "banki_spbdzielcze", - "blik", - "bnp_paribas", - "boz", - "citi_handlowy", - "credit_agricole", - "envelobank", - "etransfer_pocztowy24", - "getin_bank", - "ideabank", - "ing", - "inteligo", - "mbank_mtransfer", - "nest_przelew", - "noble_pay", - "pbac_z_ipko", - "plus_bank", - "santander_przelew24", - "tmobile_usbugi_bankowe", - "toyota_bank", - "volkswagen_bank" - ], + }, + "expected_at": { + "description": "Date when the cardholder expected to receive the product.", + "format": "unix-time", "nullable": true, - "type": "string" - } - }, - "title": "payment_method_p24", - "type": "object", - "x-expandableFields": [] - }, - "payment_method_sepa_debit": { - "description": "", - "properties": { - "bank_code": { - "description": "Bank code of bank associated with the bank account.", + "type": "integer" + }, + "explanation": { + "description": "Explanation of why the cardholder is disputing this transaction.", "maxLength": 5000, "nullable": true, "type": "string" }, - "branch_code": { - "description": "Branch code of bank associated with the bank account.", + "product_description": { + "description": "Description of the merchandise or service that was purchased.", "maxLength": 5000, "nullable": true, "type": "string" }, - "country": { - "description": "Two-letter ISO code representing the country the bank account is located in.", - "maxLength": 5000, + "product_type": { + "description": "Whether the product was a merchandise or service.", + "enum": ["merchandise", "service"], "nullable": true, "type": "string" }, - "fingerprint": { - "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", - "maxLength": 5000, + "return_status": { + "description": "Result of cardholder's attempt to return the product.", + "enum": ["merchant_rejected", "successful"], "nullable": true, "type": "string" }, - "generated_from": { + "returned_at": { + "description": "Date when the product was returned or attempted to be returned.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "title": "IssuingDisputeCanceledEvidence", + "type": "object", + "x-expandableFields": ["additional_documentation"] + }, + "issuing_dispute_duplicate_evidence": { + "description": "", + "properties": { + "additional_documentation": { "anyOf": [ { - "$ref": "#/components/schemas/sepa_debit_generated_from" + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" } ], - "description": "Information about the object that generated this PaymentMethod.", - "nullable": true + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } }, - "last4": { - "description": "Last four characters of the IBAN.", + "card_statement": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } + }, + "cash_receipt": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } + }, + "check_image": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } + }, + "explanation": { + "description": "Explanation of why the cardholder is disputing this transaction.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "original_transaction": { + "description": "Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "payment_method_sepa_debit", + "title": "IssuingDisputeDuplicateEvidence", "type": "object", - "x-expandableFields": ["generated_from"] + "x-expandableFields": [ + "additional_documentation", + "card_statement", + "cash_receipt", + "check_image" + ] }, - "payment_method_sofort": { + "issuing_dispute_evidence": { "description": "", "properties": { - "country": { - "description": "Two-letter ISO code representing the country the bank account is located in.", + "canceled": { + "$ref": "#/components/schemas/issuing_dispute_canceled_evidence" + }, + "duplicate": { + "$ref": "#/components/schemas/issuing_dispute_duplicate_evidence" + }, + "fraudulent": { + "$ref": "#/components/schemas/issuing_dispute_fraudulent_evidence" + }, + "merchandise_not_as_described": { + "$ref": "#/components/schemas/issuing_dispute_merchandise_not_as_described_evidence" + }, + "no_valid_authorization": { + "$ref": "#/components/schemas/issuing_dispute_no_valid_authorization_evidence" + }, + "not_received": { + "$ref": "#/components/schemas/issuing_dispute_not_received_evidence" + }, + "other": { + "$ref": "#/components/schemas/issuing_dispute_other_evidence" + }, + "reason": { + "description": "The reason for filing the dispute. Its value will match the field containing the evidence.", + "enum": [ + "canceled", + "duplicate", + "fraudulent", + "merchandise_not_as_described", + "no_valid_authorization", + "not_received", + "other", + "service_not_as_described" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "service_not_as_described": { + "$ref": "#/components/schemas/issuing_dispute_service_not_as_described_evidence" + } + }, + "required": ["reason"], + "title": "IssuingDisputeEvidence", + "type": "object", + "x-expandableFields": [ + "canceled", + "duplicate", + "fraudulent", + "merchandise_not_as_described", + "no_valid_authorization", + "not_received", + "other", + "service_not_as_described" + ] + }, + "issuing_dispute_fraudulent_evidence": { + "description": "", + "properties": { + "additional_documentation": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } + }, + "explanation": { + "description": "Explanation of why the cardholder is disputing this transaction.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "payment_method_sofort", + "title": "IssuingDisputeFraudulentEvidence", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["additional_documentation"] }, - "payment_pages_checkout_session_customer_details": { + "issuing_dispute_merchandise_not_as_described_evidence": { "description": "", "properties": { - "email": { - "description": "The customer’s email at time of checkout.", + "additional_documentation": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } + }, + "explanation": { + "description": "Explanation of why the cardholder is disputing this transaction.", "maxLength": 5000, "nullable": true, "type": "string" }, - "tax_exempt": { - "description": "The customer’s tax exempt status at time of checkout.", - "enum": ["exempt", "none", "reverse"], + "received_at": { + "description": "Date when the product was received.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "return_description": { + "description": "Description of the cardholder's attempt to return the product.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "tax_ids": { - "description": "The customer’s tax IDs at time of checkout.", - "items": { - "$ref": "#/components/schemas/payment_pages_checkout_session_tax_id" - }, + "return_status": { + "description": "Result of cardholder's attempt to return the product.", + "enum": ["merchant_rejected", "successful"], "nullable": true, - "type": "array" + "type": "string" + }, + "returned_at": { + "description": "Date when the product was returned or attempted to be returned.", + "format": "unix-time", + "nullable": true, + "type": "integer" } }, - "title": "PaymentPagesCheckoutSessionCustomerDetails", + "title": "IssuingDisputeMerchandiseNotAsDescribedEvidence", "type": "object", - "x-expandableFields": ["tax_ids"] + "x-expandableFields": ["additional_documentation"] }, - "payment_pages_checkout_session_tax_id": { + "issuing_dispute_no_valid_authorization_evidence": { "description": "", "properties": { - "type": { - "description": "The type of the tax ID, one of `eu_vat`, `br_cnpj`, `br_cpf`, `gb_vat`, `nz_gst`, `au_abn`, `in_gst`, `no_vat`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, or `unknown`", - "enum": [ - "ae_trn", - "au_abn", - "br_cnpj", - "br_cpf", - "ca_bn", - "ca_qst", - "ch_vat", - "cl_tin", - "es_cif", - "eu_vat", - "gb_vat", - "hk_br", - "id_npwp", - "in_gst", - "jp_cn", - "jp_rn", - "kr_brn", - "li_uid", - "mx_rfc", - "my_frp", - "my_itn", - "my_sst", - "no_vat", - "nz_gst", - "ru_inn", - "ru_kpp", - "sa_vat", - "sg_gst", - "sg_uen", - "th_vat", - "tw_vat", - "unknown", - "us_ein", - "za_vat" + "additional_documentation": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } ], - "type": "string" + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } }, - "value": { - "description": "The value of the tax ID.", + "explanation": { + "description": "Explanation of why the cardholder is disputing this transaction.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "required": ["type"], - "title": "PaymentPagesCheckoutSessionTaxID", + "title": "IssuingDisputeNoValidAuthorizationEvidence", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["additional_documentation"] }, - "payment_pages_checkout_session_total_details": { + "issuing_dispute_not_received_evidence": { "description": "", "properties": { - "amount_discount": { - "description": "This is the sum of all the line item discounts.", - "type": "integer" + "additional_documentation": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } }, - "amount_shipping": { - "description": "This is the sum of all the line item shipping amounts.", + "expected_at": { + "description": "Date when the cardholder expected to receive the product.", + "format": "unix-time", "nullable": true, "type": "integer" }, - "amount_tax": { - "description": "This is the sum of all the line item tax amounts.", - "type": "integer" + "explanation": { + "description": "Explanation of why the cardholder is disputing this transaction.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "breakdown": { - "$ref": "#/components/schemas/payment_pages_checkout_session_total_details_resource_breakdown" + "product_description": { + "description": "Description of the merchandise or service that was purchased.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "product_type": { + "description": "Whether the product was a merchandise or service.", + "enum": ["merchandise", "service"], + "nullable": true, + "type": "string" } }, - "required": ["amount_discount", "amount_tax"], - "title": "PaymentPagesCheckoutSessionTotalDetails", + "title": "IssuingDisputeNotReceivedEvidence", "type": "object", - "x-expandableFields": ["breakdown"] + "x-expandableFields": ["additional_documentation"] }, - "payment_pages_checkout_session_total_details_resource_breakdown": { + "issuing_dispute_other_evidence": { "description": "", "properties": { - "discounts": { - "description": "The aggregated line item discounts.", - "items": { - "$ref": "#/components/schemas/line_items_discount_amount" - }, - "type": "array" + "additional_documentation": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } }, - "taxes": { - "description": "The aggregated line item tax amounts by rate.", - "items": { - "$ref": "#/components/schemas/line_items_tax_amount" - }, - "type": "array" + "explanation": { + "description": "Explanation of why the cardholder is disputing this transaction.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "product_description": { + "description": "Description of the merchandise or service that was purchased.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "product_type": { + "description": "Whether the product was a merchandise or service.", + "enum": ["merchandise", "service"], + "nullable": true, + "type": "string" } }, - "required": ["discounts", "taxes"], - "title": "PaymentPagesCheckoutSessionTotalDetailsResourceBreakdown", + "title": "IssuingDisputeOtherEvidence", "type": "object", - "x-expandableFields": ["discounts", "taxes"] + "x-expandableFields": ["additional_documentation"] }, - "payment_pages_payment_page_resources_shipping_address_collection": { + "issuing_dispute_service_not_as_described_evidence": { "description": "", "properties": { - "allowed_countries": { - "description": "An array of two-letter ISO country codes representing which countries Checkout should provide as options for\nshipping locations. Unsupported country codes: `AS, CX, CC, CU, HM, IR, KP, MH, FM, NF, MP, PW, SD, SY, UM, VI`.", - "items": { - "enum": [ - "AC", - "AD", - "AE", - "AF", - "AG", - "AI", - "AL", - "AM", - "AO", - "AQ", - "AR", - "AT", - "AU", - "AW", - "AX", - "AZ", - "BA", - "BB", - "BD", - "BE", - "BF", - "BG", - "BH", - "BI", - "BJ", - "BL", - "BM", - "BN", - "BO", - "BQ", - "BR", - "BS", - "BT", - "BV", - "BW", - "BY", - "BZ", - "CA", - "CD", - "CF", - "CG", - "CH", - "CI", - "CK", - "CL", - "CM", - "CN", - "CO", - "CR", - "CV", - "CW", - "CY", - "CZ", - "DE", - "DJ", - "DK", - "DM", - "DO", - "DZ", - "EC", - "EE", - "EG", - "EH", - "ER", - "ES", - "ET", - "FI", - "FJ", - "FK", - "FO", - "FR", - "GA", - "GB", - "GD", - "GE", - "GF", - "GG", - "GH", - "GI", - "GL", - "GM", - "GN", - "GP", - "GQ", - "GR", - "GS", - "GT", - "GU", - "GW", - "GY", - "HK", - "HN", - "HR", - "HT", - "HU", - "ID", - "IE", - "IL", - "IM", - "IN", - "IO", - "IQ", - "IS", - "IT", - "JE", - "JM", - "JO", - "JP", - "KE", - "KG", - "KH", - "KI", - "KM", - "KN", - "KR", - "KW", - "KY", - "KZ", - "LA", - "LB", - "LC", - "LI", - "LK", - "LR", - "LS", - "LT", - "LU", - "LV", - "LY", - "MA", - "MC", - "MD", - "ME", - "MF", - "MG", - "MK", - "ML", - "MM", - "MN", - "MO", - "MQ", - "MR", - "MS", - "MT", - "MU", - "MV", - "MW", - "MX", - "MY", - "MZ", - "NA", - "NC", - "NE", - "NG", - "NI", - "NL", - "NO", - "NP", - "NR", - "NU", - "NZ", - "OM", - "PA", - "PE", - "PF", - "PG", - "PH", - "PK", - "PL", - "PM", - "PN", - "PR", - "PS", - "PT", - "PY", - "QA", - "RE", - "RO", - "RS", - "RU", - "RW", - "SA", - "SB", - "SC", - "SE", - "SG", - "SH", - "SI", - "SJ", - "SK", - "SL", - "SM", - "SN", - "SO", - "SR", - "SS", - "ST", - "SV", - "SX", - "SZ", - "TA", - "TC", - "TD", - "TF", - "TG", - "TH", - "TJ", - "TK", - "TL", - "TM", - "TN", - "TO", - "TR", - "TT", - "TV", - "TW", - "TZ", - "UA", - "UG", - "US", - "UY", - "UZ", - "VA", - "VC", - "VE", - "VG", - "VN", - "VU", - "WF", - "WS", - "XK", - "YE", - "YT", - "ZA", - "ZM", - "ZW", - "ZZ" - ], - "type": "string" - }, - "type": "array" - } - }, - "required": ["allowed_countries"], - "title": "PaymentPagesPaymentPageResourcesShippingAddressCollection", - "type": "object", - "x-expandableFields": [] - }, - "payment_source": { - "anyOf": [ - { - "$ref": "#/components/schemas/account" - }, - { - "$ref": "#/components/schemas/alipay_account" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/source" - } - ], - "title": "Polymorphic", - "x-resourceId": "payment_source" - }, - "payout": { - "description": "A `Payout` object is created when you receive funds from Stripe, or when you\ninitiate a payout to either a bank account or debit card of a [connected\nStripe account](/docs/connect/bank-debit-card-payouts). You can retrieve individual payouts,\nas well as list all payouts. Payouts are made on [varying\nschedules](/docs/connect/manage-payout-schedule), depending on your country and\nindustry.\n\nRelated guide: [Receiving Payouts](https://stripe.com/docs/payouts).", - "properties": { - "amount": { - "description": "Amount (in %s) to be transferred to your bank account or debit card.", - "type": "integer" - }, - "arrival_date": { - "description": "Date the payout is expected to arrive in the bank. This factors in delays like weekends or bank holidays.", - "format": "unix-time", - "type": "integer" - }, - "automatic": { - "description": "Returns `true` if the payout was created by an [automated payout schedule](https://stripe.com/docs/payouts#payout-schedule), and `false` if it was [requested manually](https://stripe.com/docs/payouts#manual-payouts).", - "type": "boolean" - }, - "balance_transaction": { + "additional_documentation": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/file" } ], - "description": "ID of the balance transaction that describes the impact of this payout on your account balance.", + "description": "(ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/file" } ] } }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "canceled_at": { + "description": "Date when order was canceled.", "format": "unix-time", + "nullable": true, "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "cancellation_reason": { + "description": "Reason for canceling the order.", "maxLength": 5000, "nullable": true, "type": "string" }, - "destination": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/deleted_bank_account" - }, - { - "$ref": "#/components/schemas/deleted_card" - } - ], - "description": "ID of the bank account or card the payout was sent to.", + "explanation": { + "description": "Explanation of why the cardholder is disputing this transaction.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/deleted_bank_account" - }, - { - "$ref": "#/components/schemas/deleted_card" - } - ] - } + "type": "string" }, - "failure_balance_transaction": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/balance_transaction" - } - ], - "description": "If the payout failed or was canceled, this will be the ID of the balance transaction that reversed the initial balance transaction, and puts the funds from the failed payout back in your balance.", + "received_at": { + "description": "Date when the product was received.", + "format": "unix-time", "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/balance_transaction" - } - ] - } - }, - "failure_code": { - "description": "Error code explaining reason for payout failure if available. See [Types of payout failures](https://stripe.com/docs/api#payout_failures) for a list of failure codes.", + "type": "integer" + } + }, + "title": "IssuingDisputeServiceNotAsDescribedEvidence", + "type": "object", + "x-expandableFields": ["additional_documentation"] + }, + "issuing_dispute_treasury": { + "description": "", + "properties": { + "debit_reversal": { + "description": "The Treasury [DebitReversal](https://stripe.com/docs/api/treasury/debit_reversals) representing this Issuing dispute", "maxLength": 5000, "nullable": true, "type": "string" }, - "failure_message": { - "description": "Message to user further explaining reason for payout failure if available.", + "received_debit": { + "description": "The Treasury [ReceivedDebit](https://stripe.com/docs/api/treasury/received_debits) that is being disputed.", "maxLength": 5000, - "nullable": true, "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", + } + }, + "required": ["received_debit"], + "title": "IssuingDisputeTreasury", + "type": "object", + "x-expandableFields": [] + }, + "issuing_network_token_address": { + "description": "", + "properties": { + "line1": { + "description": "The street address of the cardholder tokenizing the card.", "maxLength": 5000, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, - "type": "object" + "postal_code": { + "description": "The postal code of the cardholder tokenizing the card.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["line1", "postal_code"], + "title": "IssuingNetworkTokenAddress", + "type": "object", + "x-expandableFields": [] + }, + "issuing_network_token_device": { + "description": "", + "properties": { + "device_fingerprint": { + "description": "An obfuscated ID derived from the device ID.", + "maxLength": 5000, + "type": "string" }, - "method": { - "description": "The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces](https://stripe.com/blog/instant-payouts-for-marketplaces) for more information.)", + "ip_address": { + "description": "The IP address of the device at provisioning time.", "maxLength": 5000, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["payout"], + "location": { + "description": "The geographic latitude/longitude coordinates of the device at provisioning time. The format is [+-]decimal/[+-]decimal.", + "maxLength": 5000, "type": "string" }, - "original_payout": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payout" - } - ], - "description": "If the payout reverses another, this is the ID of the original payout.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payout" - } - ] - } + "name": { + "description": "The name of the device used for tokenization.", + "maxLength": 5000, + "type": "string" }, - "reversed_by": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payout" - } - ], - "description": "If the payout was reversed, this is the ID of the payout that reverses this payout.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payout" - } - ] - } + "phone_number": { + "description": "The phone number of the device used for tokenization.", + "maxLength": 5000, + "type": "string" }, - "source_type": { - "description": "The source balance this payout came from. One of `card`, `fpx`, or `bank_account`.", + "type": { + "description": "The type of device used for tokenization.", + "enum": ["other", "phone", "watch"], + "type": "string" + } + }, + "title": "IssuingNetworkTokenDevice", + "type": "object", + "x-expandableFields": [] + }, + "issuing_network_token_mastercard": { + "description": "", + "properties": { + "card_reference_id": { + "description": "A unique reference ID from MasterCard to represent the card account number.", "maxLength": 5000, "type": "string" }, - "statement_descriptor": { - "description": "Extra information about a payout to be displayed on the user's bank statement.", + "token_reference_id": { + "description": "The network-unique identifier for the token.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "status": { - "description": "Current status of the payout: `paid`, `pending`, `in_transit`, `canceled` or `failed`. A payout is `pending` until it is submitted to the bank, when it becomes `in_transit`. The status then changes to `paid` if the transaction goes through, or to `failed` or `canceled` (within 5 business days). Some failed payouts may initially show as `paid` but then change to `failed`.", + "token_requestor_id": { + "description": "The ID of the entity requesting tokenization, specific to MasterCard.", "maxLength": 5000, "type": "string" }, - "type": { - "description": "Can be `bank_account` or `card`.", - "enum": ["bank_account", "card"], + "token_requestor_name": { + "description": "The name of the entity requesting tokenization, if known. This is directly provided from MasterCard.", + "maxLength": 5000, "type": "string" } }, - "required": [ - "amount", - "arrival_date", - "automatic", - "created", - "currency", - "id", - "livemode", - "method", - "object", - "source_type", - "status", - "type" - ], - "title": "Payout", + "required": ["token_reference_id", "token_requestor_id"], + "title": "IssuingNetworkTokenMastercard", "type": "object", - "x-expandableFields": [ - "balance_transaction", - "destination", - "failure_balance_transaction", - "original_payout", - "reversed_by" - ], - "x-resourceId": "payout" + "x-expandableFields": [] }, - "period": { + "issuing_network_token_network_data": { "description": "", "properties": { - "end": { - "description": "The end date of this usage period. All usage up to and including this point in time is included.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "device": { + "$ref": "#/components/schemas/issuing_network_token_device" }, - "start": { - "description": "The start date of this usage period. All usage after this point in time is included.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "mastercard": { + "$ref": "#/components/schemas/issuing_network_token_mastercard" + }, + "type": { + "description": "The network that the token is associated with. An additional hash is included with a name matching this value, containing tokenization data specific to the card network.", + "enum": ["mastercard", "visa"], + "type": "string" + }, + "visa": { + "$ref": "#/components/schemas/issuing_network_token_visa" + }, + "wallet_provider": { + "$ref": "#/components/schemas/issuing_network_token_wallet_provider" } }, - "title": "Period", + "required": ["type"], + "title": "IssuingNetworkTokenNetworkData", "type": "object", - "x-expandableFields": [] + "x-expandableFields": [ + "device", + "mastercard", + "visa", + "wallet_provider" + ] }, - "person": { - "description": "This is an object representing a person associated with a Stripe account.\n\nA platform cannot access a Standard or Express account's persons after the account starts onboarding, such as after generating an account link for the account.\nSee the [Standard onboarding](https://stripe.com/docs/connect/standard-accounts) or [Express onboarding documentation](https://stripe.com/docs/connect/express-accounts) for information about platform pre-filling and account onboarding steps.\n\nRelated guide: [Handling Identity Verification with the API](https://stripe.com/docs/connect/identity-verification-api#person-information).", + "issuing_network_token_visa": { + "description": "", "properties": { - "account": { - "description": "The account the person is associated with.", + "card_reference_id": { + "description": "A unique reference ID from Visa to represent the card account number.", "maxLength": 5000, "type": "string" }, - "address": { - "$ref": "#/components/schemas/address" + "token_reference_id": { + "description": "The network-unique identifier for the token.", + "maxLength": 5000, + "type": "string" }, - "address_kana": { - "anyOf": [ - { - "$ref": "#/components/schemas/legal_entity_japan_address" - } - ], - "nullable": true - }, - "address_kanji": { - "anyOf": [ - { - "$ref": "#/components/schemas/legal_entity_japan_address" - } - ], - "nullable": true - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "dob": { - "$ref": "#/components/schemas/legal_entity_dob" - }, - "email": { - "description": "The person's email address.", + "token_requestor_id": { + "description": "The ID of the entity requesting tokenization, specific to Visa.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "first_name": { - "description": "The person's first name.", + "token_risk_score": { + "description": "Degree of risk associated with the token between `01` and `99`, with higher number indicating higher risk. A `00` value indicates the token was not scored by Visa.", "maxLength": 5000, - "nullable": true, "type": "string" - }, - "first_name_kana": { - "description": "The Kana variation of the person's first name (Japan only).", + } + }, + "required": [ + "card_reference_id", + "token_reference_id", + "token_requestor_id" + ], + "title": "IssuingNetworkTokenVisa", + "type": "object", + "x-expandableFields": [] + }, + "issuing_network_token_wallet_provider": { + "description": "", + "properties": { + "account_id": { + "description": "The wallet provider-given account ID of the digital wallet the token belongs to.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "first_name_kanji": { - "description": "The Kanji variation of the person's first name (Japan only).", - "maxLength": 5000, - "nullable": true, - "type": "string" + "account_trust_score": { + "description": "An evaluation on the trustworthiness of the wallet account between 1 and 5. A higher score indicates more trustworthy.", + "type": "integer" }, - "gender": { - "description": "The person's gender (International regulations require either \"male\" or \"female\").", - "nullable": true, + "card_number_source": { + "description": "The method used for tokenizing a card.", + "enum": ["app", "manual", "on_file", "other"], "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "cardholder_address": { + "$ref": "#/components/schemas/issuing_network_token_address" + }, + "cardholder_name": { + "description": "The name of the cardholder tokenizing the card.", "maxLength": 5000, "type": "string" }, - "id_number_provided": { - "description": "Whether the person's `id_number` was provided.", - "type": "boolean" + "device_trust_score": { + "description": "An evaluation on the trustworthiness of the device. A higher score indicates more trustworthy.", + "type": "integer" }, - "last_name": { - "description": "The person's last name.", + "hashed_account_email_address": { + "description": "The hashed email address of the cardholder's account with the wallet provider.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "last_name_kana": { - "description": "The Kana variation of the person's last name (Japan only).", - "maxLength": 5000, - "nullable": true, + "reason_codes": { + "description": "The reasons for suggested tokenization given by the card network.", + "items": { + "enum": [ + "account_card_too_new", + "account_recently_changed", + "account_too_new", + "account_too_new_since_launch", + "additional_device", + "data_expired", + "defer_id_v_decision", + "device_recently_lost", + "good_activity_history", + "has_suspended_tokens", + "high_risk", + "inactive_account", + "long_account_tenure", + "low_account_score", + "low_device_score", + "low_phone_number_score", + "network_service_error", + "outside_home_territory", + "provisioning_cardholder_mismatch", + "provisioning_device_and_cardholder_mismatch", + "provisioning_device_mismatch", + "same_device_no_prior_authentication", + "same_device_successful_prior_authentication", + "software_update", + "suspicious_activity", + "too_many_different_cardholders", + "too_many_recent_attempts", + "too_many_recent_tokens" + ], + "type": "string" + }, + "type": "array" + }, + "suggested_decision": { + "description": "The recommendation on responding to the tokenization request.", + "enum": ["approve", "decline", "require_auth"], "type": "string" }, - "last_name_kanji": { - "description": "The Kanji variation of the person's last name (Japan only).", + "suggested_decision_version": { + "description": "The version of the standard for mapping reason codes followed by the wallet provider.", "maxLength": 5000, - "nullable": true, "type": "string" - }, - "maiden_name": { - "description": "The person's maiden name.", + } + }, + "title": "IssuingNetworkTokenWalletProvider", + "type": "object", + "x-expandableFields": ["cardholder_address"] + }, + "issuing_personalization_design_carrier_text": { + "description": "", + "properties": { + "footer_body": { + "description": "The footer body text of the carrier letter.", "maxLength": 5000, "nullable": true, "type": "string" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "nationality": { - "description": "The country where the person is a national.", + "footer_title": { + "description": "The footer title text of the carrier letter.", "maxLength": 5000, "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["person"], - "type": "string" - }, - "phone": { - "description": "The person's phone number.", + "header_body": { + "description": "The header body text of the carrier letter.", "maxLength": 5000, "nullable": true, "type": "string" }, - "political_exposure": { - "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", - "enum": ["existing", "none"], + "header_title": { + "description": "The header title text of the carrier letter.", + "maxLength": 5000, + "nullable": true, "type": "string" - }, - "relationship": { - "$ref": "#/components/schemas/person_relationship" - }, - "requirements": { - "anyOf": [ - { - "$ref": "#/components/schemas/person_requirements" - } - ], - "nullable": true - }, - "ssn_last_4_provided": { - "description": "Whether the last four digits of the person's Social Security number have been provided (U.S. only).", - "type": "boolean" - }, - "verification": { - "$ref": "#/components/schemas/legal_entity_person_verification" } }, - "required": ["account", "created", "id", "object"], - "title": "Person", + "title": "IssuingPersonalizationDesignCarrierText", "type": "object", - "x-expandableFields": [ - "address", - "address_kana", - "address_kanji", - "dob", - "relationship", - "requirements", - "verification" - ], - "x-resourceId": "person" + "x-expandableFields": [] }, - "person_relationship": { + "issuing_personalization_design_preferences": { "description": "", "properties": { - "director": { - "description": "Whether the person is a director of the account's legal entity. Currently only required for accounts in the EU. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.", - "nullable": true, - "type": "boolean" - }, - "executive": { - "description": "Whether the person has significant responsibility to control, manage, or direct the organization.", - "nullable": true, - "type": "boolean" - }, - "owner": { - "description": "Whether the person is an owner of the account’s legal entity.", - "nullable": true, + "is_default": { + "description": "Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.", "type": "boolean" }, - "percent_ownership": { - "description": "The percent owned by the person of the account's legal entity.", - "nullable": true, - "type": "number" - }, - "representative": { - "description": "Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.", + "is_platform_default": { + "description": "Whether this personalization design is used to create cards when one is not specified and a default for this connected account does not exist.", "nullable": true, "type": "boolean" - }, - "title": { - "description": "The person's title (e.g., CEO, Support Engineer).", - "maxLength": 5000, - "nullable": true, - "type": "string" } }, - "title": "PersonRelationship", + "required": ["is_default"], + "title": "IssuingPersonalizationDesignPreferences", "type": "object", "x-expandableFields": [] }, - "person_requirements": { + "issuing_personalization_design_rejection_reasons": { "description": "", "properties": { - "currently_due": { - "description": "Fields that need to be collected to keep the person's account enabled. If not collected by the account's `current_deadline`, these fields appear in `past_due` as well, and the account is disabled.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "errors": { - "description": "The fields that are `currently_due` and need to be collected again because validation or verification failed for some reason.", - "items": { - "$ref": "#/components/schemas/account_requirements_error" - }, - "type": "array" - }, - "eventually_due": { - "description": "Fields that need to be collected assuming all volume thresholds are reached. As fields are needed, they are moved to `currently_due` and the account's `current_deadline` is set.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "past_due": { - "description": "Fields that weren't collected by the account's `current_deadline`. These fields need to be collected to enable payouts for the person's account.", + "card_logo": { + "description": "The reason(s) the card logo was rejected.", "items": { - "maxLength": 5000, + "enum": [ + "geographic_location", + "inappropriate", + "network_name", + "non_binary_image", + "non_fiat_currency", + "other", + "other_entity", + "promotional_material" + ], "type": "string" }, + "nullable": true, "type": "array" }, - "pending_verification": { - "description": "Fields that may become required depending on the results of verification or review. An empty array unless an asynchronous verification is pending. If verification fails, the fields in this array become required and move to `currently_due` or `past_due`.", + "carrier_text": { + "description": "The reason(s) the carrier text was rejected.", "items": { - "maxLength": 5000, + "enum": [ + "geographic_location", + "inappropriate", + "network_name", + "non_fiat_currency", + "other", + "other_entity", + "promotional_material" + ], "type": "string" }, + "nullable": true, "type": "array" } }, - "required": [ - "currently_due", - "errors", - "eventually_due", - "past_due", - "pending_verification" - ], - "title": "PersonRequirements", + "title": "IssuingPersonalizationDesignRejectionReasons", "type": "object", - "x-expandableFields": ["errors"] + "x-expandableFields": [] }, - "plan": { - "description": "You can now model subscriptions more flexibly using the [Prices API](https://stripe.com/docs/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration.\n\nPlans define the base price, currency, and billing cycle for recurring purchases of products.\n[Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and plans help you track pricing. Different physical goods or levels of service should be represented by products, and pricing options should be represented by plans. This approach lets you change prices without having to change your provisioning scheme.\n\nFor example, you might have a single \"gold\" product that has plans for $10/month, $100/year, €9/month, and €90/year.\n\nRelated guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/billing/prices-guide).", + "issuing_physical_bundle_features": { + "description": "", "properties": { - "active": { - "description": "Whether the plan can be used for new purchases.", - "type": "boolean" + "card_logo": { + "description": "The policy for how to use card logo images in a card design with this physical bundle.", + "enum": ["optional", "required", "unsupported"], + "type": "string" }, - "aggregate_usage": { - "description": "Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`.", - "enum": ["last_during_period", "last_ever", "max", "sum"], - "nullable": true, + "carrier_text": { + "description": "The policy for how to use carrier letter text in a card design with this physical bundle.", + "enum": ["optional", "required", "unsupported"], "type": "string" }, - "amount": { - "description": "The unit amount in %s to be charged, represented as a whole integer if possible. Only set if `billing_scheme=per_unit`.", + "second_line": { + "description": "The policy for how to use a second line on a card with this physical bundle.", + "enum": ["optional", "required", "unsupported"], + "type": "string" + } + }, + "required": ["card_logo", "carrier_text", "second_line"], + "title": "IssuingPhysicalBundleFeatures", + "type": "object", + "x-expandableFields": [] + }, + "issuing_transaction_amount_details": { + "description": "", + "properties": { + "atm_fee": { + "description": "The fee charged by the ATM for the cash withdrawal.", "nullable": true, "type": "integer" }, - "amount_decimal": { - "description": "The unit amount in %s to be charged, represented as a decimal string with at most 12 decimal places. Only set if `billing_scheme=per_unit`.", - "format": "decimal", + "cashback_amount": { + "description": "The amount of cash requested by the cardholder.", "nullable": true, - "type": "string" - }, - "billing_scheme": { - "description": "Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.", - "enum": ["per_unit", "tiered"], - "type": "string" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", + } + }, + "title": "IssuingTransactionAmountDetails", + "type": "object", + "x-expandableFields": [] + }, + "issuing_transaction_fleet_cardholder_prompt_data": { + "description": "", + "properties": { + "driver_id": { + "description": "Driver ID.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "interval": { - "description": "The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.", - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "description": "The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months.", + "odometer": { + "description": "Odometer reading.", + "nullable": true, "type": "integer" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "unspecified_id": { + "description": "An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.", + "maxLength": 5000, "nullable": true, - "type": "object" + "type": "string" }, - "nickname": { - "description": "A brief description of the plan, hidden from customers.", + "user_id": { + "description": "User ID.", "maxLength": 5000, "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["plan"], + "vehicle_number": { + "description": "Vehicle number.", + "maxLength": 5000, + "nullable": true, "type": "string" - }, - "product": { + } + }, + "title": "IssuingTransactionFleetCardholderPromptData", + "type": "object", + "x-expandableFields": [] + }, + "issuing_transaction_fleet_data": { + "description": "", + "properties": { + "cardholder_prompt_data": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/product" - }, - { - "$ref": "#/components/schemas/deleted_product" + "$ref": "#/components/schemas/issuing_transaction_fleet_cardholder_prompt_data" } ], - "description": "The product whose pricing this plan determines.", + "description": "Answers to prompts presented to cardholder at point of sale.", + "nullable": true + }, + "purchase_type": { + "description": "The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/product" - }, - { - "$ref": "#/components/schemas/deleted_product" - } - ] - } + "type": "string" }, - "tiers": { - "description": "Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.", - "items": { - "$ref": "#/components/schemas/plan_tier" - }, - "type": "array" + "reported_breakdown": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_transaction_fleet_reported_breakdown" + } + ], + "description": "More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.", + "nullable": true }, - "tiers_mode": { - "description": "Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows.", - "enum": ["graduated", "volume"], + "service_type": { + "description": "The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "IssuingTransactionFleetData", + "type": "object", + "x-expandableFields": ["cardholder_prompt_data", "reported_breakdown"] + }, + "issuing_transaction_fleet_fuel_price_data": { + "description": "", + "properties": { + "gross_amount_decimal": { + "description": "Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.", + "format": "decimal", + "nullable": true, + "type": "string" + } + }, + "title": "IssuingTransactionFleetFuelPriceData", + "type": "object", + "x-expandableFields": [] + }, + "issuing_transaction_fleet_non_fuel_price_data": { + "description": "", + "properties": { + "gross_amount_decimal": { + "description": "Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.", + "format": "decimal", "nullable": true, "type": "string" + } + }, + "title": "IssuingTransactionFleetNonFuelPriceData", + "type": "object", + "x-expandableFields": [] + }, + "issuing_transaction_fleet_reported_breakdown": { + "description": "", + "properties": { + "fuel": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_transaction_fleet_fuel_price_data" + } + ], + "description": "Breakdown of fuel portion of the purchase.", + "nullable": true }, - "transform_usage": { + "non_fuel": { "anyOf": [ { - "$ref": "#/components/schemas/transform_usage" + "$ref": "#/components/schemas/issuing_transaction_fleet_non_fuel_price_data" } ], - "description": "Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with `tiers`.", + "description": "Breakdown of non-fuel portion of the purchase.", "nullable": true }, - "trial_period_days": { - "description": "Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).", + "tax": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_transaction_fleet_tax_data" + } + ], + "description": "Information about tax included in this transaction.", + "nullable": true + } + }, + "title": "IssuingTransactionFleetReportedBreakdown", + "type": "object", + "x-expandableFields": ["fuel", "non_fuel", "tax"] + }, + "issuing_transaction_fleet_tax_data": { + "description": "", + "properties": { + "local_amount_decimal": { + "description": "Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.", + "format": "decimal", "nullable": true, - "type": "integer" + "type": "string" }, - "usage_type": { - "description": "Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.", - "enum": ["licensed", "metered"], + "national_amount_decimal": { + "description": "Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.", + "format": "decimal", + "nullable": true, "type": "string" } }, - "required": [ - "active", - "billing_scheme", - "created", - "currency", - "id", - "interval", - "interval_count", - "livemode", - "object", - "usage_type" - ], - "title": "Plan", + "title": "IssuingTransactionFleetTaxData", "type": "object", - "x-expandableFields": ["product", "tiers", "transform_usage"], - "x-resourceId": "plan" + "x-expandableFields": [] }, - "plan_tier": { + "issuing_transaction_flight_data": { "description": "", "properties": { - "flat_amount": { - "description": "Price for the entire tier.", + "departure_at": { + "description": "The time that the flight departed.", "nullable": true, "type": "integer" }, - "flat_amount_decimal": { - "description": "Same as `flat_amount`, but contains a decimal value with at most 12 decimal places.", - "format": "decimal", + "passenger_name": { + "description": "The name of the passenger.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "unit_amount": { - "description": "Per unit price for units relevant to the tier.", + "refundable": { + "description": "Whether the ticket is refundable.", "nullable": true, - "type": "integer" + "type": "boolean" }, - "unit_amount_decimal": { - "description": "Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.", - "format": "decimal", + "segments": { + "description": "The legs of the trip.", + "items": { + "$ref": "#/components/schemas/issuing_transaction_flight_data_leg" + }, "nullable": true, - "type": "string" + "type": "array" }, - "up_to": { - "description": "Up to and including to this quantity will be contained in the tier.", + "travel_agency": { + "description": "The travel agency that issued the ticket.", + "maxLength": 5000, "nullable": true, - "type": "integer" + "type": "string" } }, - "title": "PlanTier", + "title": "IssuingTransactionFlightData", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["segments"] }, - "platform_tax_fee": { + "issuing_transaction_flight_data_leg": { "description": "", "properties": { - "account": { - "description": "The Connected account that incurred this charge.", + "arrival_airport_code": { + "description": "The three-letter IATA airport code of the flight's destination.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "carrier": { + "description": "The airline carrier code.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["platform_tax_fee"], + "departure_airport_code": { + "description": "The three-letter IATA airport code that the flight departed from.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "source_transaction": { - "description": "The payment object that caused this tax to be inflicted.", + "flight_number": { + "description": "The flight number.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "type": { - "description": "The type of tax (VAT).", + "service_class": { + "description": "The flight's service class.", "maxLength": 5000, + "nullable": true, "type": "string" + }, + "stopover_allowed": { + "description": "Whether a stopover is allowed on this flight.", + "nullable": true, + "type": "boolean" } }, - "required": ["account", "id", "object", "source_transaction", "type"], - "title": "PlatformTax", + "title": "IssuingTransactionFlightDataLeg", "type": "object", "x-expandableFields": [] }, - "portal_business_profile": { + "issuing_transaction_fuel_data": { "description": "", "properties": { - "headline": { - "description": "The messaging shown to customers in the portal.", + "industry_product_code": { + "description": "[Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.", "maxLength": 5000, "nullable": true, "type": "string" }, - "privacy_policy_url": { - "description": "A link to the business’s publicly available privacy policy.", + "quantity_decimal": { + "description": "The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.", + "format": "decimal", + "nullable": true, + "type": "string" + }, + "type": { + "description": "The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.", "maxLength": 5000, "type": "string" }, - "terms_of_service_url": { - "description": "A link to the business’s publicly available terms of service.", + "unit": { + "description": "The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.", "maxLength": 5000, "type": "string" + }, + "unit_cost_decimal": { + "description": "The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.", + "format": "decimal", + "type": "string" } }, - "required": ["privacy_policy_url", "terms_of_service_url"], - "title": "PortalBusinessProfile", + "required": ["type", "unit", "unit_cost_decimal"], + "title": "IssuingTransactionFuelData", "type": "object", "x-expandableFields": [] }, - "portal_customer_update": { + "issuing_transaction_lodging_data": { "description": "", "properties": { - "allowed_updates": { - "description": "The types of customer updates that are supported. When empty, customers are not updateable.", - "items": { - "enum": ["address", "email", "phone", "shipping", "tax_id"], - "type": "string" - }, - "type": "array" + "check_in_at": { + "description": "The time of checking into the lodging.", + "nullable": true, + "type": "integer" }, - "enabled": { - "description": "Whether the feature is enabled.", - "type": "boolean" - } - }, - "required": ["allowed_updates", "enabled"], - "title": "PortalCustomerUpdate", - "type": "object", - "x-expandableFields": [] - }, - "portal_features": { - "description": "", - "properties": { - "customer_update": { - "$ref": "#/components/schemas/portal_customer_update" - }, - "invoice_history": { - "$ref": "#/components/schemas/portal_invoice_list" - }, - "payment_method_update": { - "$ref": "#/components/schemas/portal_payment_method_update" - }, - "subscription_cancel": { - "$ref": "#/components/schemas/portal_subscription_cancel" - }, - "subscription_update": { - "$ref": "#/components/schemas/portal_subscription_update" - } - }, - "required": [ - "customer_update", - "invoice_history", - "payment_method_update", - "subscription_cancel", - "subscription_update" - ], - "title": "PortalFeatures", - "type": "object", - "x-expandableFields": [ - "customer_update", - "invoice_history", - "payment_method_update", - "subscription_cancel", - "subscription_update" - ] - }, - "portal_invoice_list": { - "description": "", - "properties": { - "enabled": { - "description": "Whether the feature is enabled.", - "type": "boolean" + "nights": { + "description": "The number of nights stayed at the lodging.", + "nullable": true, + "type": "integer" } }, - "required": ["enabled"], - "title": "PortalInvoiceList", + "title": "IssuingTransactionLodgingData", "type": "object", "x-expandableFields": [] }, - "portal_payment_method_update": { + "issuing_transaction_network_data": { "description": "", "properties": { - "enabled": { - "description": "Whether the feature is enabled.", - "type": "boolean" + "authorization_code": { + "description": "A code created by Stripe which is shared with the merchant to validate the authorization. This field will be populated if the authorization message was approved. The code typically starts with the letter \"S\", followed by a six-digit number. For example, \"S498162\". Please note that the code is not guaranteed to be unique across authorizations.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "processing_date": { + "description": "The date the transaction was processed by the card network. This can be different from the date the seller recorded the transaction depending on when the acquirer submits the transaction to the network.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "transaction_id": { + "description": "Unique identifier for the authorization assigned by the card network used to match subsequent messages, disputes, and transactions.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "required": ["enabled"], - "title": "PortalPaymentMethodUpdate", + "title": "IssuingTransactionNetworkData", "type": "object", "x-expandableFields": [] }, - "portal_subscription_cancel": { + "issuing_transaction_purchase_details": { "description": "", "properties": { - "enabled": { - "description": "Whether the feature is enabled.", - "type": "boolean" + "fleet": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_transaction_fleet_data" + } + ], + "description": "Fleet-specific information for transactions using Fleet cards.", + "nullable": true }, - "mode": { - "description": "Whether to cancel subscriptions immediately or at the end of the billing period.", - "enum": ["at_period_end", "immediately"], - "type": "string" + "flight": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_transaction_flight_data" + } + ], + "description": "Information about the flight that was purchased with this transaction.", + "nullable": true }, - "proration_behavior": { - "description": "Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`.", - "enum": ["always_invoice", "create_prorations", "none"], + "fuel": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_transaction_fuel_data" + } + ], + "description": "Information about fuel that was purchased with this transaction.", + "nullable": true + }, + "lodging": { + "anyOf": [ + { + "$ref": "#/components/schemas/issuing_transaction_lodging_data" + } + ], + "description": "Information about lodging that was purchased with this transaction.", + "nullable": true + }, + "receipt": { + "description": "The line items in the purchase.", + "items": { + "$ref": "#/components/schemas/issuing_transaction_receipt_data" + }, + "nullable": true, + "type": "array" + }, + "reference": { + "description": "A merchant-specific order number.", + "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["enabled", "mode", "proration_behavior"], - "title": "PortalSubscriptionCancel", + "title": "IssuingTransactionPurchaseDetails", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["fleet", "flight", "fuel", "lodging", "receipt"] }, - "portal_subscription_update": { + "issuing_transaction_receipt_data": { "description": "", "properties": { - "default_allowed_updates": { - "description": "The types of subscription updates that are supported for items listed in the `products` attribute. When empty, subscriptions are not updateable.", - "items": { - "enum": ["price", "promotion_code", "quantity"], - "type": "string" - }, - "type": "array" + "description": { + "description": "The description of the item. The maximum length of this field is 26 characters.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "enabled": { - "description": "Whether the feature is enabled.", - "type": "boolean" + "quantity": { + "description": "The quantity of the item.", + "nullable": true, + "type": "number" }, - "products": { - "description": "The list of products that support subscription updates.", - "items": { - "$ref": "#/components/schemas/portal_subscription_update_product" - }, + "total": { + "description": "The total for this line item in cents.", "nullable": true, - "type": "array" + "type": "integer" }, - "proration_behavior": { - "description": "Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.", - "enum": ["always_invoice", "create_prorations", "none"], - "type": "string" + "unit_cost": { + "description": "The unit cost of the item in cents.", + "nullable": true, + "type": "integer" } }, - "required": [ - "default_allowed_updates", - "enabled", - "proration_behavior" - ], - "title": "PortalSubscriptionUpdate", + "title": "IssuingTransactionReceiptData", "type": "object", - "x-expandableFields": ["products"] + "x-expandableFields": [] }, - "portal_subscription_update_product": { + "issuing_transaction_treasury": { "description": "", "properties": { - "prices": { - "description": "The list of price IDs which, when subscribed to, a subscription can be updated.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "received_credit": { + "description": "The Treasury [ReceivedCredit](https://stripe.com/docs/api/treasury/received_credits) representing this Issuing transaction if it is a refund", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "product": { - "description": "The product ID.", + "received_debit": { + "description": "The Treasury [ReceivedDebit](https://stripe.com/docs/api/treasury/received_debits) representing this Issuing transaction if it is a capture", "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["prices", "product"], - "title": "PortalSubscriptionUpdateProduct", + "title": "IssuingTransactionTreasury", "type": "object", "x-expandableFields": [] }, - "price": { - "description": "Prices define the unit cost, currency, and (optional) billing cycle for both recurring and one-time purchases of products.\n[Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and prices help you track payment terms. Different physical goods or levels of service should be represented by products, and pricing options should be represented by prices. This approach lets you change prices without having to change your provisioning scheme.\n\nFor example, you might have a single \"gold\" product that has prices for $10/month, $100/year, and €9 once.\n\nRelated guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription), [create an invoice](https://stripe.com/docs/billing/invoices/create), and more about [products and prices](https://stripe.com/docs/billing/prices-guide).", + "item": { + "description": "A line item.", "properties": { - "active": { - "description": "Whether the price can be used for new purchases.", - "type": "boolean" + "amount_discount": { + "description": "Total discount amount applied. If no discounts were applied, defaults to 0.", + "type": "integer" }, - "billing_scheme": { - "description": "Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.", - "enum": ["per_unit", "tiered"], - "type": "string" + "amount_subtotal": { + "description": "Total before any discounts or taxes are applied.", + "type": "integer" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", + "amount_tax": { + "description": "Total tax amount applied. If no tax was applied, defaults to 0.", + "type": "integer" + }, + "amount_total": { + "description": "Total after discounts and taxes.", "type": "integer" }, "currency": { "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "lookup_key": { - "description": "A lookup key used to retrieve prices dynamically from a static string.", + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users. Defaults to product name.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" + "discounts": { + "description": "The discounts applied to the line item.", + "items": { + "$ref": "#/components/schemas/line_items_discount_amount" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" + "type": "array" }, - "nickname": { - "description": "A brief description of the price, hidden from customers.", + "id": { + "description": "Unique identifier for the object.", "maxLength": 5000, - "nullable": true, "type": "string" }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["price"], - "type": "string" - }, - "product": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/product" - }, - { - "$ref": "#/components/schemas/deleted_product" - } - ], - "description": "The ID of the product this price is associated with.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/product" - }, - { - "$ref": "#/components/schemas/deleted_product" - } - ] - } - }, - "recurring": { - "anyOf": [ - { - "$ref": "#/components/schemas/recurring" - } - ], - "description": "The recurring components of a price such as `interval` and `usage_type`.", - "nullable": true - }, - "tiers": { - "description": "Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.", - "items": { - "$ref": "#/components/schemas/price_tier" - }, - "type": "array" - }, - "tiers_mode": { - "description": "Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows.", - "enum": ["graduated", "volume"], - "nullable": true, + "enum": ["item"], "type": "string" }, - "transform_quantity": { + "price": { "anyOf": [ { - "$ref": "#/components/schemas/transform_quantity" + "$ref": "#/components/schemas/price" } ], - "description": "Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with `tiers`.", + "description": "The price used to generate the line item.", "nullable": true }, - "type": { - "description": "One of `one_time` or `recurring` depending on whether the price is for a one-time purchase or a recurring (subscription) purchase.", - "enum": ["one_time", "recurring"], - "type": "string" - }, - "unit_amount": { - "description": "The unit amount in %s to be charged, represented as a whole integer if possible. Only set if `billing_scheme=per_unit`.", + "quantity": { + "description": "The quantity of products being purchased.", "nullable": true, "type": "integer" }, - "unit_amount_decimal": { - "description": "The unit amount in %s to be charged, represented as a decimal string with at most 12 decimal places. Only set if `billing_scheme=per_unit`.", - "format": "decimal", - "nullable": true, - "type": "string" + "taxes": { + "description": "The taxes applied to the line item.", + "items": { + "$ref": "#/components/schemas/line_items_tax_amount" + }, + "type": "array" } }, "required": [ - "active", - "billing_scheme", - "created", + "amount_discount", + "amount_subtotal", + "amount_tax", + "amount_total", "currency", "id", - "livemode", - "metadata", - "object", - "product", - "type" + "object" ], - "title": "Price", + "title": "LineItem", "type": "object", - "x-expandableFields": [ - "product", - "recurring", - "tiers", - "transform_quantity" - ], - "x-resourceId": "price" + "x-expandableFields": ["discounts", "price", "taxes"], + "x-resourceId": "item" }, - "price_tier": { + "legal_entity_company": { "description": "", "properties": { - "flat_amount": { - "description": "Price for the entire tier.", - "nullable": true, - "type": "integer" - }, - "flat_amount_decimal": { - "description": "Same as `flat_amount`, but contains a decimal value with at most 12 decimal places.", - "format": "decimal", - "nullable": true, - "type": "string" + "address": { + "$ref": "#/components/schemas/address" }, - "unit_amount": { - "description": "Per unit price for units relevant to the tier.", - "nullable": true, - "type": "integer" + "address_kana": { + "anyOf": [ + { + "$ref": "#/components/schemas/legal_entity_japan_address" + } + ], + "description": "The Kana variation of the company's primary address (Japan only).", + "nullable": true }, - "unit_amount_decimal": { - "description": "Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.", - "format": "decimal", - "nullable": true, - "type": "string" + "address_kanji": { + "anyOf": [ + { + "$ref": "#/components/schemas/legal_entity_japan_address" + } + ], + "description": "The Kanji variation of the company's primary address (Japan only).", + "nullable": true }, - "up_to": { - "description": "Up to and including to this quantity will be contained in the tier.", - "nullable": true, - "type": "integer" - } - }, - "title": "PriceTier", - "type": "object", - "x-expandableFields": [] - }, - "product": { - "description": "Products describe the specific goods or services you offer to your customers.\nFor example, you might offer a Standard and Premium version of your goods or service; each version would be a separate Product.\nThey can be used in conjunction with [Prices](https://stripe.com/docs/api#prices) to configure pricing in Checkout and Subscriptions.\n\nRelated guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) or accept [one-time payments with Checkout](https://stripe.com/docs/payments/checkout/client#create-products) and more about [Products and Prices](https://stripe.com/docs/billing/prices-guide)", - "properties": { - "active": { - "description": "Whether the product is currently available for purchase.", + "directors_provided": { + "description": "Whether the company's directors have been provided. This Boolean will be `true` if you've manually indicated that all directors are provided via [the `directors_provided` parameter](https://stripe.com/docs/api/accounts/update#update_account-company-directors_provided).", "type": "boolean" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "executives_provided": { + "description": "Whether the company's executives have been provided. This Boolean will be `true` if you've manually indicated that all executives are provided via [the `executives_provided` parameter](https://stripe.com/docs/api/accounts/update#update_account-company-executives_provided), or if Stripe determined that sufficient executives were provided.", + "type": "boolean" }, - "description": { - "description": "The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.", + "export_license_id": { + "description": "The export license ID number of the company, also referred as Import Export Code (India only).", "maxLength": 5000, - "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "export_purpose_code": { + "description": "The purpose code to use for export transactions (India only).", "maxLength": 5000, "type": "string" }, - "images": { - "description": "A list of up to 8 URLs of images for this product, meant to be displayable to the customer.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, "name": { - "description": "The product's name, meant to be displayable to the customer. Whenever this product is sold via a subscription, name will show up on associated invoice line item descriptions.", + "description": "The company's legal name.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["product"], + "name_kana": { + "description": "The Kana variation of the company's legal name (Japan only).", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "package_dimensions": { + "name_kanji": { + "description": "The Kanji variation of the company's legal name (Japan only).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "owners_provided": { + "description": "Whether the company's owners have been provided. This Boolean will be `true` if you've manually indicated that all owners are provided via [the `owners_provided` parameter](https://stripe.com/docs/api/accounts/update#update_account-company-owners_provided), or if Stripe determined that sufficient owners were provided. Stripe determines ownership requirements using both the number of owners provided and their total percent ownership (calculated by adding the `percent_ownership` of each owner together).", + "type": "boolean" + }, + "ownership_declaration": { "anyOf": [ { - "$ref": "#/components/schemas/package_dimensions" + "$ref": "#/components/schemas/legal_entity_ubo_declaration" } ], - "description": "The dimensions of this product for shipping purposes.", + "description": "This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.", "nullable": true }, - "shippable": { - "description": "Whether this product is shipped (i.e., physical goods).", - "nullable": true, - "type": "boolean" - }, - "statement_descriptor": { - "description": "Extra information about a product which will appear on your customer's credit card statement. In the case that multiple products are billed at once, the first statement descriptor will be used.", + "phone": { + "description": "The company's phone number (used for verification).", "maxLength": 5000, "nullable": true, "type": "string" }, - "unit_label": { - "description": "A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions.", + "structure": { + "description": "The category identifying the legal structure of the company or legal entity. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details.", + "enum": [ + "free_zone_establishment", + "free_zone_llc", + "government_instrumentality", + "governmental_unit", + "incorporated_non_profit", + "incorporated_partnership", + "limited_liability_partnership", + "llc", + "multi_member_llc", + "private_company", + "private_corporation", + "private_partnership", + "public_company", + "public_corporation", + "public_partnership", + "registered_charity", + "single_member_llc", + "sole_establishment", + "sole_proprietorship", + "tax_exempt_government_instrumentality", + "unincorporated_association", + "unincorporated_non_profit", + "unincorporated_partnership" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "tax_id_provided": { + "description": "Whether the company's business ID number was provided.", + "type": "boolean" + }, + "tax_id_registrar": { + "description": "The jurisdiction in which the `tax_id` is registered (Germany-based companies only).", "maxLength": 5000, - "nullable": true, "type": "string" }, - "updated": { - "description": "Time at which the object was last updated. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "vat_id_provided": { + "description": "Whether the company's business VAT number was provided.", + "type": "boolean" }, - "url": { - "description": "A URL of a publicly-accessible webpage for this product.", - "maxLength": 2048, - "nullable": true, - "type": "string" + "verification": { + "anyOf": [ + { + "$ref": "#/components/schemas/legal_entity_company_verification" + } + ], + "description": "Information on the verification state of the company.", + "nullable": true } }, - "required": [ - "active", - "created", - "id", - "images", - "livemode", - "metadata", - "name", - "object", - "updated" - ], - "title": "Product", + "title": "LegalEntityCompany", "type": "object", - "x-expandableFields": ["package_dimensions"], - "x-resourceId": "product" + "x-expandableFields": [ + "address", + "address_kana", + "address_kanji", + "ownership_declaration", + "verification" + ] }, - "promotion_code": { - "description": "A Promotion Code represents a customer-redeemable code for a coupon. It can be used to\ncreate multiple codes for a single coupon.", + "legal_entity_company_verification": { + "description": "", "properties": { - "active": { - "description": "Whether the promotion code is currently active. A promotion code is only active if the coupon is also valid.", - "type": "boolean" - }, - "code": { - "description": "The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for each customer.", - "maxLength": 5000, - "type": "string" - }, - "coupon": { - "$ref": "#/components/schemas/coupon" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "customer": { + "document": { + "$ref": "#/components/schemas/legal_entity_company_verification_document" + } + }, + "required": ["document"], + "title": "LegalEntityCompanyVerification", + "type": "object", + "x-expandableFields": ["document"] + }, + "legal_entity_company_verification_document": { + "description": "", + "properties": { + "back": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/file" } ], - "description": "The customer that this promotion code can be used by.", + "description": "The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/file" } ] } }, - "expires_at": { - "description": "Date at which the promotion code can no longer be redeemed.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "id": { - "description": "Unique identifier for the object.", + "details": { + "description": "A user-displayable string describing the verification state of this document.", "maxLength": 5000, - "type": "string" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "max_redemptions": { - "description": "Maximum number of times this promotion code can be redeemed.", - "nullable": true, - "type": "integer" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", "nullable": true, - "type": "object" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["promotion_code"], "type": "string" }, - "restrictions": { - "$ref": "#/components/schemas/promotion_codes_resource_restrictions" - }, - "times_redeemed": { - "description": "Number of times this promotion code has been used.", - "type": "integer" - } - }, - "required": [ - "active", - "code", - "coupon", - "created", - "id", - "livemode", - "object", - "restrictions", - "times_redeemed" - ], - "title": "PromotionCode", - "type": "object", - "x-expandableFields": ["coupon", "customer", "restrictions"], - "x-resourceId": "promotion_code" - }, - "promotion_codes_resource_restrictions": { - "description": "", - "properties": { - "first_time_transaction": { - "description": "A Boolean indicating if the Promotion Code should only be redeemed for Customers without any successful payments or invoices", - "type": "boolean" - }, - "minimum_amount": { - "description": "Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).", - "nullable": true, - "type": "integer" - }, - "minimum_amount_currency": { - "description": "Three-letter [ISO code](https://stripe.com/docs/currencies) for minimum_amount", + "details_code": { + "description": "One of `document_corrupt`, `document_expired`, `document_failed_copy`, `document_failed_greyscale`, `document_failed_other`, `document_failed_test_mode`, `document_fraudulent`, `document_incomplete`, `document_invalid`, `document_manipulated`, `document_not_readable`, `document_not_uploaded`, `document_type_not_supported`, or `document_too_large`. A machine-readable code specifying the verification state for this document.", "maxLength": 5000, "nullable": true, "type": "string" - } - }, - "required": ["first_time_transaction"], - "title": "PromotionCodesResourceRestrictions", - "type": "object", - "x-expandableFields": [] - }, - "radar.early_fraud_warning": { - "description": "An early fraud warning indicates that the card issuer has notified us that a\ncharge may be fraudulent.\n\nRelated guide: [Early Fraud Warnings](https://stripe.com/docs/disputes/measuring#early-fraud-warnings).", - "properties": { - "actionable": { - "description": "An EFW is actionable if it has not received a dispute and has not been fully refunded. You may wish to proactively refund a charge that receives an EFW, in order to avoid receiving a dispute later.", - "type": "boolean" }, - "charge": { + "front": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/file" } ], - "description": "ID of the charge this early fraud warning is for, optionally expanded.", + "description": "The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`.", + "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/file" } ] } - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "fraud_type": { - "description": "The type of fraud labelled by the issuer. One of `card_never_received`, `fraudulent_card_application`, `made_with_counterfeit_card`, `made_with_lost_card`, `made_with_stolen_card`, `misc`, `unauthorized_use_of_card`.", - "maxLength": 5000, - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["radar.early_fraud_warning"], - "type": "string" } }, - "required": [ - "actionable", - "charge", - "created", - "fraud_type", - "id", - "livemode", - "object" - ], - "title": "RadarEarlyFraudWarning", + "title": "LegalEntityCompanyVerificationDocument", "type": "object", - "x-expandableFields": ["charge"], - "x-resourceId": "radar.early_fraud_warning" + "x-expandableFields": ["back", "front"] }, - "radar.value_list": { - "description": "Value lists allow you to group values together which can then be referenced in rules.\n\nRelated guide: [Default Stripe Lists](https://stripe.com/docs/radar/lists#managing-list-items).", + "legal_entity_dob": { + "description": "", "properties": { - "alias": { - "description": "The name of the value list for use in rules.", - "maxLength": 5000, - "type": "string" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", + "day": { + "description": "The day of birth, between 1 and 31.", + "nullable": true, "type": "integer" }, - "created_by": { - "description": "The name or email address of the user who created this value list.", - "maxLength": 5000, - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "item_type": { - "description": "The type of items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`.", - "enum": [ - "card_bin", - "card_fingerprint", - "case_sensitive_string", - "country", - "email", - "ip_address", - "string" - ], - "type": "string" - }, - "list_items": { - "description": "List of items contained within this value list.", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/radar.value_list_item" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "RadarListListItemList", - "type": "object", - "x-expandableFields": ["data"] - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "name": { - "description": "The name of the value list.", - "maxLength": 5000, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["radar.value_list"], - "type": "string" - } - }, - "required": [ - "alias", - "created", - "created_by", - "id", - "item_type", - "list_items", - "livemode", - "metadata", - "name", - "object" - ], - "title": "RadarListList", - "type": "object", - "x-expandableFields": ["list_items"], - "x-resourceId": "radar.value_list" - }, - "radar.value_list_item": { - "description": "Value list items allow you to add specific values to a given Radar value list, which can then be used in rules.\n\nRelated guide: [Managing List Items](https://stripe.com/docs/radar/lists#managing-list-items).", - "properties": { - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", + "month": { + "description": "The month of birth, between 1 and 12.", + "nullable": true, "type": "integer" }, - "created_by": { - "description": "The name or email address of the user who added this item to the value list.", - "maxLength": 5000, - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["radar.value_list_item"], - "type": "string" - }, - "value": { - "description": "The value of the item.", - "maxLength": 5000, - "type": "string" - }, - "value_list": { - "description": "The identifier of the value list this item belongs to.", - "maxLength": 5000, - "type": "string" + "year": { + "description": "The four-digit year of birth.", + "nullable": true, + "type": "integer" } }, - "required": [ - "created", - "created_by", - "id", - "livemode", - "object", - "value", - "value_list" - ], - "title": "RadarListListItem", + "title": "LegalEntityDOB", "type": "object", - "x-expandableFields": [], - "x-resourceId": "radar.value_list_item" + "x-expandableFields": [] }, - "radar_review_resource_location": { + "legal_entity_japan_address": { "description": "", "properties": { "city": { - "description": "The city where the payment originated.", + "description": "City/Ward.", "maxLength": 5000, "nullable": true, "type": "string" }, "country": { - "description": "Two-letter ISO code representing the country where the payment originated.", + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", "maxLength": 5000, "nullable": true, "type": "string" }, - "latitude": { - "description": "The geographic latitude where the payment originated.", - "nullable": true, - "type": "number" - }, - "longitude": { - "description": "The geographic longitude where the payment originated.", - "nullable": true, - "type": "number" - }, - "region": { - "description": "The state/county/province/region where the payment originated.", + "line1": { + "description": "Block/Building number.", "maxLength": 5000, "nullable": true, "type": "string" - } - }, - "title": "RadarReviewResourceLocation", - "type": "object", - "x-expandableFields": [] - }, - "radar_review_resource_session": { - "description": "", - "properties": { - "browser": { - "description": "The browser used in this browser session (e.g., `Chrome`).", + }, + "line2": { + "description": "Building details.", "maxLength": 5000, "nullable": true, "type": "string" }, - "device": { - "description": "Information about the device used for the browser session (e.g., `Samsung SM-G930T`).", + "postal_code": { + "description": "ZIP or postal code.", "maxLength": 5000, "nullable": true, "type": "string" }, - "platform": { - "description": "The platform for the browser session (e.g., `Macintosh`).", + "state": { + "description": "Prefecture.", "maxLength": 5000, "nullable": true, "type": "string" }, - "version": { - "description": "The version for the browser session (e.g., `61.0.3163.100`).", + "town": { + "description": "Town/cho-me.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "RadarReviewResourceSession", + "title": "LegalEntityJapanAddress", "type": "object", "x-expandableFields": [] }, - "recipient": { - "description": "With `Recipient` objects, you can transfer money from your Stripe account to a\nthird-party bank account or debit card. The API allows you to create, delete,\nand update your recipients. You can retrieve individual recipients as well as\na list of all your recipients.\n\n**`Recipient` objects have been deprecated in favor of\n[Connect](https://stripe.com/docs/connect), specifically Connect's much more powerful\n[Account objects](https://stripe.com/docs/api#account). Stripe accounts that don't already use\nrecipients can no longer begin doing so. Please use `Account` objects\ninstead.**", + "legal_entity_person_verification": { + "description": "", "properties": { - "active_account": { + "additional_document": { "anyOf": [ { - "$ref": "#/components/schemas/bank_account" + "$ref": "#/components/schemas/legal_entity_person_verification_document" } ], - "description": "Hash describing the current account on the recipient, if there is one.", + "description": "A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.", "nullable": true }, - "cards": { - "description": "", + "details": { + "description": "A user-displayable string describing the verification state for the person. For example, this may say \"Provided identity information could not be verified\".", + "maxLength": 5000, "nullable": true, - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/card" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "CardList", - "type": "object", - "x-expandableFields": ["data"] + "type": "string" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "details_code": { + "description": "One of `document_address_mismatch`, `document_dob_mismatch`, `document_duplicate_type`, `document_id_number_mismatch`, `document_name_mismatch`, `document_nationality_mismatch`, `failed_keyed_identity`, or `failed_other`. A machine-readable code specifying the verification state for the person.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "default_card": { + "document": { + "$ref": "#/components/schemas/legal_entity_person_verification_document" + }, + "status": { + "description": "The state of verification for the person. Possible values are `unverified`, `pending`, or `verified`.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["status"], + "title": "LegalEntityPersonVerification", + "type": "object", + "x-expandableFields": ["additional_document", "document"] + }, + "legal_entity_person_verification_document": { + "description": "", + "properties": { + "back": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/card" + "$ref": "#/components/schemas/file" } ], - "description": "The default card to use for creating transfers to this recipient.", + "description": "The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/card" + "$ref": "#/components/schemas/file" } ] } }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "details": { + "description": "A user-displayable string describing the verification state of this document. For example, if a document is uploaded and the picture is too fuzzy, this may say \"Identity document is too unclear to read\".", "maxLength": 5000, "nullable": true, "type": "string" }, - "email": { + "details_code": { + "description": "One of `document_corrupt`, `document_country_not_supported`, `document_expired`, `document_failed_copy`, `document_failed_other`, `document_failed_test_mode`, `document_fraudulent`, `document_failed_greyscale`, `document_incomplete`, `document_invalid`, `document_manipulated`, `document_missing_back`, `document_missing_front`, `document_not_readable`, `document_not_uploaded`, `document_photo_mismatch`, `document_too_large`, or `document_type_not_supported`. A machine-readable code specifying the verification state for this document.", "maxLength": 5000, "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "migrated_to": { + "front": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/file" } ], - "description": "The ID of the [Custom account](https://stripe.com/docs/connect/custom-accounts) this recipient was migrated to. If set, the recipient can no longer be updated, nor can transfers be made to it: use the Custom account instead.", + "description": "The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/file" } ] } + } + }, + "title": "LegalEntityPersonVerificationDocument", + "type": "object", + "x-expandableFields": ["back", "front"] + }, + "legal_entity_ubo_declaration": { + "description": "", + "properties": { + "date": { + "description": "The Unix timestamp marking when the beneficial owner attestation was made.", + "format": "unix-time", + "nullable": true, + "type": "integer" }, - "name": { - "description": "Full, legal name of the recipient.", + "ip": { + "description": "The IP address from which the beneficial owner attestation was made.", "maxLength": 5000, "nullable": true, "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["recipient"], - "type": "string" - }, - "rolled_back_from": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/account" - } - ], - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/account" - } - ] - } - }, - "type": { - "description": "Type of the recipient, one of `individual` or `corporation`.", - "maxLength": 5000, + "user_agent": { + "description": "The user-agent string from the browser where the beneficial owner attestation was made.", + "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["created", "id", "livemode", "metadata", "object", "type"], - "title": "TransferRecipient", + "title": "LegalEntityUBODeclaration", "type": "object", - "x-expandableFields": [ - "active_account", - "cards", - "default_card", - "migrated_to", - "rolled_back_from" - ], - "x-resourceId": "recipient" + "x-expandableFields": [] }, - "recurring": { - "description": "", + "line_item": { + "description": "Invoice Line Items represent the individual lines within an [invoice](https://stripe.com/docs/api/invoices) and only exist within the context of an invoice.\n\nEach line item is backed by either an [invoice item](https://stripe.com/docs/api/invoiceitems) or a [subscription item](https://stripe.com/docs/api/subscription_items).", "properties": { - "aggregate_usage": { - "description": "Specifies a usage aggregation strategy for prices of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`.", - "enum": ["last_during_period", "last_ever", "max", "sum"], - "nullable": true, - "type": "string" - }, - "interval": { - "description": "The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.", - "enum": ["day", "month", "week", "year"], - "type": "string" + "amount": { + "description": "The amount, in cents (or local equivalent).", + "type": "integer" }, - "interval_count": { - "description": "The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months.", + "amount_excluding_tax": { + "description": "The integer amount in cents (or local equivalent) representing the amount for this line item, excluding all tax and discounts.", + "nullable": true, "type": "integer" }, - "usage_type": { - "description": "Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.", - "enum": ["licensed", "metered"], + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" - } - }, - "required": ["interval", "interval_count", "usage_type"], - "title": "Recurring", - "type": "object", - "x-expandableFields": [] - }, - "refund": { - "description": "`Refund` objects allow you to refund a charge that has previously been created\nbut not yet refunded. Funds will be refunded to the credit or debit card that\nwas originally charged.\n\nRelated guide: [Refunds](https://stripe.com/docs/refunds).", - "properties": { - "amount": { - "description": "Amount, in %s.", - "type": "integer" }, - "balance_transaction": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/balance_transaction" - } - ], - "description": "Balance transaction that describes the impact on your account balance.", + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/balance_transaction" - } - ] - } + "type": "string" }, - "charge": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/charge" - } - ], - "description": "ID of the charge that was refunded.", + "discount_amounts": { + "description": "The amount of discount calculated per discount for this line item.", + "items": { + "$ref": "#/components/schemas/discounts_resource_discount_amount" + }, "nullable": true, - "x-expansionResources": { - "oneOf": [ + "type": "array" + }, + "discountable": { + "description": "If true, discounts will apply to this line item. Always false for prorations.", + "type": "boolean" + }, + "discounts": { + "description": "The discounts applied to the invoice line item. Line item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.", + "items": { + "anyOf": [ { - "$ref": "#/components/schemas/charge" + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/discount" } - ] - } - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/discount" + } + ] + } + }, + "type": "array" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, "type": "string" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users. (Available on non-card refunds only)", + "invoice": { + "description": "The ID of the invoice that contains this line item.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "failure_balance_transaction": { + "invoice_item": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/invoiceitem" } ], - "description": "If the refund failed, this balance transaction describes the adjustment made on your account balance that reverses the initial balance transaction.", + "description": "The ID of the [invoice item](https://stripe.com/docs/api/invoiceitems) associated with this line item if any.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/invoiceitem" } ] } }, - "failure_reason": { - "description": "If the refund failed, the reason for refund failure if known. Possible values are `lost_or_stolen_card`, `expired_or_canceled_card`, or `unknown`.", - "maxLength": 5000, - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" }, "metadata": { "additionalProperties": { "maxLength": 500, "type": "string" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items with `type=subscription`, `metadata` reflects the current metadata from the subscription associated with the line item, unless the invoice line was directly updated with different metadata after creation.", "type": "object" }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["refund"], + "enum": ["line_item"], "type": "string" }, - "payment_intent": { + "period": { + "$ref": "#/components/schemas/invoice_line_item_period" + }, + "price": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_intent" + "$ref": "#/components/schemas/price" } ], - "description": "ID of the PaymentIntent that was refunded.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_intent" - } - ] - } + "description": "The price of the line item.", + "nullable": true }, - "reason": { - "description": "Reason for the refund, either user-provided (`duplicate`, `fraudulent`, or `requested_by_customer`) or generated by Stripe internally (`expired_uncaptured_charge`).", - "maxLength": 5000, - "nullable": true, - "type": "string" + "proration": { + "description": "Whether this is a proration.", + "type": "boolean" }, - "receipt_number": { - "description": "This is the transaction number that appears on email receipts sent for this refund.", - "maxLength": 5000, + "proration_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoices_resource_line_items_proration_details" + } + ], + "description": "Additional details for proration line items", + "nullable": true + }, + "quantity": { + "description": "The quantity of the subscription, if the line item is a subscription or a proration.", "nullable": true, - "type": "string" + "type": "integer" }, - "source_transfer_reversal": { + "subscription": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/transfer_reversal" + "$ref": "#/components/schemas/subscription" } ], - "description": "The transfer reversal that is associated with the refund. Only present if the charge came from another Stripe account. See the Connect documentation for details.", + "description": "The subscription that the invoice item pertains to, if any.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/transfer_reversal" + "$ref": "#/components/schemas/subscription" } ] } }, - "status": { - "description": "Status of the refund. For credit card refunds, this can be `pending`, `succeeded`, or `failed`. For other types of refunds, it can be `pending`, `succeeded`, `failed`, or `canceled`. Refer to our [refunds](https://stripe.com/docs/refunds#failed-refunds) documentation for more details.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "transfer_reversal": { + "subscription_item": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/transfer_reversal" + "$ref": "#/components/schemas/subscription_item" } ], - "description": "If the accompanying transfer was reversed, the transfer reversal object. Only applicable if the charge was created using the destination parameter.", - "nullable": true, + "description": "The subscription item that generated this line item. Left empty if the line item is not an explicit result of a subscription.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/transfer_reversal" + "$ref": "#/components/schemas/subscription_item" } ] } + }, + "tax_amounts": { + "description": "The amount of tax calculated per tax rate for this line item", + "items": { + "$ref": "#/components/schemas/invoice_tax_amount" + }, + "type": "array" + }, + "tax_rates": { + "description": "The tax rates which apply to the line item.", + "items": { + "$ref": "#/components/schemas/tax_rate" + }, + "type": "array" + }, + "type": { + "description": "A string identifying the type of the source of this line item, either an `invoiceitem` or a `subscription`.", + "enum": ["invoiceitem", "subscription"], + "type": "string" + }, + "unit_amount_excluding_tax": { + "description": "The amount in cents (or local equivalent) representing the unit amount for this line item, excluding all tax and discounts.", + "format": "decimal", + "nullable": true, + "type": "string" } }, - "required": ["amount", "created", "currency", "id", "object"], - "title": "Refund", + "required": [ + "amount", + "currency", + "discountable", + "discounts", + "id", + "livemode", + "metadata", + "object", + "period", + "proration", + "type" + ], + "title": "InvoiceLineItem", "type": "object", "x-expandableFields": [ - "balance_transaction", - "charge", - "failure_balance_transaction", - "payment_intent", - "source_transfer_reversal", - "transfer_reversal" + "discount_amounts", + "discounts", + "invoice_item", + "period", + "price", + "proration_details", + "subscription", + "subscription_item", + "tax_amounts", + "tax_rates" ], - "x-resourceId": "refund" + "x-resourceId": "line_item" }, - "reporting.report_run": { - "description": "The Report Run object represents an instance of a report type generated with\nspecific run parameters. Once the object is created, Stripe begins processing the report.\nWhen the report has finished running, it will give you a reference to a file\nwhere you can retrieve your results. For an overview, see\n[API Access to Reports](https://stripe.com/docs/reporting/statements/api).\n\nNote that reports can only be run based on your live-mode data (not test-mode\ndata), and thus related requests must be made with a\n[live-mode API key](https://stripe.com/docs/keys#test-live-modes).", + "line_items_discount_amount": { + "description": "", "properties": { - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", + "amount": { + "description": "The amount discounted.", "type": "integer" }, - "error": { - "description": "If something should go wrong during the run, a message about the failure (populated when\n `status=failed`).", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "livemode": { - "description": "Always `true`: reports can only be run on live-mode data.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["reporting.report_run"], - "type": "string" - }, - "parameters": { - "$ref": "#/components/schemas/financial_reporting_finance_report_run_run_parameters" + "discount": { + "$ref": "#/components/schemas/discount" + } + }, + "required": ["amount", "discount"], + "title": "LineItemsDiscountAmount", + "type": "object", + "x-expandableFields": ["discount"] + }, + "line_items_tax_amount": { + "description": "", + "properties": { + "amount": { + "description": "Amount of tax applied for this rate.", + "type": "integer" }, - "report_type": { - "description": "The ID of the [report type](https://stripe.com/docs/reports/report-types) to run, such as `\"balance.summary.1\"`.", - "maxLength": 5000, - "type": "string" + "rate": { + "$ref": "#/components/schemas/tax_rate" }, - "result": { - "anyOf": [ - { - "$ref": "#/components/schemas/file" - } + "taxability_reason": { + "description": "The reasoning behind this tax, for example, if the product is tax exempt. The possible values for this field may be extended as new tax rules are supported.", + "enum": [ + "customer_exempt", + "not_collecting", + "not_subject_to_tax", + "not_supported", + "portion_product_exempt", + "portion_reduced_rated", + "portion_standard_rated", + "product_exempt", + "product_exempt_holiday", + "proportionally_rated", + "reduced_rated", + "reverse_charge", + "standard_rated", + "taxable_basis_reduced", + "zero_rated" ], - "description": "The file object representing the result of the report run (populated when\n `status=succeeded`).", - "nullable": true - }, - "status": { - "description": "Status of this report run. This will be `pending` when the run is initially created.\n When the run finishes, this will be set to `succeeded` and the `result` field will be populated.\n Rarely, we may encounter an error, at which point this will be set to `failed` and the `error` field will be populated.", - "maxLength": 5000, - "type": "string" + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true }, - "succeeded_at": { - "description": "Timestamp at which this run successfully finished (populated when\n `status=succeeded`). Measured in seconds since the Unix epoch.", - "format": "unix-time", + "taxable_amount": { + "description": "The amount on which tax is calculated, in cents (or local equivalent).", "nullable": true, "type": "integer" } }, - "required": [ - "created", - "id", - "livemode", - "object", - "parameters", - "report_type", - "status" - ], - "title": "reporting_report_run", + "required": ["amount", "rate"], + "title": "LineItemsTaxAmount", "type": "object", - "x-expandableFields": ["parameters", "result"], - "x-resourceId": "reporting.report_run" + "x-expandableFields": ["rate"] }, - "reporting.report_type": { - "description": "The Report Type resource corresponds to a particular type of report, such as\nthe \"Activity summary\" or \"Itemized payouts\" reports. These objects are\nidentified by an ID belonging to a set of enumerated values. See\n[API Access to Reports documentation](https://stripe.com/docs/reporting/statements/api)\nfor those Report Type IDs, along with required and optional parameters.\n\nNote that reports can only be run based on your live-mode data (not test-mode\ndata), and thus related requests must be made with a\n[live-mode API key](https://stripe.com/docs/keys#test-live-modes).", + "linked_account_options_us_bank_account": { + "description": "", "properties": { - "data_available_end": { - "description": "Most recent time for which this Report Type is available. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "data_available_start": { - "description": "Earliest time for which this Report Type is available. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "filters": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_us_bank_account_linked_account_options_filters" }, - "default_columns": { - "description": "List of column names that are included by default when this Report Type gets run. (If the Report Type doesn't support the `columns` parameter, this will be null.)", + "permissions": { + "description": "The list of permissions to request. The `payment_method` permission must be included.", "items": { - "maxLength": 5000, + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], "type": "string" }, - "nullable": true, "type": "array" }, - "id": { - "description": "The [ID of the Report Type](https://stripe.com/docs/reporting/statements/api#available-report-types), such as `balance.summary.1`.", - "maxLength": 5000, - "type": "string" + "prefetch": { + "description": "Data features requested to be retrieved upon account creation.", + "items": { + "enum": ["balances", "ownership", "transactions"], + "type": "string", + "x-stripeBypassValidation": true + }, + "nullable": true, + "type": "array" }, - "name": { - "description": "Human-readable name of the Report Type", + "return_url": { + "description": "For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.", "maxLength": 5000, "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["reporting.report_type"], - "type": "string" - }, - "updated": { - "description": "When this Report Type was latest updated. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "version": { - "description": "Version of the Report Type. Different versions report with the same ID will have the same purpose, but may take different run parameters or have different result schemas.", - "type": "integer" } }, - "required": [ - "data_available_end", - "data_available_start", - "id", - "name", - "object", - "updated", - "version" - ], - "title": "reporting_report_type", + "title": "linked_account_options_us_bank_account", "type": "object", - "x-expandableFields": [], - "x-resourceId": "reporting.report_type" + "x-expandableFields": ["filters"] }, - "reserve_transaction": { - "description": "", + "login_link": { + "description": "Login Links are single-use URLs for a connected account to access the Express Dashboard. The connected account's [account.controller.stripe_dashboard.type](/api/accounts/object#account_object-controller-stripe_dashboard-type) must be `express` to have access to the Express Dashboard.", "properties": { - "amount": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["login_link"], "type": "string" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "url": { + "description": "The URL for the login link.", "maxLength": 5000, - "nullable": true, "type": "string" + } + }, + "required": ["created", "object", "url"], + "title": "LoginLink", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "login_link" + }, + "mandate": { + "description": "A Mandate is a record of the permission that your customer gives you to debit their payment method.", + "properties": { + "customer_acceptance": { + "$ref": "#/components/schemas/customer_acceptance" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "multi_use": { + "$ref": "#/components/schemas/mandate_multi_use" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["reserve_transaction"], + "enum": ["mandate"], "type": "string" - } - }, - "required": ["amount", "currency", "id", "object"], - "title": "ReserveTransaction", - "type": "object", - "x-expandableFields": [] - }, - "review": { - "description": "Reviews can be used to supplement automated fraud detection with human expertise.\n\nLearn more about [Radar](/radar) and reviewing payments\n[here](https://stripe.com/docs/radar/reviews).", - "properties": { - "billing_zip": { - "description": "The ZIP or postal code of the card used, if applicable.", + }, + "on_behalf_of": { + "description": "The account (if any) that the mandate is intended for.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "charge": { + "payment_method": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/payment_method" } ], - "description": "The charge associated with this review.", - "nullable": true, + "description": "ID of the payment method associated with this mandate.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/payment_method" } ] } }, - "closed_reason": { - "description": "The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, or `disputed`.", - "enum": ["approved", "disputed", "refunded", "refunded_as_fraud"], - "nullable": true, - "type": "string" + "payment_method_details": { + "$ref": "#/components/schemas/mandate_payment_method_details" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "single_use": { + "$ref": "#/components/schemas/mandate_single_use" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "status": { + "description": "The mandate status indicates whether or not you can use it to initiate a payment.", + "enum": ["active", "inactive", "pending"], "type": "string" }, - "ip_address": { - "description": "The IP address where the payment originated.", - "maxLength": 5000, - "nullable": true, + "type": { + "description": "The type of the mandate.", + "enum": ["multi_use", "single_use"], "type": "string" - }, - "ip_address_location": { - "anyOf": [ - { - "$ref": "#/components/schemas/radar_review_resource_location" - } - ], - "description": "Information related to the location of the payment. Note that this information is an approximation and attempts to locate the nearest population center - it should not be used to determine a specific address.", - "nullable": true - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["review"], - "type": "string" - }, - "open": { - "description": "If `true`, the review needs action.", - "type": "boolean" - }, - "opened_reason": { - "description": "The reason the review was opened. One of `rule` or `manual`.", - "enum": ["manual", "rule"], - "type": "string" - }, - "payment_intent": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_intent" - } - ], - "description": "The PaymentIntent ID associated with this review, if one exists.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_intent" - } - ] - } - }, - "reason": { - "description": "The reason the review is currently open or closed. One of `rule`, `manual`, `approved`, `refunded`, `refunded_as_fraud`, or `disputed`.", - "maxLength": 5000, - "type": "string" - }, - "session": { - "anyOf": [ - { - "$ref": "#/components/schemas/radar_review_resource_session" - } - ], - "description": "Information related to the browsing session of the user who initiated the payment.", - "nullable": true } }, "required": [ - "created", + "customer_acceptance", "id", "livemode", "object", - "open", - "opened_reason", - "reason" + "payment_method", + "payment_method_details", + "status", + "type" ], - "title": "RadarReview", + "title": "Mandate", "type": "object", "x-expandableFields": [ - "charge", - "ip_address_location", - "payment_intent", - "session" + "customer_acceptance", + "multi_use", + "payment_method", + "payment_method_details", + "single_use" ], - "x-resourceId": "review" + "x-resourceId": "mandate" }, - "rule": { + "mandate_acss_debit": { "description": "", "properties": { - "action": { - "description": "The action taken on the payment.", + "default_for": { + "description": "List of Stripe products where this mandate can be selected automatically.", + "items": { + "enum": ["invoice", "subscription"], + "type": "string" + }, + "type": "array" + }, + "interval_description": { + "description": "Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "payment_schedule": { + "description": "Payment schedule for the mandate.", + "enum": ["combined", "interval", "sporadic"], "type": "string" }, - "predicate": { - "description": "The predicate to evaluate the payment against.", - "maxLength": 5000, + "transaction_type": { + "description": "Transaction type of the mandate.", + "enum": ["business", "personal"], "type": "string" } }, - "required": ["action", "id", "predicate"], - "title": "RadarRule", + "required": ["payment_schedule", "transaction_type"], + "title": "mandate_acss_debit", "type": "object", "x-expandableFields": [] }, - "scheduled_query_run": { - "description": "If you have [scheduled a Sigma query](https://stripe.com/docs/sigma/scheduled-queries), you'll\nreceive a `sigma.scheduled_query_run.created` webhook each time the query\nruns. The webhook contains a `ScheduledQueryRun` object, which you can use to\nretrieve the query results.", - "properties": { - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "data_load_time": { - "description": "When the query was run, Sigma contained a snapshot of your Stripe data at this time.", - "format": "unix-time", - "type": "integer" - }, - "error": { - "$ref": "#/components/schemas/sigma_scheduled_query_run_error" - }, - "file": { - "anyOf": [ - { - "$ref": "#/components/schemas/file" - } - ], - "description": "The file object representing the results of the query.", - "nullable": true - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["scheduled_query_run"], - "type": "string" - }, - "result_available_until": { - "description": "Time at which the result expires and is no longer available for download.", - "format": "unix-time", - "type": "integer" - }, - "sql": { - "description": "SQL for the query.", - "maxLength": 100000, - "type": "string" - }, - "status": { - "description": "The query's execution status, which will be `completed` for successful runs, and `canceled`, `failed`, or `timed_out` otherwise.", - "maxLength": 5000, - "type": "string" - }, - "title": { - "description": "Title of the query.", - "maxLength": 5000, - "type": "string" - } - }, - "required": [ - "created", - "data_load_time", - "id", - "livemode", - "object", - "result_available_until", - "sql", - "status", - "title" - ], - "title": "ScheduledQueryRun", + "mandate_amazon_pay": { + "description": "", + "properties": {}, + "title": "mandate_amazon_pay", "type": "object", - "x-expandableFields": ["error", "file"], - "x-resourceId": "scheduled_query_run" + "x-expandableFields": [] }, - "sepa_debit_generated_from": { + "mandate_au_becs_debit": { "description": "", "properties": { - "charge": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/charge" - } - ], - "description": "The ID of the Charge that generated this PaymentMethod, if any.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/charge" - } - ] - } - }, - "setup_attempt": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/setup_attempt" - } - ], - "description": "The ID of the SetupAttempt that generated this PaymentMethod, if any.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/setup_attempt" - } - ] - } + "url": { + "description": "The URL of the mandate. This URL generally contains sensitive information about the customer and should be shared with them exclusively.", + "maxLength": 5000, + "type": "string" } }, - "title": "sepa_debit_generated_from", + "required": ["url"], + "title": "mandate_au_becs_debit", "type": "object", - "x-expandableFields": ["charge", "setup_attempt"] + "x-expandableFields": [] }, - "setup_attempt": { - "description": "A SetupAttempt describes one attempted confirmation of a SetupIntent,\nwhether that confirmation was successful or unsuccessful. You can use\nSetupAttempts to inspect details of a specific attempt at setting up a\npayment method using a SetupIntent.", + "mandate_bacs_debit": { + "description": "", "properties": { - "application": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/application" - } - ], - "description": "The value of [application](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-application) on the SetupIntent at the time of this confirmation.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/application" - } - ] - } - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "customer": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ], - "description": "The value of [customer](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-customer) on the SetupIntent at the time of this confirmation.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ] - } - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "network_status": { + "description": "The status of the mandate on the Bacs network. Can be one of `pending`, `revoked`, `refused`, or `accepted`.", + "enum": ["accepted", "pending", "refused", "revoked"], "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["setup_attempt"], + "reference": { + "description": "The unique reference identifying the mandate on the Bacs network.", + "maxLength": 5000, "type": "string" }, - "on_behalf_of": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/account" - } + "revocation_reason": { + "description": "When the mandate is revoked on the Bacs network this field displays the reason for the revocation.", + "enum": [ + "account_closed", + "bank_account_restricted", + "bank_ownership_changed", + "could_not_process", + "debit_not_authorized" ], - "description": "The value of [on_behalf_of](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-on_behalf_of) on the SetupIntent at the time of this confirmation.", "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/account" - } - ] - } - }, - "payment_method": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" - } - ], - "description": "ID of the payment method used with this SetupAttempt.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } - }, - "payment_method_details": { - "$ref": "#/components/schemas/setup_attempt_payment_method_details" - }, - "setup_error": { - "anyOf": [ - { - "$ref": "#/components/schemas/api_errors" - } - ], - "description": "The error encountered during this attempt to confirm the SetupIntent, if any.", - "nullable": true - }, - "setup_intent": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/setup_intent" - } - ], - "description": "ID of the SetupIntent that this attempt belongs to.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/setup_intent" - } - ] - } - }, - "status": { - "description": "Status of this SetupAttempt, one of `requires_confirmation`, `requires_action`, `processing`, `succeeded`, `failed`, or `abandoned`.", - "maxLength": 5000, "type": "string" }, - "usage": { - "description": "The value of [usage](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-usage) on the SetupIntent at the time of this confirmation, one of `off_session` or `on_session`.", + "url": { + "description": "The URL that will contain the mandate that the customer has signed.", "maxLength": 5000, "type": "string" } }, - "required": [ - "created", - "id", - "livemode", - "object", - "payment_method", - "payment_method_details", - "setup_intent", - "status", - "usage" - ], - "title": "PaymentFlowsSetupIntentSetupAttempt", + "required": ["network_status", "reference", "url"], + "title": "mandate_bacs_debit", "type": "object", - "x-expandableFields": [ - "application", - "customer", - "on_behalf_of", - "payment_method", - "payment_method_details", - "setup_error", - "setup_intent" - ], - "x-resourceId": "setup_attempt" + "x-expandableFields": [] }, - "setup_attempt_payment_method_details": { + "mandate_cashapp": { + "description": "", + "properties": {}, + "title": "mandate_cashapp", + "type": "object", + "x-expandableFields": [] + }, + "mandate_link": { + "description": "", + "properties": {}, + "title": "mandate_link", + "type": "object", + "x-expandableFields": [] + }, + "mandate_multi_use": { + "description": "", + "properties": {}, + "title": "mandate_multi_use", + "type": "object", + "x-expandableFields": [] + }, + "mandate_payment_method_details": { "description": "", "properties": { + "acss_debit": { + "$ref": "#/components/schemas/mandate_acss_debit" + }, + "amazon_pay": { + "$ref": "#/components/schemas/mandate_amazon_pay" + }, "au_becs_debit": { - "$ref": "#/components/schemas/setup_attempt_payment_method_details_au_becs_debit" + "$ref": "#/components/schemas/mandate_au_becs_debit" }, "bacs_debit": { - "$ref": "#/components/schemas/setup_attempt_payment_method_details_bacs_debit" - }, - "bancontact": { - "$ref": "#/components/schemas/setup_attempt_payment_method_details_bancontact" + "$ref": "#/components/schemas/mandate_bacs_debit" }, "card": { - "$ref": "#/components/schemas/setup_attempt_payment_method_details_card" + "$ref": "#/components/schemas/card_mandate_payment_method_details" }, - "card_present": { - "$ref": "#/components/schemas/setup_attempt_payment_method_details_card_present" + "cashapp": { + "$ref": "#/components/schemas/mandate_cashapp" }, - "ideal": { - "$ref": "#/components/schemas/setup_attempt_payment_method_details_ideal" + "link": { + "$ref": "#/components/schemas/mandate_link" }, - "sepa_debit": { - "$ref": "#/components/schemas/setup_attempt_payment_method_details_sepa_debit" + "paypal": { + "$ref": "#/components/schemas/mandate_paypal" }, - "sofort": { - "$ref": "#/components/schemas/setup_attempt_payment_method_details_sofort" + "revolut_pay": { + "$ref": "#/components/schemas/mandate_revolut_pay" + }, + "sepa_debit": { + "$ref": "#/components/schemas/mandate_sepa_debit" }, "type": { - "description": "The type of the payment method used in the SetupIntent (e.g., `card`). An additional hash is included on `payment_method_details` with a name matching this value. It contains confirmation-specific information for the payment method.", + "description": "This mandate corresponds with a specific payment method type. The `payment_method_details` includes an additional hash with the same name and contains mandate information that's specific to that payment method.", "maxLength": 5000, "type": "string" + }, + "us_bank_account": { + "$ref": "#/components/schemas/mandate_us_bank_account" } }, "required": ["type"], - "title": "SetupAttemptPaymentMethodDetails", + "title": "mandate_payment_method_details", "type": "object", "x-expandableFields": [ + "acss_debit", + "amazon_pay", "au_becs_debit", "bacs_debit", - "bancontact", "card", - "card_present", - "ideal", + "cashapp", + "link", + "paypal", + "revolut_pay", "sepa_debit", - "sofort" + "us_bank_account" ] }, - "setup_attempt_payment_method_details_au_becs_debit": { + "mandate_paypal": { "description": "", - "properties": {}, - "title": "setup_attempt_payment_method_details_au_becs_debit", + "properties": { + "billing_agreement_id": { + "description": "The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "payer_id": { + "description": "PayPal account PayerID. This identifier uniquely identifies the PayPal customer.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "mandate_paypal", "type": "object", "x-expandableFields": [] }, - "setup_attempt_payment_method_details_bacs_debit": { + "mandate_revolut_pay": { "description": "", "properties": {}, - "title": "setup_attempt_payment_method_details_bacs_debit", + "title": "mandate_revolut_pay", "type": "object", "x-expandableFields": [] }, - "setup_attempt_payment_method_details_bancontact": { + "mandate_sepa_debit": { "description": "", "properties": { - "bank_code": { - "description": "Bank code of bank associated with the bank account.", + "reference": { + "description": "The unique reference of the mandate.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "bank_name": { - "description": "Name of the bank associated with the bank account.", + "url": { + "description": "The URL of the mandate. This URL generally contains sensitive information about the customer and should be shared with them exclusively.", "maxLength": 5000, - "nullable": true, "type": "string" + } + }, + "required": ["reference", "url"], + "title": "mandate_sepa_debit", + "type": "object", + "x-expandableFields": [] + }, + "mandate_single_use": { + "description": "", + "properties": { + "amount": { + "description": "The amount of the payment on a single use mandate.", + "type": "integer" }, - "bic": { - "description": "Bank Identifier Code of the bank associated with the bank account.", + "currency": { + "description": "The currency of the payment on a single use mandate.", + "type": "string" + } + }, + "required": ["amount", "currency"], + "title": "mandate_single_use", + "type": "object", + "x-expandableFields": [] + }, + "mandate_us_bank_account": { + "description": "", + "properties": { + "collection_method": { + "description": "Mandate collection method", + "enum": ["paper"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "mandate_us_bank_account", + "type": "object", + "x-expandableFields": [] + }, + "networks": { + "description": "", + "properties": { + "available": { + "description": "All available networks for the card.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "preferred": { + "description": "The preferred network for co-branded cards. Can be `cartes_bancaires`, `mastercard`, `visa` or `invalid_preference` if requested network is not valid for the card.", "maxLength": 5000, "nullable": true, "type": "string" + } + }, + "required": ["available"], + "title": "networks", + "type": "object", + "x-expandableFields": [] + }, + "notification_event_data": { + "description": "", + "properties": { + "object": { + "description": "Object containing the API resource relevant to the event. For example, an `invoice.created` event will have a full [invoice object](https://stripe.com/docs/api#invoice_object) as the value of the object key.", + "type": "object" }, - "generated_sepa_debit": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" - } - ], - "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } - }, - "generated_sepa_debit_mandate": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/mandate" - } - ], - "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", + "previous_attributes": { + "description": "Object containing the names of the updated attributes and their values prior to the event (only included in events of type `*.updated`). If an array attribute has any updated elements, this object contains the entire array. In Stripe API versions 2017-04-06 or earlier, an updated array attribute in this object includes only the updated array elements.", + "type": "object" + } + }, + "required": ["object"], + "title": "NotificationEventData", + "type": "object", + "x-expandableFields": [] + }, + "notification_event_request": { + "description": "", + "properties": { + "id": { + "description": "ID of the API request that caused the event. If null, the event was automatic (e.g., Stripe's automatic subscription handling). Request logs are available in the [dashboard](https://dashboard.stripe.com/logs), but currently not in the API.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/mandate" - } - ] - } + "type": "string" }, - "iban_last4": { - "description": "Last four characters of the IBAN.", + "idempotency_key": { + "description": "The idempotency key transmitted during the request, if any. *Note: This property is populated only for events on or after May 23, 2017*.", "maxLength": 5000, "nullable": true, "type": "string" - }, - "preferred_language": { - "description": "Preferred language of the Bancontact authorization page that the customer is redirected to.\nCan be one of `en`, `de`, `fr`, or `nl`", - "enum": ["de", "en", "fr", "nl"], + } + }, + "title": "NotificationEventRequest", + "type": "object", + "x-expandableFields": [] + }, + "offline_acceptance": { + "description": "", + "properties": {}, + "title": "offline_acceptance", + "type": "object", + "x-expandableFields": [] + }, + "online_acceptance": { + "description": "", + "properties": { + "ip_address": { + "description": "The customer accepts the mandate from this IP address.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "verified_name": { - "description": "Owner's verified full name. Values are verified or provided by Bancontact directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "user_agent": { + "description": "The customer accepts the mandate using the user agent of the browser.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "setup_attempt_payment_method_details_bancontact", + "title": "online_acceptance", "type": "object", - "x-expandableFields": [ - "generated_sepa_debit", - "generated_sepa_debit_mandate" - ] + "x-expandableFields": [] }, - "setup_attempt_payment_method_details_card": { + "outbound_payments_payment_method_details": { "description": "", "properties": { - "three_d_secure": { - "anyOf": [ - { - "$ref": "#/components/schemas/three_d_secure_details" - } - ], - "description": "Populated if this authorization used 3D Secure authentication.", - "nullable": true + "billing_details": { + "$ref": "#/components/schemas/treasury_shared_resource_billing_details" + }, + "financial_account": { + "$ref": "#/components/schemas/outbound_payments_payment_method_details_financial_account" + }, + "type": { + "description": "The type of the payment method used in the OutboundPayment.", + "enum": ["financial_account", "us_bank_account"], + "type": "string" + }, + "us_bank_account": { + "$ref": "#/components/schemas/outbound_payments_payment_method_details_us_bank_account" } }, - "title": "setup_attempt_payment_method_details_card", + "required": ["billing_details", "type"], + "title": "OutboundPaymentsPaymentMethodDetails", "type": "object", - "x-expandableFields": ["three_d_secure"] + "x-expandableFields": [ + "billing_details", + "financial_account", + "us_bank_account" + ] }, - "setup_attempt_payment_method_details_card_present": { + "outbound_payments_payment_method_details_financial_account": { "description": "", "properties": { - "generated_card": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" - } - ], - "description": "The ID of the Card PaymentMethod which was generated by this SetupAttempt.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } + "id": { + "description": "Token of the FinancialAccount.", + "maxLength": 5000, + "type": "string" + }, + "network": { + "description": "The rails used to send funds.", + "enum": ["stripe"], + "type": "string" } }, - "title": "setup_attempt_payment_method_details_card_present", + "required": ["id", "network"], + "title": "outbound_payments_payment_method_details_financial_account", "type": "object", - "x-expandableFields": ["generated_card"] + "x-expandableFields": [] }, - "setup_attempt_payment_method_details_ideal": { + "outbound_payments_payment_method_details_us_bank_account": { "description": "", "properties": { - "bank": { - "description": "The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, or `van_lanschot`.", - "enum": [ - "abn_amro", - "asn_bank", - "bunq", - "handelsbanken", - "ing", - "knab", - "moneyou", - "rabobank", - "regiobank", - "revolut", - "sns_bank", - "triodos_bank", - "van_lanschot" - ], + "account_holder_type": { + "description": "Account holder type: individual or company.", + "enum": ["company", "individual"], "nullable": true, "type": "string" }, - "bic": { - "description": "The Bank Identifier Code of the customer's bank.", - "enum": [ - "ABNANL2A", - "ASNBNL21", - "BUNQNL2A", - "FVLBNL22", - "HANDNL2A", - "INGBNL2A", - "KNABNL2H", - "MOYONL21", - "RABONL2U", - "RBRBNL21", - "REVOLT21", - "SNSBNL2A", - "TRIONL2U" - ], + "account_type": { + "description": "Account type: checkings or savings. Defaults to checking if omitted.", + "enum": ["checking", "savings"], "nullable": true, "type": "string" }, - "generated_sepa_debit": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" - } - ], - "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", + "bank_name": { + "description": "Name of the bank associated with the bank account.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } + "type": "string" }, - "generated_sepa_debit_mandate": { + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "mandate": { "anyOf": [ { "maxLength": 5000, @@ -19230,8 +22207,7 @@ "$ref": "#/components/schemas/mandate" } ], - "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", - "nullable": true, + "description": "ID of the mandate used to make this payment.", "x-expansionResources": { "oneOf": [ { @@ -19240,39 +22216,56 @@ ] } }, - "iban_last4": { - "description": "Last four characters of the IBAN.", - "maxLength": 5000, - "nullable": true, + "network": { + "description": "The network rails used. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.", + "enum": ["ach", "us_domestic_wire"], "type": "string" }, - "verified_name": { - "description": "Owner's verified full name. Values are verified or provided by iDEAL directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "routing_number": { + "description": "Routing number of the bank account.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "setup_attempt_payment_method_details_ideal", + "required": ["network"], + "title": "outbound_payments_payment_method_details_us_bank_account", "type": "object", - "x-expandableFields": [ - "generated_sepa_debit", - "generated_sepa_debit_mandate" - ] + "x-expandableFields": ["mandate"] }, - "setup_attempt_payment_method_details_sepa_debit": { + "outbound_transfers_payment_method_details": { "description": "", - "properties": {}, - "title": "setup_attempt_payment_method_details_sepa_debit", + "properties": { + "billing_details": { + "$ref": "#/components/schemas/treasury_shared_resource_billing_details" + }, + "type": { + "description": "The type of the payment method used in the OutboundTransfer.", + "enum": ["us_bank_account"], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "$ref": "#/components/schemas/outbound_transfers_payment_method_details_us_bank_account" + } + }, + "required": ["billing_details", "type"], + "title": "OutboundTransfersPaymentMethodDetails", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["billing_details", "us_bank_account"] }, - "setup_attempt_payment_method_details_sofort": { + "outbound_transfers_payment_method_details_us_bank_account": { "description": "", "properties": { - "bank_code": { - "description": "Bank code of bank associated with the bank account.", - "maxLength": 5000, + "account_holder_type": { + "description": "Account holder type: individual or company.", + "enum": ["company", "individual"], + "nullable": true, + "type": "string" + }, + "account_type": { + "description": "Account type: checkings or savings. Defaults to checking if omitted.", + "enum": ["checking", "savings"], "nullable": true, "type": "string" }, @@ -19282,33 +22275,19 @@ "nullable": true, "type": "string" }, - "bic": { - "description": "Bank Identifier Code of the bank associated with the bank account.", + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", "maxLength": 5000, "nullable": true, "type": "string" }, - "generated_sepa_debit": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" - } - ], - "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } + "type": "string" }, - "generated_sepa_debit_mandate": { + "mandate": { "anyOf": [ { "maxLength": 5000, @@ -19318,8 +22297,7 @@ "$ref": "#/components/schemas/mandate" } ], - "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", - "nullable": true, + "description": "ID of the mandate used to make this payment.", "x-expansionResources": { "oneOf": [ { @@ -19328,35 +22306,285 @@ ] } }, - "iban_last4": { - "description": "Last four characters of the IBAN.", + "network": { + "description": "The network rails used. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.", + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "routing_number": { + "description": "Routing number of the bank account.", "maxLength": 5000, "nullable": true, "type": "string" + } + }, + "required": ["network"], + "title": "outbound_transfers_payment_method_details_us_bank_account", + "type": "object", + "x-expandableFields": ["mandate"] + }, + "package_dimensions": { + "description": "", + "properties": { + "height": { + "description": "Height, in inches.", + "type": "number" }, - "preferred_language": { - "description": "Preferred language of the Sofort authorization page that the customer is redirected to.\nCan be one of `en`, `de`, `fr`, or `nl`", - "enum": ["de", "en", "fr", "nl"], + "length": { + "description": "Length, in inches.", + "type": "number" + }, + "weight": { + "description": "Weight, in ounces.", + "type": "number" + }, + "width": { + "description": "Width, in inches.", + "type": "number" + } + }, + "required": ["height", "length", "weight", "width"], + "title": "PackageDimensions", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_amount_details": { + "description": "", + "properties": { + "tip": { + "$ref": "#/components/schemas/payment_flows_amount_details_resource_tip" + } + }, + "title": "PaymentFlowsAmountDetails", + "type": "object", + "x-expandableFields": ["tip"] + }, + "payment_flows_amount_details_resource_tip": { + "description": "", + "properties": { + "amount": { + "description": "Portion of the amount that corresponds to a tip.", + "type": "integer" + } + }, + "title": "PaymentFlowsAmountDetailsResourceTip", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_automatic_payment_methods_payment_intent": { + "description": "", + "properties": { + "allow_redirects": { + "description": "Controls whether this PaymentIntent will accept redirect-based payment methods.\n\nRedirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the payment.", + "enum": ["always", "never"], + "type": "string" + }, + "enabled": { + "description": "Automatically calculates compatible payment methods", + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "PaymentFlowsAutomaticPaymentMethodsPaymentIntent", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_automatic_payment_methods_setup_intent": { + "description": "", + "properties": { + "allow_redirects": { + "description": "Controls whether this SetupIntent will accept redirect-based payment methods.\n\nRedirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/setup_intents/confirm) this SetupIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the setup.", + "enum": ["always", "never"], + "type": "string" + }, + "enabled": { + "description": "Automatically calculates compatible payment methods", "nullable": true, + "type": "boolean" + } + }, + "title": "PaymentFlowsAutomaticPaymentMethodsSetupIntent", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_installment_options": { + "description": "", + "properties": { + "enabled": { + "type": "boolean" + }, + "plan": { + "$ref": "#/components/schemas/payment_method_details_card_installments_plan" + } + }, + "required": ["enabled"], + "title": "PaymentFlowsInstallmentOptions", + "type": "object", + "x-expandableFields": ["plan"] + }, + "payment_flows_private_payment_methods_alipay": { + "description": "", + "properties": {}, + "title": "PaymentFlowsPrivatePaymentMethodsAlipay", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_private_payment_methods_alipay_details": { + "description": "", + "properties": { + "buyer_id": { + "description": "Uniquely identifies this particular Alipay account. You can use this attribute to check whether two Alipay accounts are the same.", + "maxLength": 5000, "type": "string" }, - "verified_name": { - "description": "Owner's verified full name. Values are verified or provided by Sofort directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "fingerprint": { + "description": "Uniquely identifies this particular Alipay account. You can use this attribute to check whether two Alipay accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "transaction_id": { + "description": "Transaction ID of this particular Alipay transaction.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "setup_attempt_payment_method_details_sofort", + "title": "PaymentFlowsPrivatePaymentMethodsAlipayDetails", "type": "object", - "x-expandableFields": [ - "generated_sepa_debit", - "generated_sepa_debit_mandate" - ] + "x-expandableFields": [] }, - "setup_intent": { - "description": "A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.\nFor example, you could use a SetupIntent to set up and save your customer's card without immediately collecting a payment.\nLater, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.\n\nCreate a SetupIntent as soon as you're ready to collect your customer's payment credentials.\nDo not maintain long-lived, unconfirmed SetupIntents as they may no longer be valid.\nThe SetupIntent then transitions through multiple [statuses](https://stripe.com/docs/payments/intents#intent-statuses) as it guides\nyou through the setup process.\n\nSuccessful SetupIntents result in payment credentials that are optimized for future payments.\nFor example, cardholders in [certain regions](/guides/strong-customer-authentication) may need to be run through\n[Strong Customer Authentication](https://stripe.com/docs/strong-customer-authentication) at the time of payment method collection\nin order to streamline later [off-session payments](https://stripe.com/docs/payments/setup-intents).\nIf the SetupIntent is used with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer), upon success,\nit will automatically attach the resulting payment method to that Customer.\nWe recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on\nPaymentIntents to save payment methods in order to prevent saving invalid or unoptimized payment methods.\n\nBy using SetupIntents, you ensure that your customers experience the minimum set of required friction,\neven as regulations change over time.\n\nRelated guide: [Setup Intents API](https://stripe.com/docs/payments/setup-intents).", + "payment_flows_private_payment_methods_card_details_api_resource_enterprise_features_extended_authorization_extended_authorization": { + "description": "", + "properties": { + "status": { + "description": "Indicates whether or not the capture window is extended beyond the standard authorization.", + "enum": ["disabled", "enabled"], + "type": "string" + } + }, + "required": ["status"], + "title": "PaymentFlowsPrivatePaymentMethodsCardDetailsAPIResourceEnterpriseFeaturesExtendedAuthorizationExtendedAuthorization", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_private_payment_methods_card_details_api_resource_enterprise_features_incremental_authorization_incremental_authorization": { + "description": "", + "properties": { + "status": { + "description": "Indicates whether or not the incremental authorization feature is supported.", + "enum": ["available", "unavailable"], + "type": "string" + } + }, + "required": ["status"], + "title": "PaymentFlowsPrivatePaymentMethodsCardDetailsAPIResourceEnterpriseFeaturesIncrementalAuthorizationIncrementalAuthorization", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_private_payment_methods_card_details_api_resource_enterprise_features_overcapture_overcapture": { + "description": "", + "properties": { + "maximum_amount_capturable": { + "description": "The maximum amount that can be captured.", + "type": "integer" + }, + "status": { + "description": "Indicates whether or not the authorized amount can be over-captured.", + "enum": ["available", "unavailable"], + "type": "string" + } + }, + "required": ["maximum_amount_capturable", "status"], + "title": "PaymentFlowsPrivatePaymentMethodsCardDetailsAPIResourceEnterpriseFeaturesOvercaptureOvercapture", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_private_payment_methods_card_details_api_resource_multicapture": { + "description": "", + "properties": { + "status": { + "description": "Indicates whether or not multiple captures are supported.", + "enum": ["available", "unavailable"], + "type": "string" + } + }, + "required": ["status"], + "title": "PaymentFlowsPrivatePaymentMethodsCardDetailsAPIResourceMulticapture", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_private_payment_methods_card_present_common_wallet": { + "description": "", + "properties": { + "type": { + "description": "The type of mobile wallet, one of `apple_pay`, `google_pay`, `samsung_pay`, or `unknown`.", + "enum": ["apple_pay", "google_pay", "samsung_pay", "unknown"], + "type": "string" + } + }, + "required": ["type"], + "title": "PaymentFlowsPrivatePaymentMethodsCardPresentCommonWallet", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_private_payment_methods_klarna_dob": { + "description": "", + "properties": { + "day": { + "description": "The day of birth, between 1 and 31.", + "nullable": true, + "type": "integer" + }, + "month": { + "description": "The month of birth, between 1 and 12.", + "nullable": true, + "type": "integer" + }, + "year": { + "description": "The four-digit year of birth.", + "nullable": true, + "type": "integer" + } + }, + "title": "PaymentFlowsPrivatePaymentMethodsKlarnaDOB", + "type": "object", + "x-expandableFields": [] + }, + "payment_flows_private_payment_methods_us_bank_account_linked_account_options_filters": { + "description": "", + "properties": { + "account_subcategories": { + "description": "The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.", + "items": { + "enum": ["checking", "savings"], + "type": "string" + }, + "type": "array" + } + }, + "title": "PaymentFlowsPrivatePaymentMethodsUsBankAccountLinkedAccountOptionsFilters", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent": { + "description": "A PaymentIntent guides you through the process of collecting a payment from your customer.\nWe recommend that you create exactly one PaymentIntent for each order or\ncustomer session in your system. You can reference the PaymentIntent later to\nsee the history of payment attempts for a particular session.\n\nA PaymentIntent transitions through\n[multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses)\nthroughout its lifetime as it interfaces with Stripe.js to perform\nauthentication flows and ultimately creates at most one successful charge.\n\nRelated guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents)", "properties": { + "amount": { + "description": "Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", + "type": "integer" + }, + "amount_capturable": { + "description": "Amount that can be captured from this PaymentIntent.", + "type": "integer" + }, + "amount_details": { + "$ref": "#/components/schemas/payment_flows_amount_details" + }, + "amount_received": { + "description": "Amount that this PaymentIntent collects.", + "type": "integer" + }, "application": { "anyOf": [ { @@ -19367,7 +22595,7 @@ "$ref": "#/components/schemas/application" } ], - "description": "ID of the Connect application that created the SetupIntent.", + "description": "ID of the Connect application that created the PaymentIntent.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -19377,23 +22605,65 @@ ] } }, - "cancellation_reason": { - "description": "Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`.", - "enum": ["abandoned", "duplicate", "requested_by_customer"], - "nullable": true, - "type": "string" - }, - "client_secret": { - "description": "The client secret of this SetupIntent. Used for client-side retrieval using a publishable key.\n\nThe client secret can be used to complete payment setup from your frontend. It should not be stored, logged, embedded in URLs, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.", - "maxLength": 5000, + "application_fee_amount": { + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", "nullable": true, - "type": "string" + "type": "integer" + }, + "automatic_payment_methods": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_flows_automatic_payment_methods_payment_intent" + } + ], + "description": "Settings to configure compatible payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods)", + "nullable": true + }, + "canceled_at": { + "description": "Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "cancellation_reason": { + "description": "Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, or `automatic`).", + "enum": [ + "abandoned", + "automatic", + "duplicate", + "failed_invoice", + "fraudulent", + "requested_by_customer", + "void_invoice" + ], + "nullable": true, + "type": "string" + }, + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["automatic", "automatic_async", "manual"], + "type": "string" + }, + "client_secret": { + "description": "The client secret of this PaymentIntent. Used for client-side retrieval using a publishable key. \n\nThe client secret can be used to complete a payment from your frontend. It should not be stored, logged, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.\n\nRefer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment?ui=elements) and learn about how `client_secret` should be handled.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "confirmation_method": { + "description": "Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.", + "enum": ["automatic", "manual"], + "type": "string" }, "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", "type": "integer" }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, "customer": { "anyOf": [ { @@ -19407,7 +22677,7 @@ "$ref": "#/components/schemas/deleted_customer" } ], - "description": "ID of the Customer this SetupIntent belongs to, if one exists.\n\nIf present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.", + "description": "ID of the Customer this PaymentIntent belongs to, if one exists.\n\nPayment methods attached to other Customers cannot be used with this PaymentIntent.\n\nIf [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -19431,80 +22701,79 @@ "maxLength": 5000, "type": "string" }, - "last_setup_error": { - "anyOf": [ - { - "$ref": "#/components/schemas/api_errors" - } - ], - "description": "The error encountered in the previous SetupIntent confirmation.", - "nullable": true - }, - "latest_attempt": { + "invoice": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/setup_attempt" + "$ref": "#/components/schemas/invoice" } ], - "description": "The most recent SetupAttempt for this SetupIntent.", + "description": "ID of the invoice that created this PaymentIntent, if it exists.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/setup_attempt" + "$ref": "#/components/schemas/invoice" } ] } }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "last_payment_error": { + "anyOf": [ + { + "$ref": "#/components/schemas/api_errors" + } + ], + "description": "The payment error encountered in the previous PaymentIntent confirmation. It will be cleared if the PaymentIntent is later updated for any reason.", + "nullable": true }, - "mandate": { + "latest_charge": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/mandate" + "$ref": "#/components/schemas/charge" } ], - "description": "ID of the multi use Mandate generated by the SetupIntent.", + "description": "ID of the latest [Charge object](https://stripe.com/docs/api/charges) created by this PaymentIntent. This property is `null` until PaymentIntent confirmation is attempted.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/mandate" + "$ref": "#/components/schemas/charge" } ] } }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, "metadata": { "additionalProperties": { "maxLength": 500, "type": "string" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Learn more about [storing information in metadata](https://stripe.com/docs/payments/payment-intents/creating-payment-intents#storing-information-in-metadata).", "type": "object" }, "next_action": { "anyOf": [ { - "$ref": "#/components/schemas/setup_intent_next_action" + "$ref": "#/components/schemas/payment_intent_next_action" } ], - "description": "If present, this property tells you what actions you need to take in order for your customer to continue payment setup.", + "description": "If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source.", "nullable": true }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["setup_intent"], + "enum": ["payment_intent"], "type": "string" }, "on_behalf_of": { @@ -19517,7 +22786,7 @@ "$ref": "#/components/schemas/account" } ], - "description": "The account (if any) for which the setup is intended.", + "description": "The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -19537,7 +22806,7 @@ "$ref": "#/components/schemas/payment_method" } ], - "description": "ID of the payment method used with this SetupIntent.", + "description": "ID of the payment method used in this PaymentIntent.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -19547,110 +22816,270 @@ ] } }, + "payment_method_configuration_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_config_biz_payment_method_configuration_details" + } + ], + "description": "Information about the payment method configuration used for this PaymentIntent.", + "nullable": true + }, "payment_method_options": { "anyOf": [ { - "$ref": "#/components/schemas/setup_intent_payment_method_options" + "$ref": "#/components/schemas/payment_intent_payment_method_options" } ], - "description": "Payment-method-specific configuration for this SetupIntent.", + "description": "Payment-method-specific configuration for this PaymentIntent.", "nullable": true }, "payment_method_types": { - "description": "The list of payment method types (e.g. card) that this SetupIntent is allowed to set up.", + "description": "The list of payment method types (e.g. card) that this PaymentIntent is allowed to use.", "items": { "maxLength": 5000, "type": "string" }, "type": "array" }, - "single_use_mandate": { + "processing": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_processing" + } + ], + "description": "If present, this property tells you about the processing state of the payment.", + "nullable": true + }, + "receipt_email": { + "description": "Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "review": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/mandate" + "$ref": "#/components/schemas/review" } ], - "description": "ID of the single_use Mandate generated by the SetupIntent.", + "description": "ID of the review associated with this PaymentIntent, if any.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/mandate" + "$ref": "#/components/schemas/review" } ] } }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["off_session", "on_session"], + "nullable": true, + "type": "string" + }, + "shipping": { + "anyOf": [ + { + "$ref": "#/components/schemas/shipping" + } + ], + "description": "Shipping information for this PaymentIntent.", + "nullable": true + }, + "statement_descriptor": { + "description": "Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).\n\nSetting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "statement_descriptor_suffix": { + "description": "Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, "status": { - "description": "[Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`.", + "description": "Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses).", "enum": [ "canceled", "processing", "requires_action", + "requires_capture", "requires_confirmation", "requires_payment_method", "succeeded" ], "type": "string" }, - "usage": { - "description": "Indicates how the payment method is intended to be used in the future.\n\nUse `on_session` if you intend to only reuse the payment method when the customer is in your checkout flow. Use `off_session` if your customer may or may not be in your checkout flow. If not provided, this value defaults to `off_session`.", + "transfer_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/transfer_data" + } + ], + "description": "The data that automatically creates a Transfer after the payment finalizes. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "nullable": true + }, + "transfer_group": { + "description": "A string that identifies the resulting payment as part of a group. Learn more about the [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers).", "maxLength": 5000, + "nullable": true, "type": "string" } }, "required": [ + "amount", + "capture_method", + "confirmation_method", "created", + "currency", "id", "livemode", "object", "payment_method_types", - "status", - "usage" + "status" ], - "title": "SetupIntent", + "title": "PaymentIntent", "type": "object", "x-expandableFields": [ + "amount_details", "application", + "automatic_payment_methods", "customer", - "last_setup_error", - "latest_attempt", - "mandate", + "invoice", + "last_payment_error", + "latest_charge", "next_action", "on_behalf_of", "payment_method", + "payment_method_configuration_details", "payment_method_options", - "single_use_mandate" + "processing", + "review", + "shipping", + "transfer_data" ], - "x-resourceId": "setup_intent" + "x-resourceId": "payment_intent" }, - "setup_intent_next_action": { + "payment_intent_card_processing": { + "description": "", + "properties": { + "customer_notification": { + "$ref": "#/components/schemas/payment_intent_processing_customer_notification" + } + }, + "title": "PaymentIntentCardProcessing", + "type": "object", + "x-expandableFields": ["customer_notification"] + }, + "payment_intent_next_action": { "description": "", "properties": { + "alipay_handle_redirect": { + "$ref": "#/components/schemas/payment_intent_next_action_alipay_handle_redirect" + }, + "boleto_display_details": { + "$ref": "#/components/schemas/payment_intent_next_action_boleto" + }, + "card_await_notification": { + "$ref": "#/components/schemas/payment_intent_next_action_card_await_notification" + }, + "cashapp_handle_redirect_or_display_qr_code": { + "$ref": "#/components/schemas/payment_intent_next_action_cashapp_handle_redirect_or_display_qr_code" + }, + "display_bank_transfer_instructions": { + "$ref": "#/components/schemas/payment_intent_next_action_display_bank_transfer_instructions" + }, + "konbini_display_details": { + "$ref": "#/components/schemas/payment_intent_next_action_konbini" + }, + "multibanco_display_details": { + "$ref": "#/components/schemas/payment_intent_next_action_display_multibanco_details" + }, + "oxxo_display_details": { + "$ref": "#/components/schemas/payment_intent_next_action_display_oxxo_details" + }, + "paynow_display_qr_code": { + "$ref": "#/components/schemas/payment_intent_next_action_paynow_display_qr_code" + }, + "pix_display_qr_code": { + "$ref": "#/components/schemas/payment_intent_next_action_pix_display_qr_code" + }, + "promptpay_display_qr_code": { + "$ref": "#/components/schemas/payment_intent_next_action_promptpay_display_qr_code" + }, "redirect_to_url": { - "$ref": "#/components/schemas/setup_intent_next_action_redirect_to_url" + "$ref": "#/components/schemas/payment_intent_next_action_redirect_to_url" + }, + "swish_handle_redirect_or_display_qr_code": { + "$ref": "#/components/schemas/payment_intent_next_action_swish_handle_redirect_or_display_qr_code" }, "type": { - "description": "Type of the next action to perform, one of `redirect_to_url`, `use_stripe_sdk`, `alipay_handle_redirect`, or `oxxo_display_details`.", + "description": "Type of the next action to perform, one of `redirect_to_url`, `use_stripe_sdk`, `alipay_handle_redirect`, `oxxo_display_details`, or `verify_with_microdeposits`.", "maxLength": 5000, "type": "string" }, "use_stripe_sdk": { - "description": "When confirming a SetupIntent with Stripe.js, Stripe.js depends on the contents of this dictionary to invoke authentication flows. The shape of the contents is subject to change and is only intended to be used by Stripe.js.", + "description": "When confirming a PaymentIntent with Stripe.js, Stripe.js depends on the contents of this dictionary to invoke authentication flows. The shape of the contents is subject to change and is only intended to be used by Stripe.js.", "type": "object" + }, + "verify_with_microdeposits": { + "$ref": "#/components/schemas/payment_intent_next_action_verify_with_microdeposits" + }, + "wechat_pay_display_qr_code": { + "$ref": "#/components/schemas/payment_intent_next_action_wechat_pay_display_qr_code" + }, + "wechat_pay_redirect_to_android_app": { + "$ref": "#/components/schemas/payment_intent_next_action_wechat_pay_redirect_to_android_app" + }, + "wechat_pay_redirect_to_ios_app": { + "$ref": "#/components/schemas/payment_intent_next_action_wechat_pay_redirect_to_ios_app" } }, "required": ["type"], - "title": "SetupIntentNextAction", + "title": "PaymentIntentNextAction", "type": "object", - "x-expandableFields": ["redirect_to_url"] + "x-expandableFields": [ + "alipay_handle_redirect", + "boleto_display_details", + "card_await_notification", + "cashapp_handle_redirect_or_display_qr_code", + "display_bank_transfer_instructions", + "konbini_display_details", + "multibanco_display_details", + "oxxo_display_details", + "paynow_display_qr_code", + "pix_display_qr_code", + "promptpay_display_qr_code", + "redirect_to_url", + "swish_handle_redirect_or_display_qr_code", + "verify_with_microdeposits", + "wechat_pay_display_qr_code", + "wechat_pay_redirect_to_android_app", + "wechat_pay_redirect_to_ios_app" + ] }, - "setup_intent_next_action_redirect_to_url": { + "payment_intent_next_action_alipay_handle_redirect": { "description": "", "properties": { + "native_data": { + "description": "The native data to be used with Alipay SDK you must redirect your customer to in order to authenticate the payment in an Android App.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "native_url": { + "description": "The native URL you must redirect your customer to in order to authenticate the payment in an iOS App.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, "return_url": { "description": "If the customer does not exit their browser while authenticating, they will be redirected to this specified URL after completion.", "maxLength": 5000, @@ -19658,5050 +23087,41330 @@ "type": "string" }, "url": { - "description": "The URL you must redirect your customer to in order to authenticate.", + "description": "The URL you must redirect your customer to in order to authenticate the payment.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "title": "SetupIntentNextActionRedirectToUrl", + "title": "PaymentIntentNextActionAlipayHandleRedirect", "type": "object", "x-expandableFields": [] }, - "setup_intent_payment_method_options": { + "payment_intent_next_action_boleto": { "description": "", "properties": { - "card": { - "$ref": "#/components/schemas/setup_intent_payment_method_options_card" + "expires_at": { + "description": "The timestamp after which the boleto expires.", + "format": "unix-time", + "nullable": true, + "type": "integer" }, - "sepa_debit": { - "$ref": "#/components/schemas/setup_intent_payment_method_options_sepa_debit" + "hosted_voucher_url": { + "description": "The URL to the hosted boleto voucher page, which allows customers to view the boleto voucher.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "number": { + "description": "The boleto number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "pdf": { + "description": "The URL to the downloadable boleto voucher PDF.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "title": "SetupIntentPaymentMethodOptions", + "title": "payment_intent_next_action_boleto", "type": "object", - "x-expandableFields": ["card", "sepa_debit"] + "x-expandableFields": [] }, - "setup_intent_payment_method_options_card": { + "payment_intent_next_action_card_await_notification": { "description": "", "properties": { - "request_three_d_secure": { - "description": "We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Permitted values include: `automatic` or `any`. If not provided, defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.", - "enum": ["any", "automatic", "challenge_only"], + "charge_attempt_at": { + "description": "The time that payment will be attempted. If customer approval is required, they need to provide approval before this time.", + "format": "unix-time", "nullable": true, - "type": "string" + "type": "integer" + }, + "customer_approval_required": { + "description": "For payments greater than INR 15000, the customer must provide explicit approval of the payment with their bank. For payments of lower amount, no customer action is required.", + "nullable": true, + "type": "boolean" } }, - "title": "setup_intent_payment_method_options_card", + "title": "PaymentIntentNextActionCardAwaitNotification", "type": "object", "x-expandableFields": [] }, - "setup_intent_payment_method_options_mandate_options_sepa_debit": { - "description": "", - "properties": {}, - "title": "setup_intent_payment_method_options_mandate_options_sepa_debit", - "type": "object", - "x-expandableFields": [] - }, - "setup_intent_payment_method_options_sepa_debit": { + "payment_intent_next_action_cashapp_handle_redirect_or_display_qr_code": { "description": "", "properties": { - "mandate_options": { - "$ref": "#/components/schemas/setup_intent_payment_method_options_mandate_options_sepa_debit" + "hosted_instructions_url": { + "description": "The URL to the hosted Cash App Pay instructions page, which allows customers to view the QR code, and supports QR code refreshing on expiration.", + "maxLength": 5000, + "type": "string" + }, + "mobile_auth_url": { + "description": "The url for mobile redirect based auth", + "maxLength": 5000, + "type": "string" + }, + "qr_code": { + "$ref": "#/components/schemas/payment_intent_next_action_cashapp_qr_code" } }, - "title": "setup_intent_payment_method_options_sepa_debit", + "required": ["hosted_instructions_url", "mobile_auth_url", "qr_code"], + "title": "PaymentIntentNextActionCashappHandleRedirectOrDisplayQrCode", "type": "object", - "x-expandableFields": ["mandate_options"] + "x-expandableFields": ["qr_code"] }, - "shipping": { + "payment_intent_next_action_cashapp_qr_code": { "description": "", "properties": { - "address": { - "$ref": "#/components/schemas/address" + "expires_at": { + "description": "The date (unix timestamp) when the QR code expires.", + "format": "unix-time", + "type": "integer" }, - "carrier": { - "description": "The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.", + "image_url_png": { + "description": "The image_url_png string used to render QR code", "maxLength": 5000, - "nullable": true, "type": "string" }, - "name": { - "description": "Recipient name.", + "image_url_svg": { + "description": "The image_url_svg string used to render QR code", "maxLength": 5000, + "type": "string" + } + }, + "required": ["expires_at", "image_url_png", "image_url_svg"], + "title": "PaymentIntentNextActionCashappQRCode", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_next_action_display_bank_transfer_instructions": { + "description": "", + "properties": { + "amount_remaining": { + "description": "The remaining amount that needs to be transferred to complete the payment.", + "nullable": true, + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "nullable": true, "type": "string" }, - "phone": { - "description": "Recipient phone (including extension).", + "financial_addresses": { + "description": "A list of financial addresses that can be used to fund the customer balance", + "items": { + "$ref": "#/components/schemas/funding_instructions_bank_transfer_financial_address" + }, + "type": "array" + }, + "hosted_instructions_url": { + "description": "A link to a hosted page that guides your customer through completing the transfer.", "maxLength": 5000, "nullable": true, "type": "string" }, - "tracking_number": { - "description": "The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.", + "reference": { + "description": "A string identifying this payment. Instruct your customer to include this code in the reference or memo field of their bank transfer.", "maxLength": 5000, "nullable": true, "type": "string" + }, + "type": { + "description": "Type of bank transfer", + "enum": [ + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "mx_bank_transfer", + "us_bank_transfer" + ], + "type": "string", + "x-stripeBypassValidation": true } }, - "title": "Shipping", + "required": ["type"], + "title": "PaymentIntentNextActionDisplayBankTransferInstructions", "type": "object", - "x-expandableFields": ["address"] + "x-expandableFields": ["financial_addresses"] }, - "shipping_method": { + "payment_intent_next_action_display_multibanco_details": { "description": "", "properties": { - "amount": { - "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount for the line item.", - "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "entity": { + "description": "Entity number associated with this Multibanco payment.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "delivery_estimate": { - "anyOf": [ - { - "$ref": "#/components/schemas/delivery_estimate" - } - ], - "description": "The estimated delivery date for the given shipping method. Can be either a specific date or a range.", - "nullable": true + "expires_at": { + "description": "The timestamp at which the Multibanco voucher expires.", + "format": "unix-time", + "nullable": true, + "type": "integer" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "hosted_voucher_url": { + "description": "The URL for the hosted Multibanco voucher page, which allows customers to view a Multibanco voucher.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "reference": { + "description": "Reference number associated with this Multibanco payment.", "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["amount", "currency", "description", "id"], - "title": "ShippingMethod", + "title": "PaymentIntentNextActionDisplayMultibancoDetails", "type": "object", - "x-expandableFields": ["delivery_estimate"] + "x-expandableFields": [] }, - "sigma_scheduled_query_run_error": { + "payment_intent_next_action_display_oxxo_details": { "description": "", "properties": { - "message": { - "description": "Information about the run failure.", + "expires_after": { + "description": "The timestamp after which the OXXO voucher expires.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "hosted_voucher_url": { + "description": "The URL for the hosted OXXO voucher page, which allows customers to view and print an OXXO voucher.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "number": { + "description": "OXXO reference number.", "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["message"], - "title": "SigmaScheduledQueryRunError", + "title": "PaymentIntentNextActionDisplayOxxoDetails", "type": "object", "x-expandableFields": [] }, - "sku": { - "description": "Stores representations of [stock keeping units](https://en.wikipedia.org/wiki/Stock_keeping_unit).\nSKUs describe specific product variations, taking into account any combination of: attributes,\ncurrency, and cost. For example, a product may be a T-shirt, whereas a specific SKU represents\nthe `size: large`, `color: red` version of that shirt.\n\nCan also be used to manage inventory.\n\nRelated guide: [Tax, Shipping, and Inventory](https://stripe.com/docs/orders).", + "payment_intent_next_action_konbini": { + "description": "", "properties": { - "active": { - "description": "Whether the SKU is available for purchase.", - "type": "boolean" - }, - "attributes": { - "additionalProperties": { - "maxLength": 5000, - "type": "string" - }, - "description": "A dictionary of attributes and values for the attributes defined by the product. If, for example, a product's attributes are `[\"size\", \"gender\"]`, a valid SKU has the following dictionary of attributes: `{\"size\": \"Medium\", \"gender\": \"Unisex\"}`.", - "type": "object" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "expires_at": { + "description": "The timestamp at which the pending Konbini payment expires.", "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "hosted_voucher_url": { + "description": "The URL for the Konbini payment instructions page, which allows customers to view and print a Konbini voucher.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "stores": { + "$ref": "#/components/schemas/payment_intent_next_action_konbini_stores" + } + }, + "required": ["expires_at", "stores"], + "title": "payment_intent_next_action_konbini", + "type": "object", + "x-expandableFields": ["stores"] + }, + "payment_intent_next_action_konbini_familymart": { + "description": "", + "properties": { + "confirmation_number": { + "description": "The confirmation number.", "maxLength": 5000, "type": "string" }, - "image": { - "description": "The URL of an image for this SKU, meant to be displayable to the customer.", - "maxLength": 2048, - "nullable": true, + "payment_code": { + "description": "The payment code.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["payment_code"], + "title": "payment_intent_next_action_konbini_familymart", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_next_action_konbini_lawson": { + "description": "", + "properties": { + "confirmation_number": { + "description": "The confirmation number.", + "maxLength": 5000, "type": "string" }, - "inventory": { - "$ref": "#/components/schemas/inventory" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" + "payment_code": { + "description": "The payment code.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["payment_code"], + "title": "payment_intent_next_action_konbini_lawson", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_next_action_konbini_ministop": { + "description": "", + "properties": { + "confirmation_number": { + "description": "The confirmation number.", + "maxLength": 5000, + "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["sku"], + "payment_code": { + "description": "The payment code.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["payment_code"], + "title": "payment_intent_next_action_konbini_ministop", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_next_action_konbini_seicomart": { + "description": "", + "properties": { + "confirmation_number": { + "description": "The confirmation number.", + "maxLength": 5000, "type": "string" }, - "package_dimensions": { + "payment_code": { + "description": "The payment code.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["payment_code"], + "title": "payment_intent_next_action_konbini_seicomart", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_next_action_konbini_stores": { + "description": "", + "properties": { + "familymart": { "anyOf": [ { - "$ref": "#/components/schemas/package_dimensions" + "$ref": "#/components/schemas/payment_intent_next_action_konbini_familymart" } ], - "description": "The dimensions of this SKU for shipping purposes.", + "description": "FamilyMart instruction details.", "nullable": true }, - "price": { - "description": "The cost of the item as a positive integer in the smallest currency unit (that is, 100 cents to charge $1.00, or 100 to charge ¥100, Japanese Yen being a zero-decimal currency).", - "type": "integer" - }, - "product": { + "lawson": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, + "$ref": "#/components/schemas/payment_intent_next_action_konbini_lawson" + } + ], + "description": "Lawson instruction details.", + "nullable": true + }, + "ministop": { + "anyOf": [ { - "$ref": "#/components/schemas/product" + "$ref": "#/components/schemas/payment_intent_next_action_konbini_ministop" } ], - "description": "The ID of the product this SKU is associated with. The product must be currently active.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/product" - } - ] - } + "description": "Ministop instruction details.", + "nullable": true }, - "updated": { - "description": "Time at which the object was last updated. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "seicomart": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_next_action_konbini_seicomart" + } + ], + "description": "Seicomart instruction details.", + "nullable": true } }, - "required": [ - "active", - "attributes", - "created", - "currency", - "id", - "inventory", - "livemode", - "metadata", - "object", - "price", - "product", - "updated" - ], - "title": "Sku", + "title": "payment_intent_next_action_konbini_stores", "type": "object", - "x-expandableFields": ["inventory", "package_dimensions", "product"], - "x-resourceId": "sku" + "x-expandableFields": ["familymart", "lawson", "ministop", "seicomart"] }, - "source": { - "description": "`Source` objects allow you to accept a variety of payment methods. They\nrepresent a customer's payment instrument, and can be used with the Stripe API\njust like a `Card` object: once chargeable, they can be charged, or can be\nattached to customers.\n\nRelated guides: [Sources API](https://stripe.com/docs/sources) and [Sources & Customers](https://stripe.com/docs/sources/customers).", + "payment_intent_next_action_paynow_display_qr_code": { + "description": "", "properties": { - "ach_credit_transfer": { - "$ref": "#/components/schemas/source_type_ach_credit_transfer" - }, - "ach_debit": { - "$ref": "#/components/schemas/source_type_ach_debit" - }, - "alipay": { - "$ref": "#/components/schemas/source_type_alipay" - }, - "amount": { - "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources.", - "nullable": true, - "type": "integer" - }, - "au_becs_debit": { - "$ref": "#/components/schemas/source_type_au_becs_debit" - }, - "bancontact": { - "$ref": "#/components/schemas/source_type_bancontact" - }, - "card": { - "$ref": "#/components/schemas/source_type_card" - }, - "card_present": { - "$ref": "#/components/schemas/source_type_card_present" - }, - "client_secret": { - "description": "The client secret of the source. Used for client-side retrieval using a publishable key.", + "data": { + "description": "The raw data string used to generate QR code, it should be used together with QR code library.", "maxLength": 5000, "type": "string" }, - "code_verification": { - "$ref": "#/components/schemas/source_code_verification_flow" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready. Required for `single_use` sources.", + "hosted_instructions_url": { + "description": "The URL to the hosted PayNow instructions page, which allows customers to view the PayNow QR code.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "customer": { - "description": "The ID of the customer to which this source is attached. This will not be present when the source has not been attached to a customer.", + "image_url_png": { + "description": "The image_url_png string used to render QR code", "maxLength": 5000, "type": "string" }, - "eps": { - "$ref": "#/components/schemas/source_type_eps" - }, - "flow": { - "description": "The authentication `flow` of the source. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`.", + "image_url_svg": { + "description": "The image_url_svg string used to render QR code", "maxLength": 5000, "type": "string" - }, - "giropay": { - "$ref": "#/components/schemas/source_type_giropay" - }, - "id": { - "description": "Unique identifier for the object.", + } + }, + "required": ["data", "image_url_png", "image_url_svg"], + "title": "PaymentIntentNextActionPaynowDisplayQrCode", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_next_action_pix_display_qr_code": { + "description": "", + "properties": { + "data": { + "description": "The raw data string used to generate QR code, it should be used together with QR code library.", "maxLength": 5000, "type": "string" }, - "ideal": { - "$ref": "#/components/schemas/source_type_ideal" - }, - "klarna": { - "$ref": "#/components/schemas/source_type_klarna" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "nullable": true, - "type": "object" - }, - "multibanco": { - "$ref": "#/components/schemas/source_type_multibanco" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["source"], - "type": "string" - }, - "owner": { - "anyOf": [ - { - "$ref": "#/components/schemas/source_owner" - } - ], - "description": "Information about the owner of the payment instrument that may be used or required by particular source types.", - "nullable": true - }, - "p24": { - "$ref": "#/components/schemas/source_type_p24" - }, - "receiver": { - "$ref": "#/components/schemas/source_receiver_flow" - }, - "redirect": { - "$ref": "#/components/schemas/source_redirect_flow" - }, - "sepa_debit": { - "$ref": "#/components/schemas/source_type_sepa_debit" - }, - "sofort": { - "$ref": "#/components/schemas/source_type_sofort" - }, - "source_order": { - "$ref": "#/components/schemas/source_order" - }, - "statement_descriptor": { - "description": "Extra information about a source. This will appear on your customer's statement every time you charge the source.", - "maxLength": 5000, - "nullable": true, - "type": "string" + "expires_at": { + "description": "The date (unix timestamp) when the PIX expires.", + "type": "integer" }, - "status": { - "description": "The status of the source, one of `canceled`, `chargeable`, `consumed`, `failed`, or `pending`. Only `chargeable` sources can be used to create a charge.", + "hosted_instructions_url": { + "description": "The URL to the hosted pix instructions page, which allows customers to view the pix QR code.", "maxLength": 5000, "type": "string" }, - "three_d_secure": { - "$ref": "#/components/schemas/source_type_three_d_secure" - }, - "type": { - "description": "The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used.", - "enum": [ - "ach_credit_transfer", - "ach_debit", - "alipay", - "au_becs_debit", - "bancontact", - "card", - "card_present", - "eps", - "giropay", - "ideal", - "klarna", - "multibanco", - "p24", - "sepa_debit", - "sofort", - "three_d_secure", - "wechat" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "usage": { - "description": "Either `reusable` or `single_use`. Whether this source should be reusable or not. Some source types may or may not be reusable by construction, while others may leave the option at creation. If an incompatible value is passed, an error will be returned.", + "image_url_png": { + "description": "The image_url_png string used to render png QR code", "maxLength": 5000, - "nullable": true, "type": "string" }, - "wechat": { - "$ref": "#/components/schemas/source_type_wechat" - } - }, - "required": [ - "client_secret", - "created", - "flow", - "id", - "livemode", - "object", - "status", - "type" - ], - "title": "Source", - "type": "object", - "x-expandableFields": [ - "code_verification", - "owner", - "receiver", - "redirect", - "source_order" - ], - "x-resourceId": "source" - }, - "source_code_verification_flow": { - "description": "", - "properties": { - "attempts_remaining": { - "description": "The number of attempts remaining to authenticate the source object with a verification code.", - "type": "integer" - }, - "status": { - "description": "The status of the code verification, either `pending` (awaiting verification, `attempts_remaining` should be greater than 0), `succeeded` (successful verification) or `failed` (failed verification, cannot be verified anymore as `attempts_remaining` should be 0).", + "image_url_svg": { + "description": "The image_url_svg string used to render svg QR code", "maxLength": 5000, "type": "string" } }, - "required": ["attempts_remaining", "status"], - "title": "SourceCodeVerificationFlow", + "title": "PaymentIntentNextActionPixDisplayQrCode", "type": "object", "x-expandableFields": [] }, - "source_mandate_notification": { - "description": "Source mandate notifications should be created when a notification related to\na source mandate must be sent to the payer. They will trigger a webhook or\ndeliver an email to the customer.", + "payment_intent_next_action_promptpay_display_qr_code": { + "description": "", "properties": { - "acss_debit": { - "$ref": "#/components/schemas/source_mandate_notification_acss_debit_data" - }, - "amount": { - "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the amount associated with the mandate notification. The amount is expressed in the currency of the underlying source. Required if the notification type is `debit_initiated`.", - "nullable": true, - "type": "integer" - }, - "bacs_debit": { - "$ref": "#/components/schemas/source_mandate_notification_bacs_debit_data" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "id": { - "description": "Unique identifier for the object.", + "data": { + "description": "The raw data string used to generate QR code, it should be used together with QR code library.", "maxLength": 5000, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["source_mandate_notification"], - "type": "string" - }, - "reason": { - "description": "The reason of the mandate notification. Valid reasons are `mandate_confirmed` or `debit_initiated`.", + "hosted_instructions_url": { + "description": "The URL to the hosted PromptPay instructions page, which allows customers to view the PromptPay QR code.", "maxLength": 5000, "type": "string" }, - "sepa_debit": { - "$ref": "#/components/schemas/source_mandate_notification_sepa_debit_data" - }, - "source": { - "$ref": "#/components/schemas/source" - }, - "status": { - "description": "The status of the mandate notification. Valid statuses are `pending` or `submitted`.", + "image_url_png": { + "description": "The PNG path used to render the QR code, can be used as the source in an HTML img tag", "maxLength": 5000, "type": "string" }, - "type": { - "description": "The type of source this mandate notification is attached to. Should be the source type identifier code for the payment method, such as `three_d_secure`.", + "image_url_svg": { + "description": "The SVG path used to render the QR code, can be used as the source in an HTML img tag", "maxLength": 5000, "type": "string" } }, "required": [ - "created", - "id", - "livemode", - "object", - "reason", - "source", - "status", - "type" + "data", + "hosted_instructions_url", + "image_url_png", + "image_url_svg" ], - "title": "SourceMandateNotification", + "title": "PaymentIntentNextActionPromptpayDisplayQrCode", "type": "object", - "x-expandableFields": [ - "acss_debit", - "bacs_debit", - "sepa_debit", - "source" - ], - "x-resourceId": "source_mandate_notification" + "x-expandableFields": [] }, - "source_mandate_notification_acss_debit_data": { + "payment_intent_next_action_redirect_to_url": { "description": "", "properties": { - "statement_descriptor": { - "description": "The statement descriptor associate with the debit.", + "return_url": { + "description": "If the customer does not exit their browser while authenticating, they will be redirected to this specified URL after completion.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "url": { + "description": "The URL you must redirect your customer to in order to authenticate the payment.", "maxLength": 5000, + "nullable": true, "type": "string" } }, - "title": "SourceMandateNotificationAcssDebitData", + "title": "PaymentIntentNextActionRedirectToUrl", "type": "object", "x-expandableFields": [] }, - "source_mandate_notification_bacs_debit_data": { + "payment_intent_next_action_swish_handle_redirect_or_display_qr_code": { "description": "", "properties": { - "last4": { - "description": "Last 4 digits of the account number associated with the debit.", + "hosted_instructions_url": { + "description": "The URL to the hosted Swish instructions page, which allows customers to view the QR code.", "maxLength": 5000, "type": "string" + }, + "qr_code": { + "$ref": "#/components/schemas/payment_intent_next_action_swish_qr_code" } }, - "title": "SourceMandateNotificationBacsDebitData", + "required": ["hosted_instructions_url", "qr_code"], + "title": "PaymentIntentNextActionSwishHandleRedirectOrDisplayQrCode", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["qr_code"] }, - "source_mandate_notification_sepa_debit_data": { + "payment_intent_next_action_swish_qr_code": { "description": "", "properties": { - "creditor_identifier": { - "description": "SEPA creditor ID.", + "data": { + "description": "The raw data string used to generate QR code, it should be used together with QR code library.", "maxLength": 5000, "type": "string" }, - "last4": { - "description": "Last 4 digits of the account number associated with the debit.", + "image_url_png": { + "description": "The image_url_png string used to render QR code", "maxLength": 5000, "type": "string" }, - "mandate_reference": { - "description": "Mandate reference associated with the debit.", + "image_url_svg": { + "description": "The image_url_svg string used to render QR code", "maxLength": 5000, "type": "string" } }, - "title": "SourceMandateNotificationSepaDebitData", + "required": ["data", "image_url_png", "image_url_svg"], + "title": "PaymentIntentNextActionSwishQRCode", "type": "object", "x-expandableFields": [] }, - "source_order": { + "payment_intent_next_action_verify_with_microdeposits": { "description": "", "properties": { - "amount": { - "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount for the order.", + "arrival_date": { + "description": "The timestamp when the microdeposits are expected to land.", + "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "email": { - "description": "The email address of the customer placing the order.", + "hosted_verification_url": { + "description": "The URL for the hosted verification page, which allows customers to verify their bank account.", "maxLength": 5000, "type": "string" }, - "items": { - "description": "List of items constituting the order.", - "items": { - "$ref": "#/components/schemas/source_order_item" - }, + "microdeposit_type": { + "description": "The type of the microdeposit sent to the customer. Used to distinguish between different verification methods.", + "enum": ["amounts", "descriptor_code"], "nullable": true, - "type": "array" - }, - "shipping": { - "$ref": "#/components/schemas/shipping" + "type": "string" } }, - "required": ["amount", "currency"], - "title": "SourceOrder", + "required": ["arrival_date", "hosted_verification_url"], + "title": "PaymentIntentNextActionVerifyWithMicrodeposits", "type": "object", - "x-expandableFields": ["items", "shipping"] + "x-expandableFields": [] }, - "source_order_item": { + "payment_intent_next_action_wechat_pay_display_qr_code": { "description": "", "properties": { - "amount": { - "description": "The amount (price) for this order item.", - "nullable": true, - "type": "integer" - }, - "currency": { - "description": "This currency of this order item. Required when `amount` is present.", + "data": { + "description": "The data being used to generate QR code", "maxLength": 5000, - "nullable": true, "type": "string" }, - "description": { - "description": "Human-readable description for this order item.", + "hosted_instructions_url": { + "description": "The URL to the hosted WeChat Pay instructions page, which allows customers to view the WeChat Pay QR code.", "maxLength": 5000, - "nullable": true, "type": "string" }, - "parent": { - "description": "The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU).", + "image_data_url": { + "description": "The base64 image data for a pre-generated QR code", "maxLength": 5000, - "nullable": true, "type": "string" }, - "quantity": { - "description": "The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.", - "type": "integer" + "image_url_png": { + "description": "The image_url_png string used to render QR code", + "maxLength": 5000, + "type": "string" }, - "type": { - "description": "The type of this order item. Must be `sku`, `tax`, or `shipping`.", + "image_url_svg": { + "description": "The image_url_svg string used to render QR code", "maxLength": 5000, - "nullable": true, "type": "string" } }, - "title": "SourceOrderItem", + "required": [ + "data", + "hosted_instructions_url", + "image_data_url", + "image_url_png", + "image_url_svg" + ], + "title": "PaymentIntentNextActionWechatPayDisplayQrCode", "type": "object", "x-expandableFields": [] }, - "source_owner": { + "payment_intent_next_action_wechat_pay_redirect_to_android_app": { "description": "", "properties": { - "address": { - "anyOf": [ - { - "$ref": "#/components/schemas/address" - } - ], - "description": "Owner's address.", - "nullable": true - }, - "email": { - "description": "Owner's email address.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "name": { - "description": "Owner's full name.", + "app_id": { + "description": "app_id is the APP ID registered on WeChat open platform", "maxLength": 5000, - "nullable": true, "type": "string" }, - "phone": { - "description": "Owner's phone number (including extension).", + "nonce_str": { + "description": "nonce_str is a random string", "maxLength": 5000, - "nullable": true, "type": "string" }, - "verified_address": { - "anyOf": [ - { - "$ref": "#/components/schemas/address" - } - ], - "description": "Verified owner's address. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "nullable": true - }, - "verified_email": { - "description": "Verified owner's email address. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "package": { + "description": "package is static value", "maxLength": 5000, - "nullable": true, "type": "string" }, - "verified_name": { - "description": "Verified owner's full name. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "partner_id": { + "description": "an unique merchant ID assigned by WeChat Pay", "maxLength": 5000, - "nullable": true, "type": "string" }, - "verified_phone": { - "description": "Verified owner's phone number (including extension). Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.", - "maxLength": 5000, - "nullable": true, - "type": "string" - } - }, - "title": "SourceOwner", - "type": "object", - "x-expandableFields": ["address", "verified_address"] - }, - "source_receiver_flow": { - "description": "", - "properties": { - "address": { - "description": "The address of the receiver source. This is the value that should be communicated to the customer to send their funds to.", + "prepay_id": { + "description": "an unique trading ID assigned by WeChat Pay", "maxLength": 5000, - "nullable": true, "type": "string" }, - "amount_charged": { - "description": "The total amount that was moved to your balance. This is almost always equal to the amount charged. In rare cases when customers deposit excess funds and we are unable to refund those, those funds get moved to your balance and show up in amount_charged as well. The amount charged is expressed in the source's currency.", - "type": "integer" - }, - "amount_received": { - "description": "The total amount received by the receiver source. `amount_received = amount_returned + amount_charged` should be true for consumed sources unless customers deposit excess funds. The amount received is expressed in the source's currency.", - "type": "integer" - }, - "amount_returned": { - "description": "The total amount that was returned to the customer. The amount returned is expressed in the source's currency.", - "type": "integer" - }, - "refund_attributes_method": { - "description": "Type of refund attribute method, one of `email`, `manual`, or `none`.", + "sign": { + "description": "A signature", "maxLength": 5000, "type": "string" }, - "refund_attributes_status": { - "description": "Type of refund attribute status, one of `missing`, `requested`, or `available`.", + "timestamp": { + "description": "Specifies the current time in epoch format", "maxLength": 5000, "type": "string" } }, "required": [ - "amount_charged", - "amount_received", - "amount_returned", - "refund_attributes_method", - "refund_attributes_status" + "app_id", + "nonce_str", + "package", + "partner_id", + "prepay_id", + "sign", + "timestamp" ], - "title": "SourceReceiverFlow", + "title": "PaymentIntentNextActionWechatPayRedirectToAndroidApp", "type": "object", "x-expandableFields": [] }, - "source_redirect_flow": { + "payment_intent_next_action_wechat_pay_redirect_to_ios_app": { "description": "", "properties": { - "failure_reason": { - "description": "The failure reason for the redirect, either `user_abort` (the customer aborted or dropped out of the redirect flow), `declined` (the authentication failed or the transaction was declined), or `processing_error` (the redirect failed due to a technical error). Present only if the redirect status is `failed`.", - "maxLength": 5000, - "nullable": true, - "type": "string" - }, - "return_url": { - "description": "The URL you provide to redirect the customer to after they authenticated their payment.", - "maxLength": 5000, - "type": "string" - }, - "status": { - "description": "The status of the redirect, either `pending` (ready to be used by your customer to authenticate the transaction), `succeeded` (succesful authentication, cannot be reused) or `not_required` (redirect should not be used) or `failed` (failed authentication, cannot be reused).", + "native_url": { + "description": "An universal link that redirect to WeChat Pay app", "maxLength": 5000, "type": "string" - }, - "url": { - "description": "The URL provided to you to redirect a customer to as part of a `redirect` authentication flow.", - "maxLength": 2048, - "type": "string" } }, - "required": ["return_url", "status", "url"], - "title": "SourceRedirectFlow", + "required": ["native_url"], + "title": "PaymentIntentNextActionWechatPayRedirectToIOSApp", "type": "object", "x-expandableFields": [] }, - "source_transaction": { - "description": "Some payment methods have no required amount that a customer must send.\nCustomers can be instructed to send any amount, and it can be made up of\nmultiple transactions. As such, sources can have multiple associated\ntransactions.", + "payment_intent_payment_method_options": { + "description": "", "properties": { - "ach_credit_transfer": { - "$ref": "#/components/schemas/source_transaction_ach_credit_transfer_data" + "acss_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_acss_debit" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "amount": { - "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the amount your customer has pushed to the receiver.", - "type": "integer" + "affirm": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_affirm" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "chf_credit_transfer": { - "$ref": "#/components/schemas/source_transaction_chf_credit_transfer_data" + "afterpay_clearpay": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_afterpay_clearpay" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "alipay": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_alipay" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" + "amazon_pay": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_amazon_pay" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "gbp_credit_transfer": { - "$ref": "#/components/schemas/source_transaction_gbp_credit_transfer_data" + "au_becs_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_au_becs_debit" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" + "bacs_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_bacs_debit" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "bancontact": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_bancontact" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["source_transaction"], - "type": "string" + "blik": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_blik" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "paper_check": { - "$ref": "#/components/schemas/source_transaction_paper_check_data" + "boleto": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_boleto" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "sepa_credit_transfer": { - "$ref": "#/components/schemas/source_transaction_sepa_credit_transfer_data" + "card": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_card" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "source": { - "description": "The ID of the source this transaction is attached to.", - "maxLength": 5000, - "type": "string" + "card_present": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_card_present" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "status": { - "description": "The status of the transaction, one of `succeeded`, `pending`, or `failed`.", - "maxLength": 5000, - "type": "string" + "cashapp": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_cashapp" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] }, - "type": { - "description": "The type of source this transaction is attached to.", - "enum": [ - "ach_credit_transfer", - "ach_debit", - "alipay", - "bancontact", - "card", - "card_present", - "eps", - "giropay", - "ideal", - "klarna", - "multibanco", - "p24", - "sepa_debit", - "sofort", - "three_d_secure", - "wechat" - ], - "type": "string" + "customer_balance": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_customer_balance" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "eps": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_eps" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "fpx": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_fpx" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "giropay": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_giropay" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "grabpay": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_grabpay" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "ideal": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_ideal" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "interac_present": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_interac_present" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "klarna": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_klarna" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "konbini": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_konbini" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "link": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_link" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "mobilepay": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_mobilepay" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "multibanco": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_multibanco" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "oxxo": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_oxxo" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "p24": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_p24" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "paynow": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_paynow" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "paypal": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_paypal" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "pix": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_pix" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "promptpay": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_promptpay" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "revolut_pay": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_revolut_pay" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_sepa_debit" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "sofort": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_sofort" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "swish": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_swish" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "twint": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_twint" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_intent_payment_method_options_us_bank_account" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "wechat_pay": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_wechat_pay" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] + }, + "zip": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_zip" + }, + { + "$ref": "#/components/schemas/payment_intent_type_specific_payment_method_options_client" + } + ] } }, - "required": [ - "amount", - "created", - "currency", - "id", - "livemode", - "object", - "source", - "status", - "type" - ], - "title": "SourceTransaction", + "title": "PaymentIntentPaymentMethodOptions", "type": "object", "x-expandableFields": [ - "ach_credit_transfer", - "chf_credit_transfer", - "gbp_credit_transfer", - "paper_check", - "sepa_credit_transfer" - ], - "x-resourceId": "source_transaction" + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "card_present", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "interac_present", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ] }, - "source_transaction_ach_credit_transfer_data": { + "payment_intent_payment_method_options_acss_debit": { "description": "", "properties": { - "customer_data": { - "description": "Customer data associated with the transfer.", - "maxLength": 5000, - "type": "string" - }, - "fingerprint": { - "description": "Bank account fingerprint associated with the transfer.", - "maxLength": 5000, - "type": "string" + "mandate_options": { + "$ref": "#/components/schemas/payment_intent_payment_method_options_mandate_options_acss_debit" }, - "last4": { - "description": "Last 4 digits of the account number associated with the transfer.", - "maxLength": 5000, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], "type": "string" }, - "routing_number": { - "description": "Routing number associated with the transfer.", - "maxLength": 5000, + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_intent_payment_method_options_acss_debit", + "type": "object", + "x-expandableFields": ["mandate_options"] + }, + "payment_intent_payment_method_options_au_becs_debit": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], "type": "string" } }, - "title": "SourceTransactionAchCreditTransferData", + "title": "payment_intent_payment_method_options_au_becs_debit", "type": "object", "x-expandableFields": [] }, - "source_transaction_chf_credit_transfer_data": { + "payment_intent_payment_method_options_bacs_debit": { "description": "", "properties": { - "reference": { - "description": "Reference associated with the transfer.", - "maxLength": 5000, - "type": "string" - }, - "sender_address_country": { - "description": "Sender's country address.", - "maxLength": 5000, - "type": "string" - }, - "sender_address_line1": { - "description": "Sender's line 1 address.", - "maxLength": 5000, - "type": "string" - }, - "sender_iban": { - "description": "Sender's bank account IBAN.", - "maxLength": 5000, - "type": "string" + "mandate_options": { + "$ref": "#/components/schemas/payment_intent_payment_method_options_mandate_options_bacs_debit" }, - "sender_name": { - "description": "Sender's name.", - "maxLength": 5000, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], "type": "string" } }, - "title": "SourceTransactionChfCreditTransferData", + "title": "payment_intent_payment_method_options_bacs_debit", + "type": "object", + "x-expandableFields": ["mandate_options"] + }, + "payment_intent_payment_method_options_blik": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_intent_payment_method_options_blik", "type": "object", "x-expandableFields": [] }, - "source_transaction_gbp_credit_transfer_data": { + "payment_intent_payment_method_options_card": { "description": "", "properties": { - "fingerprint": { - "description": "Bank account fingerprint associated with the Stripe owned bank account receiving the transfer.", - "maxLength": 5000, + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], "type": "string" }, - "funding_method": { - "description": "The credit transfer rails the sender used to push this transfer. The possible rails are: Faster Payments, BACS, CHAPS, and wire transfers. Currently only Faster Payments is supported.", - "maxLength": 5000, + "installments": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_card_installments" + } + ], + "description": "Installment details for this payment (Mexico only).\n\nFor more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).", + "nullable": true + }, + "mandate_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_options_card_mandate_options" + } + ], + "description": "Configuration options for setting up an eMandate for cards issued in India.", + "nullable": true + }, + "network": { + "description": "Selected network to process this payment intent on. Depends on the available networks of the card attached to the payment intent. Can be only set confirm-time.", + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "nullable": true, "type": "string" }, - "last4": { - "description": "Last 4 digits of sender account number associated with the transfer.", - "maxLength": 5000, + "request_extended_authorization": { + "description": "Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.", + "enum": ["if_available", "never"], "type": "string" }, - "reference": { - "description": "Sender entered arbitrary information about the transfer.", - "maxLength": 5000, + "request_incremental_authorization": { + "description": "Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.", + "enum": ["if_available", "never"], "type": "string" }, - "sender_account_number": { - "description": "Sender account number associated with the transfer.", - "maxLength": 5000, + "request_multicapture": { + "description": "Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.", + "enum": ["if_available", "never"], "type": "string" }, - "sender_name": { - "description": "Sender name associated with the transfer.", + "request_overcapture": { + "description": "Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.", + "enum": ["if_available", "never"], + "type": "string" + }, + "request_three_d_secure": { + "description": "We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.", + "enum": ["any", "automatic", "challenge"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "require_cvc_recollection": { + "description": "When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).", + "type": "boolean" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], + "type": "string" + }, + "statement_descriptor_suffix_kana": { + "description": "Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.", "maxLength": 5000, "type": "string" }, - "sender_sort_code": { - "description": "Sender sort code associated with the transfer.", + "statement_descriptor_suffix_kanji": { + "description": "Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.", "maxLength": 5000, "type": "string" } }, - "title": "SourceTransactionGbpCreditTransferData", + "title": "payment_intent_payment_method_options_card", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["installments", "mandate_options"] }, - "source_transaction_paper_check_data": { + "payment_intent_payment_method_options_eps": { "description": "", "properties": { - "available_at": { - "description": "Time at which the deposited funds will be available for use. Measured in seconds since the Unix epoch.", - "maxLength": 5000, - "type": "string" - }, - "invoices": { - "description": "Comma-separated list of invoice IDs associated with the paper check.", - "maxLength": 5000, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], "type": "string" } }, - "title": "SourceTransactionPaperCheckData", + "title": "payment_intent_payment_method_options_eps", "type": "object", "x-expandableFields": [] }, - "source_transaction_sepa_credit_transfer_data": { + "payment_intent_payment_method_options_link": { "description": "", "properties": { - "reference": { - "description": "Reference associated with the transfer.", - "maxLength": 5000, - "type": "string" - }, - "sender_iban": { - "description": "Sender's bank account IBAN.", - "maxLength": 5000, + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], "type": "string" }, - "sender_name": { - "description": "Sender's name.", - "maxLength": 5000, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], "type": "string" } }, - "title": "SourceTransactionSepaCreditTransferData", + "title": "payment_intent_payment_method_options_link", "type": "object", "x-expandableFields": [] }, - "source_type_ach_credit_transfer": { + "payment_intent_payment_method_options_mandate_options_acss_debit": { + "description": "", "properties": { - "account_number": { - "nullable": true, - "type": "string" - }, - "bank_name": { - "nullable": true, + "custom_mandate_url": { + "description": "A URL for custom mandate text", + "maxLength": 5000, "type": "string" }, - "fingerprint": { + "interval_description": { + "description": "Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "refund_account_holder_name": { + "payment_schedule": { + "description": "Payment schedule for the mandate.", + "enum": ["combined", "interval", "sporadic"], "nullable": true, "type": "string" }, - "refund_account_holder_type": { + "transaction_type": { + "description": "Transaction type of the mandate.", + "enum": ["business", "personal"], "nullable": true, "type": "string" - }, - "refund_routing_number": { - "nullable": true, + } + }, + "title": "payment_intent_payment_method_options_mandate_options_acss_debit", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_payment_method_options_mandate_options_bacs_debit": { + "description": "", + "properties": {}, + "title": "payment_intent_payment_method_options_mandate_options_bacs_debit", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_payment_method_options_mandate_options_sepa_debit": { + "description": "", + "properties": {}, + "title": "payment_intent_payment_method_options_mandate_options_sepa_debit", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_payment_method_options_mobilepay": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], "type": "string" }, - "routing_number": { - "nullable": true, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], "type": "string" + } + }, + "title": "payment_intent_payment_method_options_mobilepay", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_payment_method_options_sepa_debit": { + "description": "", + "properties": { + "mandate_options": { + "$ref": "#/components/schemas/payment_intent_payment_method_options_mandate_options_sepa_debit" }, - "swift_code": { - "nullable": true, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], "type": "string" } }, - "type": "object" + "title": "payment_intent_payment_method_options_sepa_debit", + "type": "object", + "x-expandableFields": ["mandate_options"] }, - "source_type_ach_debit": { + "payment_intent_payment_method_options_swish": { + "description": "", "properties": { - "bank_name": { + "reference": { + "description": "The order ID displayed in the Swish app after the payment is authorized.", + "maxLength": 35, "nullable": true, "type": "string" }, - "country": { - "nullable": true, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], "type": "string" + } + }, + "title": "payment_intent_payment_method_options_swish", + "type": "object", + "x-expandableFields": [] + }, + "payment_intent_payment_method_options_us_bank_account": { + "description": "", + "properties": { + "financial_connections": { + "$ref": "#/components/schemas/linked_account_options_us_bank_account" }, - "fingerprint": { - "nullable": true, - "type": "string" + "mandate_options": { + "$ref": "#/components/schemas/payment_method_options_us_bank_account_mandate_options" }, - "last4": { - "nullable": true, + "preferred_settlement_speed": { + "description": "Preferred transaction settlement speed", + "enum": ["fastest", "standard"], "type": "string" }, - "routing_number": { - "nullable": true, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], "type": "string" }, - "type": { - "nullable": true, - "type": "string" - } + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } }, - "type": "object" + "title": "payment_intent_payment_method_options_us_bank_account", + "type": "object", + "x-expandableFields": ["financial_connections", "mandate_options"] }, - "source_type_alipay": { + "payment_intent_processing": { + "description": "", "properties": { - "data_string": { - "nullable": true, - "type": "string" - }, - "native_url": { - "nullable": true, - "type": "string" + "card": { + "$ref": "#/components/schemas/payment_intent_card_processing" }, - "statement_descriptor": { - "nullable": true, + "type": { + "description": "Type of the payment method for which payment is in `processing` state, one of `card`.", + "enum": ["card"], "type": "string" } }, - "type": "object" + "required": ["type"], + "title": "PaymentIntentProcessing", + "type": "object", + "x-expandableFields": ["card"] }, - "source_type_au_becs_debit": { + "payment_intent_processing_customer_notification": { + "description": "", "properties": { - "bsb_number": { - "nullable": true, - "type": "string" - }, - "fingerprint": { + "approval_requested": { + "description": "Whether customer approval has been requested for this payment. For payments greater than INR 15000 or mandate amount, the customer must provide explicit approval of the payment with their bank.", "nullable": true, - "type": "string" + "type": "boolean" }, - "last4": { + "completes_at": { + "description": "If customer approval is required, they need to provide approval before this time.", + "format": "unix-time", "nullable": true, - "type": "string" + "type": "integer" } }, - "type": "object" + "title": "PaymentIntentProcessingCustomerNotification", + "type": "object", + "x-expandableFields": [] }, - "source_type_bancontact": { + "payment_intent_type_specific_payment_method_options_client": { + "description": "", "properties": { - "bank_code": { - "nullable": true, + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual", "manual_preferred"], "type": "string" }, - "bank_name": { - "nullable": true, - "type": "string" + "installments": { + "$ref": "#/components/schemas/payment_flows_installment_options" }, - "bic": { - "nullable": true, - "type": "string" + "request_incremental_authorization_support": { + "description": "Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.", + "type": "boolean" }, - "iban_last4": { - "nullable": true, - "type": "string" + "require_cvc_recollection": { + "description": "When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).", + "type": "boolean" }, - "preferred_language": { - "nullable": true, - "type": "string" + "routing": { + "$ref": "#/components/schemas/payment_method_options_card_present_routing" }, - "statement_descriptor": { - "nullable": true, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], "type": "string" + }, + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true } }, - "type": "object" + "title": "PaymentIntentTypeSpecificPaymentMethodOptionsClient", + "type": "object", + "x-expandableFields": ["installments", "routing"] }, - "source_type_card": { + "payment_link": { + "description": "A payment link is a shareable URL that will take your customers to a hosted payment page. A payment link can be shared and used multiple times.\n\nWhen a customer opens a payment link it will open a new [checkout session](https://stripe.com/docs/api/checkout/sessions) to render the payment page. You can use [checkout session events](https://stripe.com/docs/api/events/types#event_types-checkout.session.completed) to track payments through payment links.\n\nRelated guide: [Payment Links API](https://stripe.com/docs/payment-links)", "properties": { - "address_line1_check": { - "nullable": true, - "type": "string" - }, - "address_zip_check": { - "nullable": true, - "type": "string" - }, - "brand": { - "nullable": true, - "type": "string" + "active": { + "description": "Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.", + "type": "boolean" }, - "country": { - "nullable": true, - "type": "string" + "after_completion": { + "$ref": "#/components/schemas/payment_links_resource_after_completion" }, - "cvc_check": { - "nullable": true, - "type": "string" + "allow_promotion_codes": { + "description": "Whether user redeemable promotion codes are enabled.", + "type": "boolean" }, - "dynamic_last4": { + "application": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" + } + ], + "description": "The ID of the Connect application that created the Payment Link.", "nullable": true, - "type": "string" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" + } + ] + } }, - "exp_month": { + "application_fee_amount": { + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account.", "nullable": true, "type": "integer" }, - "exp_year": { + "application_fee_percent": { + "description": "This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account.", "nullable": true, - "type": "integer" - }, - "fingerprint": { - "type": "string" + "type": "number" }, - "funding": { - "nullable": true, - "type": "string" + "automatic_tax": { + "$ref": "#/components/schemas/payment_links_resource_automatic_tax" }, - "last4": { - "nullable": true, + "billing_address_collection": { + "description": "Configuration for collecting the customer's billing address. Defaults to `auto`.", + "enum": ["auto", "required"], "type": "string" }, - "name": { - "nullable": true, - "type": "string" + "consent_collection": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_consent_collection" + } + ], + "description": "When set, provides configuration to gather active consent from customers.", + "nullable": true }, - "three_d_secure": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, - "tokenization_method": { - "nullable": true, - "type": "string" - } - }, - "type": "object" - }, - "source_type_card_present": { - "properties": { - "application_cryptogram": { - "type": "string" + "custom_fields": { + "description": "Collect additional information from your customer using custom fields. Up to 3 fields are supported.", + "items": { + "$ref": "#/components/schemas/payment_links_resource_custom_fields" + }, + "type": "array" }, - "application_preferred_name": { - "type": "string" + "custom_text": { + "$ref": "#/components/schemas/payment_links_resource_custom_text" }, - "authorization_code": { - "nullable": true, + "customer_creation": { + "description": "Configuration for Customer creation during checkout.", + "enum": ["always", "if_required"], "type": "string" }, - "authorization_response_code": { + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, "type": "string" }, - "brand": { + "inactive_message": { + "description": "The custom message to be displayed to a customer when a payment link is no longer active.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "country": { - "nullable": true, - "type": "string" + "invoice_creation": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_invoice_creation" + } + ], + "description": "Configuration for creating invoice for payment mode payment links.", + "nullable": true }, - "cvm_type": { - "type": "string" + "line_items": { + "description": "The line items representing what is being sold.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PaymentLinksResourceListLineItems", + "type": "object", + "x-expandableFields": ["data"] }, - "data_type": { - "nullable": true, - "type": "string" + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" }, - "dedicated_file_name": { - "type": "string" + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" }, - "emv_auth_data": { + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["payment_link"], "type": "string" }, - "evidence_customer_signature": { + "on_behalf_of": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account on behalf of which to charge. See the [Connect documentation](https://support.stripe.com/questions/sending-invoices-on-behalf-of-connected-accounts) for details.", "nullable": true, - "type": "string" + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } }, - "evidence_transaction_certificate": { - "nullable": true, - "type": "string" + "payment_intent_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_payment_intent_data" + } + ], + "description": "Indicates the parameters to be passed to PaymentIntent creation during checkout.", + "nullable": true }, - "exp_month": { - "nullable": true, - "type": "integer" + "payment_method_collection": { + "description": "Configuration for collecting a payment method during checkout. Defaults to `always`.", + "enum": ["always", "if_required"], + "type": "string" }, - "exp_year": { + "payment_method_types": { + "description": "The list of payment method types that customers can use. When `null`, Stripe will dynamically show relevant payment methods you've enabled in your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).", + "items": { + "enum": [ + "affirm", + "afterpay_clearpay", + "alipay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "cashapp", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, "nullable": true, - "type": "integer" + "type": "array" }, - "fingerprint": { - "type": "string" + "phone_number_collection": { + "$ref": "#/components/schemas/payment_links_resource_phone_number_collection" }, - "funding": { - "nullable": true, - "type": "string" + "restrictions": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_restrictions" + } + ], + "description": "Settings that restrict the usage of a payment link.", + "nullable": true }, - "last4": { - "nullable": true, - "type": "string" + "shipping_address_collection": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_shipping_address_collection" + } + ], + "description": "Configuration for collecting the customer's shipping address.", + "nullable": true }, - "pos_device_id": { - "nullable": true, - "type": "string" + "shipping_options": { + "description": "The shipping rate options applied to the session.", + "items": { + "$ref": "#/components/schemas/payment_links_resource_shipping_option" + }, + "type": "array" }, - "pos_entry_mode": { + "submit_type": { + "description": "Indicates the type of transaction being performed which customizes relevant text on the page, such as the submit button.", + "enum": ["auto", "book", "donate", "pay"], "type": "string" }, - "read_method": { - "nullable": true, - "type": "string" + "subscription_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_subscription_data" + } + ], + "description": "When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.", + "nullable": true }, - "reader": { - "nullable": true, - "type": "string" + "tax_id_collection": { + "$ref": "#/components/schemas/payment_links_resource_tax_id_collection" }, - "terminal_verification_results": { - "type": "string" + "transfer_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_transfer_data" + } + ], + "description": "The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.", + "nullable": true }, - "transaction_status_information": { + "url": { + "description": "The public URL that can be shared with customers.", + "maxLength": 5000, "type": "string" } }, - "type": "object" + "required": [ + "active", + "after_completion", + "allow_promotion_codes", + "automatic_tax", + "billing_address_collection", + "currency", + "custom_fields", + "custom_text", + "customer_creation", + "id", + "livemode", + "metadata", + "object", + "payment_method_collection", + "phone_number_collection", + "shipping_options", + "submit_type", + "tax_id_collection", + "url" + ], + "title": "PaymentLink", + "type": "object", + "x-expandableFields": [ + "after_completion", + "application", + "automatic_tax", + "consent_collection", + "custom_fields", + "custom_text", + "invoice_creation", + "line_items", + "on_behalf_of", + "payment_intent_data", + "phone_number_collection", + "restrictions", + "shipping_address_collection", + "shipping_options", + "subscription_data", + "tax_id_collection", + "transfer_data" + ], + "x-resourceId": "payment_link" }, - "source_type_eps": { + "payment_links_resource_after_completion": { + "description": "", "properties": { - "reference": { - "nullable": true, - "type": "string" + "hosted_confirmation": { + "$ref": "#/components/schemas/payment_links_resource_completion_behavior_confirmation_page" }, - "statement_descriptor": { - "nullable": true, + "redirect": { + "$ref": "#/components/schemas/payment_links_resource_completion_behavior_redirect" + }, + "type": { + "description": "The specified behavior after the purchase is complete.", + "enum": ["hosted_confirmation", "redirect"], "type": "string" } }, - "type": "object" + "required": ["type"], + "title": "PaymentLinksResourceAfterCompletion", + "type": "object", + "x-expandableFields": ["hosted_confirmation", "redirect"] }, - "source_type_giropay": { + "payment_links_resource_automatic_tax": { + "description": "", "properties": { - "bank_code": { - "nullable": true, - "type": "string" - }, - "bank_name": { - "nullable": true, - "type": "string" + "enabled": { + "description": "If `true`, tax will be calculated automatically using the customer's location.", + "type": "boolean" }, - "bic": { - "nullable": true, - "type": "string" + "liability": { + "anyOf": [ + { + "$ref": "#/components/schemas/connect_account_reference" + } + ], + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "nullable": true + } + }, + "required": ["enabled"], + "title": "PaymentLinksResourceAutomaticTax", + "type": "object", + "x-expandableFields": ["liability"] + }, + "payment_links_resource_completed_sessions": { + "description": "", + "properties": { + "count": { + "description": "The current number of checkout sessions that have been completed on the payment link which count towards the `completed_sessions` restriction to be met.", + "type": "integer" }, - "statement_descriptor": { - "nullable": true, - "type": "string" + "limit": { + "description": "The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.", + "type": "integer" } }, - "type": "object" + "required": ["count", "limit"], + "title": "PaymentLinksResourceCompletedSessions", + "type": "object", + "x-expandableFields": [] }, - "source_type_ideal": { + "payment_links_resource_completion_behavior_confirmation_page": { + "description": "", "properties": { - "bank": { + "custom_message": { + "description": "The custom message that is displayed to the customer after the purchase is complete.", + "maxLength": 5000, "nullable": true, "type": "string" - }, - "bic": { - "nullable": true, + } + }, + "title": "PaymentLinksResourceCompletionBehaviorConfirmationPage", + "type": "object", + "x-expandableFields": [] + }, + "payment_links_resource_completion_behavior_redirect": { + "description": "", + "properties": { + "url": { + "description": "The URL the customer will be redirected to after the purchase is complete.", + "maxLength": 5000, "type": "string" + } + }, + "required": ["url"], + "title": "PaymentLinksResourceCompletionBehaviorRedirect", + "type": "object", + "x-expandableFields": [] + }, + "payment_links_resource_consent_collection": { + "description": "", + "properties": { + "payment_method_reuse_agreement": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_payment_method_reuse_agreement" + } + ], + "description": "Settings related to the payment method reuse text shown in the Checkout UI.", + "nullable": true }, - "iban_last4": { + "promotions": { + "description": "If set to `auto`, enables the collection of customer consent for promotional communications.", + "enum": ["auto", "none"], "nullable": true, "type": "string" }, - "statement_descriptor": { + "terms_of_service": { + "description": "If set to `required`, it requires cutomers to accept the terms of service before being able to pay. If set to `none`, customers won't be shown a checkbox to accept the terms of service.", + "enum": ["none", "required"], "nullable": true, "type": "string" } }, - "type": "object" + "title": "PaymentLinksResourceConsentCollection", + "type": "object", + "x-expandableFields": ["payment_method_reuse_agreement"] }, - "source_type_klarna": { + "payment_links_resource_custom_fields": { + "description": "", "properties": { - "background_image_url": { - "type": "string" - }, - "client_token": { - "nullable": true, - "type": "string" - }, - "first_name": { - "type": "string" + "dropdown": { + "$ref": "#/components/schemas/payment_links_resource_custom_fields_dropdown" }, - "last_name": { + "key": { + "description": "String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.", + "maxLength": 5000, "type": "string" }, - "locale": { - "type": "string" + "label": { + "$ref": "#/components/schemas/payment_links_resource_custom_fields_label" }, - "logo_url": { - "type": "string" + "numeric": { + "$ref": "#/components/schemas/payment_links_resource_custom_fields_numeric" }, - "page_title": { - "type": "string" + "optional": { + "description": "Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.", + "type": "boolean" }, - "pay_later_asset_urls_descriptive": { - "type": "string" + "text": { + "$ref": "#/components/schemas/payment_links_resource_custom_fields_text" }, - "pay_later_asset_urls_standard": { + "type": { + "description": "The type of the field.", + "enum": ["dropdown", "numeric", "text"], "type": "string" - }, - "pay_later_name": { + } + }, + "required": ["key", "label", "optional", "type"], + "title": "PaymentLinksResourceCustomFields", + "type": "object", + "x-expandableFields": ["dropdown", "label", "numeric", "text"] + }, + "payment_links_resource_custom_fields_dropdown": { + "description": "", + "properties": { + "options": { + "description": "The options available for the customer to select. Up to 200 options allowed.", + "items": { + "$ref": "#/components/schemas/payment_links_resource_custom_fields_dropdown_option" + }, + "type": "array" + } + }, + "required": ["options"], + "title": "PaymentLinksResourceCustomFieldsDropdown", + "type": "object", + "x-expandableFields": ["options"] + }, + "payment_links_resource_custom_fields_dropdown_option": { + "description": "", + "properties": { + "label": { + "description": "The label for the option, displayed to the customer. Up to 100 characters.", + "maxLength": 5000, "type": "string" }, - "pay_later_redirect_url": { + "value": { + "description": "The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.", + "maxLength": 5000, "type": "string" - }, - "pay_now_asset_urls_descriptive": { + } + }, + "required": ["label", "value"], + "title": "PaymentLinksResourceCustomFieldsDropdownOption", + "type": "object", + "x-expandableFields": [] + }, + "payment_links_resource_custom_fields_label": { + "description": "", + "properties": { + "custom": { + "description": "Custom text for the label, displayed to the customer. Up to 50 characters.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "pay_now_asset_urls_standard": { + "type": { + "description": "The type of the label.", + "enum": ["custom"], "type": "string" + } + }, + "required": ["type"], + "title": "PaymentLinksResourceCustomFieldsLabel", + "type": "object", + "x-expandableFields": [] + }, + "payment_links_resource_custom_fields_numeric": { + "description": "", + "properties": { + "maximum_length": { + "description": "The maximum character length constraint for the customer's input.", + "nullable": true, + "type": "integer" }, - "pay_now_name": { - "type": "string" + "minimum_length": { + "description": "The minimum character length requirement for the customer's input.", + "nullable": true, + "type": "integer" + } + }, + "title": "PaymentLinksResourceCustomFieldsNumeric", + "type": "object", + "x-expandableFields": [] + }, + "payment_links_resource_custom_fields_text": { + "description": "", + "properties": { + "maximum_length": { + "description": "The maximum character length constraint for the customer's input.", + "nullable": true, + "type": "integer" }, - "pay_now_redirect_url": { - "type": "string" - }, - "pay_over_time_asset_urls_descriptive": { - "type": "string" - }, - "pay_over_time_asset_urls_standard": { - "type": "string" - }, - "pay_over_time_name": { - "type": "string" - }, - "pay_over_time_redirect_url": { - "type": "string" - }, - "payment_method_categories": { - "type": "string" - }, - "purchase_country": { - "type": "string" - }, - "purchase_type": { - "type": "string" - }, - "redirect_url": { - "type": "string" - }, - "shipping_delay": { + "minimum_length": { + "description": "The minimum character length requirement for the customer's input.", + "nullable": true, "type": "integer" - }, - "shipping_first_name": { - "type": "string" - }, - "shipping_last_name": { - "type": "string" } }, - "type": "object" + "title": "PaymentLinksResourceCustomFieldsText", + "type": "object", + "x-expandableFields": [] }, - "source_type_multibanco": { + "payment_links_resource_custom_text": { + "description": "", "properties": { - "entity": { - "nullable": true, - "type": "string" - }, - "reference": { - "nullable": true, - "type": "string" - }, - "refund_account_holder_address_city": { - "nullable": true, - "type": "string" - }, - "refund_account_holder_address_country": { - "nullable": true, - "type": "string" - }, - "refund_account_holder_address_line1": { - "nullable": true, - "type": "string" - }, - "refund_account_holder_address_line2": { - "nullable": true, - "type": "string" - }, - "refund_account_holder_address_postal_code": { - "nullable": true, - "type": "string" + "after_submit": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_custom_text_position" + } + ], + "description": "Custom text that should be displayed after the payment confirmation button.", + "nullable": true }, - "refund_account_holder_address_state": { - "nullable": true, - "type": "string" + "shipping_address": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_custom_text_position" + } + ], + "description": "Custom text that should be displayed alongside shipping address collection.", + "nullable": true }, - "refund_account_holder_name": { - "nullable": true, - "type": "string" + "submit": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_custom_text_position" + } + ], + "description": "Custom text that should be displayed alongside the payment confirmation button.", + "nullable": true }, - "refund_iban": { - "nullable": true, - "type": "string" + "terms_of_service_acceptance": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_custom_text_position" + } + ], + "description": "Custom text that should be displayed in place of the default terms of service agreement text.", + "nullable": true } }, - "type": "object" + "title": "PaymentLinksResourceCustomText", + "type": "object", + "x-expandableFields": [ + "after_submit", + "shipping_address", + "submit", + "terms_of_service_acceptance" + ] }, - "source_type_p24": { + "payment_links_resource_custom_text_position": { + "description": "", "properties": { - "reference": { - "nullable": true, + "message": { + "description": "Text may be up to 1200 characters in length.", + "maxLength": 500, "type": "string" } }, - "type": "object" + "required": ["message"], + "title": "PaymentLinksResourceCustomTextPosition", + "type": "object", + "x-expandableFields": [] }, - "source_type_sepa_debit": { + "payment_links_resource_invoice_creation": { + "description": "", "properties": { - "bank_code": { - "nullable": true, - "type": "string" - }, - "branch_code": { - "nullable": true, - "type": "string" - }, - "country": { - "nullable": true, - "type": "string" - }, - "fingerprint": { - "nullable": true, - "type": "string" - }, - "last4": { - "nullable": true, - "type": "string" - }, - "mandate_reference": { - "nullable": true, - "type": "string" + "enabled": { + "description": "Enable creating an invoice on successful payment.", + "type": "boolean" }, - "mandate_url": { - "nullable": true, - "type": "string" + "invoice_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_links_resource_invoice_settings" + } + ], + "description": "Configuration for the invoice. Default invoice values will be used if unspecified.", + "nullable": true } }, - "type": "object" + "required": ["enabled"], + "title": "PaymentLinksResourceInvoiceCreation", + "type": "object", + "x-expandableFields": ["invoice_data"] }, - "source_type_sofort": { + "payment_links_resource_invoice_settings": { + "description": "", "properties": { - "bank_code": { + "account_tax_ids": { + "description": "The account tax IDs associated with the invoice.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ] + } + }, "nullable": true, - "type": "string" + "type": "array" }, - "bank_name": { + "custom_fields": { + "description": "A list of up to 4 custom fields to be displayed on the invoice.", + "items": { + "$ref": "#/components/schemas/invoice_setting_custom_field" + }, "nullable": true, - "type": "string" + "type": "array" }, - "bic": { + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "country": { + "footer": { + "description": "Footer to be displayed on the invoice.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "iban_last4": { - "nullable": true, - "type": "string" + "issuer": { + "anyOf": [ + { + "$ref": "#/components/schemas/connect_account_reference" + } + ], + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", + "nullable": true }, - "preferred_language": { + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", "nullable": true, - "type": "string" + "type": "object" }, - "statement_descriptor": { - "nullable": true, - "type": "string" + "rendering_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_setting_rendering_options" + } + ], + "description": "Options for invoice PDF rendering.", + "nullable": true } }, - "type": "object" + "title": "PaymentLinksResourceInvoiceSettings", + "type": "object", + "x-expandableFields": [ + "account_tax_ids", + "custom_fields", + "issuer", + "rendering_options" + ] }, - "source_type_three_d_secure": { + "payment_links_resource_payment_intent_data": { + "description": "", "properties": { - "address_line1_check": { - "nullable": true, - "type": "string" - }, - "address_zip_check": { - "nullable": true, - "type": "string" - }, - "authenticated": { - "nullable": true, - "type": "boolean" - }, - "brand": { - "nullable": true, - "type": "string" - }, - "card": { - "nullable": true, - "type": "string" - }, - "country": { - "nullable": true, - "type": "string" - }, - "customer": { - "nullable": true, - "type": "string" - }, - "cvc_check": { + "capture_method": { + "description": "Indicates when the funds will be captured from the customer's account.", + "enum": ["automatic", "automatic_async", "manual"], "nullable": true, "type": "string" }, - "dynamic_last4": { + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "exp_month": { - "nullable": true, - "type": "integer" - }, - "exp_year": { - "nullable": true, - "type": "integer" - }, - "fingerprint": { - "type": "string" + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link.", + "type": "object" }, - "funding": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with the payment method collected during checkout.", + "enum": ["off_session", "on_session"], "nullable": true, "type": "string" }, - "last4": { + "statement_descriptor": { + "description": "For a non-card payment, information about the charge that appears on the customer's statement when this payment succeeds in creating a charge.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "name": { + "statement_descriptor_suffix": { + "description": "For a card payment, information about the charge that appears on the customer's statement when this payment succeeds in creating a charge. Concatenated with the account's statement descriptor prefix to form the complete statement descriptor.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "three_d_secure": { - "type": "string" - }, - "tokenization_method": { + "transfer_group": { + "description": "A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.", + "maxLength": 5000, "nullable": true, "type": "string" } }, - "type": "object" + "required": ["metadata"], + "title": "PaymentLinksResourcePaymentIntentData", + "type": "object", + "x-expandableFields": [] }, - "source_type_wechat": { + "payment_links_resource_payment_method_reuse_agreement": { + "description": "", "properties": { - "prepay_id": { - "type": "string" - }, - "qr_code_url": { - "nullable": true, - "type": "string" - }, - "statement_descriptor": { + "position": { + "description": "Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's defaults will be used.\n\nWhen set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.", + "enum": ["auto", "hidden"], "type": "string" } }, - "type": "object" + "required": ["position"], + "title": "PaymentLinksResourcePaymentMethodReuseAgreement", + "type": "object", + "x-expandableFields": [] }, - "status_transitions": { + "payment_links_resource_phone_number_collection": { "description": "", "properties": { - "canceled": { - "description": "The time that the order was canceled.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "fulfiled": { - "description": "The time that the order was fulfilled.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "paid": { - "description": "The time that the order was paid.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "returned": { - "description": "The time that the order was returned.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "enabled": { + "description": "If `true`, a phone number will be collected during checkout.", + "type": "boolean" } }, - "title": "StatusTransitions", + "required": ["enabled"], + "title": "PaymentLinksResourcePhoneNumberCollection", "type": "object", "x-expandableFields": [] }, - "subscription": { - "description": "Subscriptions allow you to charge a customer on a recurring basis.\n\nRelated guide: [Creating Subscriptions](https://stripe.com/docs/billing/subscriptions/creating).", + "payment_links_resource_restrictions": { + "description": "", "properties": { - "application_fee_percent": { - "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account.", - "nullable": true, - "type": "number" - }, - "billing_cycle_anchor": { - "description": "Determines the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices.", - "format": "unix-time", - "type": "integer" - }, - "billing_thresholds": { - "anyOf": [ - { - "$ref": "#/components/schemas/subscription_billing_thresholds" - } - ], - "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period", - "nullable": true - }, - "cancel_at": { - "description": "A date in the future at which the subscription will automatically get canceled", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "cancel_at_period_end": { - "description": "If the subscription has been canceled with the `at_period_end` flag set to `true`, `cancel_at_period_end` on the subscription will be true. You can use this attribute to determine whether a subscription that has a status of active is scheduled to be canceled at the end of the current period.", - "type": "boolean" - }, - "canceled_at": { - "description": "If the subscription has been canceled, the date of that cancellation. If the subscription was canceled with `cancel_at_period_end`, `canceled_at` will reflect the time of the most recent update request, not the end of the subscription period when the subscription is automatically moved to a canceled state.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "collection_method": { - "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions.", - "enum": ["charge_automatically", "send_invoice"], - "nullable": true, - "type": "string" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "current_period_end": { - "description": "End of the current period that the subscription has been invoiced for. At the end of this period, a new invoice will be created.", - "format": "unix-time", - "type": "integer" - }, - "current_period_start": { - "description": "Start of the current period that the subscription has been invoiced for.", - "format": "unix-time", - "type": "integer" - }, - "customer": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ], - "description": "ID of the customer who owns the subscription.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ] - } - }, - "days_until_due": { - "description": "Number of days a customer has to pay invoices generated by this subscription. This value will be `null` for subscriptions where `collection_method=charge_automatically`.", - "nullable": true, - "type": "integer" - }, - "default_payment_method": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" - } - ], - "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } - }, - "default_source": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/alipay_account" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/source" - } - ], - "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/alipay_account" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/source" - } - ] - } - }, - "default_tax_rates": { - "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription.", + "completed_sessions": { + "$ref": "#/components/schemas/payment_links_resource_completed_sessions" + } + }, + "required": ["completed_sessions"], + "title": "PaymentLinksResourceRestrictions", + "type": "object", + "x-expandableFields": ["completed_sessions"] + }, + "payment_links_resource_shipping_address_collection": { + "description": "", + "properties": { + "allowed_countries": { + "description": "An array of two-letter ISO country codes representing which countries Checkout should provide as options for shipping locations. Unsupported country codes: `AS, CX, CC, CU, HM, IR, KP, MH, FM, NF, MP, PW, SD, SY, UM, VI`.", "items": { - "$ref": "#/components/schemas/tax_rate" - }, - "nullable": true, - "type": "array" - }, - "discount": { - "anyOf": [ - { - "$ref": "#/components/schemas/discount" - } - ], - "description": "Describes the current discount applied to this subscription, if there is one. When billing, a discount applied to a subscription overrides a discount applied on a customer-wide basis.", - "nullable": true - }, - "ended_at": { - "description": "If the subscription has ended, the date the subscription ended.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "items": { - "description": "List of subscription items, each with an attached price.", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/subscription_item" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } + "enum": [ + "AC", + "AD", + "AE", + "AF", + "AG", + "AI", + "AL", + "AM", + "AO", + "AQ", + "AR", + "AT", + "AU", + "AW", + "AX", + "AZ", + "BA", + "BB", + "BD", + "BE", + "BF", + "BG", + "BH", + "BI", + "BJ", + "BL", + "BM", + "BN", + "BO", + "BQ", + "BR", + "BS", + "BT", + "BV", + "BW", + "BY", + "BZ", + "CA", + "CD", + "CF", + "CG", + "CH", + "CI", + "CK", + "CL", + "CM", + "CN", + "CO", + "CR", + "CV", + "CW", + "CY", + "CZ", + "DE", + "DJ", + "DK", + "DM", + "DO", + "DZ", + "EC", + "EE", + "EG", + "EH", + "ER", + "ES", + "ET", + "FI", + "FJ", + "FK", + "FO", + "FR", + "GA", + "GB", + "GD", + "GE", + "GF", + "GG", + "GH", + "GI", + "GL", + "GM", + "GN", + "GP", + "GQ", + "GR", + "GS", + "GT", + "GU", + "GW", + "GY", + "HK", + "HN", + "HR", + "HT", + "HU", + "ID", + "IE", + "IL", + "IM", + "IN", + "IO", + "IQ", + "IS", + "IT", + "JE", + "JM", + "JO", + "JP", + "KE", + "KG", + "KH", + "KI", + "KM", + "KN", + "KR", + "KW", + "KY", + "KZ", + "LA", + "LB", + "LC", + "LI", + "LK", + "LR", + "LS", + "LT", + "LU", + "LV", + "LY", + "MA", + "MC", + "MD", + "ME", + "MF", + "MG", + "MK", + "ML", + "MM", + "MN", + "MO", + "MQ", + "MR", + "MS", + "MT", + "MU", + "MV", + "MW", + "MX", + "MY", + "MZ", + "NA", + "NC", + "NE", + "NG", + "NI", + "NL", + "NO", + "NP", + "NR", + "NU", + "NZ", + "OM", + "PA", + "PE", + "PF", + "PG", + "PH", + "PK", + "PL", + "PM", + "PN", + "PR", + "PS", + "PT", + "PY", + "QA", + "RE", + "RO", + "RS", + "RU", + "RW", + "SA", + "SB", + "SC", + "SE", + "SG", + "SH", + "SI", + "SJ", + "SK", + "SL", + "SM", + "SN", + "SO", + "SR", + "SS", + "ST", + "SV", + "SX", + "SZ", + "TA", + "TC", + "TD", + "TF", + "TG", + "TH", + "TJ", + "TK", + "TL", + "TM", + "TN", + "TO", + "TR", + "TT", + "TV", + "TW", + "TZ", + "UA", + "UG", + "US", + "UY", + "UZ", + "VA", + "VC", + "VE", + "VG", + "VN", + "VU", + "WF", + "WS", + "XK", + "YE", + "YT", + "ZA", + "ZM", + "ZW", + "ZZ" + ], + "type": "string" }, - "required": ["data", "has_more", "object", "url"], - "title": "SubscriptionItemList", - "type": "object", - "x-expandableFields": ["data"] + "type": "array" + } + }, + "required": ["allowed_countries"], + "title": "PaymentLinksResourceShippingAddressCollection", + "type": "object", + "x-expandableFields": [] + }, + "payment_links_resource_shipping_option": { + "description": "", + "properties": { + "shipping_amount": { + "description": "A non-negative integer in cents representing how much to charge.", + "type": "integer" }, - "latest_invoice": { + "shipping_rate": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/invoice" + "$ref": "#/components/schemas/shipping_rate" } ], - "description": "The most recent invoice this subscription has generated.", - "nullable": true, + "description": "The ID of the Shipping Rate to use for this shipping option.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/invoice" + "$ref": "#/components/schemas/shipping_rate" } ] } + } + }, + "required": ["shipping_amount", "shipping_rate"], + "title": "PaymentLinksResourceShippingOption", + "type": "object", + "x-expandableFields": ["shipping_rate"] + }, + "payment_links_resource_subscription_data": { + "description": "", + "properties": { + "description": { + "description": "The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "invoice_settings": { + "$ref": "#/components/schemas/payment_links_resource_subscription_data_invoice_settings" }, "metadata": { "additionalProperties": { "maxLength": 500, "type": "string" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link.", "type": "object" }, - "next_pending_invoice_item_invoice": { - "description": "Specifies the approximate timestamp on which any pending invoice items will be billed according to the schedule provided at `pending_invoice_item_interval`.", - "format": "unix-time", + "trial_period_days": { + "description": "Integer representing the number of trial period days before the customer is charged for the first time.", "nullable": true, "type": "integer" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["subscription"], - "type": "string" - }, - "pause_collection": { - "anyOf": [ - { - "$ref": "#/components/schemas/subscriptions_resource_pause_collection" - } - ], - "description": "If specified, payment collection for this subscription will be paused.", - "nullable": true - }, - "pending_invoice_item_interval": { + "trial_settings": { "anyOf": [ { - "$ref": "#/components/schemas/subscription_pending_invoice_item_interval" + "$ref": "#/components/schemas/subscriptions_trials_resource_trial_settings" } ], - "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.", + "description": "Settings related to subscription trials.", "nullable": true + } + }, + "required": ["invoice_settings", "metadata"], + "title": "PaymentLinksResourceSubscriptionData", + "type": "object", + "x-expandableFields": ["invoice_settings", "trial_settings"] + }, + "payment_links_resource_subscription_data_invoice_settings": { + "description": "", + "properties": { + "issuer": { + "$ref": "#/components/schemas/connect_account_reference" + } + }, + "required": ["issuer"], + "title": "PaymentLinksResourceSubscriptionDataInvoiceSettings", + "type": "object", + "x-expandableFields": ["issuer"] + }, + "payment_links_resource_tax_id_collection": { + "description": "", + "properties": { + "enabled": { + "description": "Indicates whether tax ID collection is enabled for the session.", + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "PaymentLinksResourceTaxIdCollection", + "type": "object", + "x-expandableFields": [] + }, + "payment_links_resource_transfer_data": { + "description": "", + "properties": { + "amount": { + "description": "The amount in cents (or local equivalent) that will be transferred to the destination account. By default, the entire amount is transferred to the destination.", + "nullable": true, + "type": "integer" }, - "pending_setup_intent": { + "destination": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/setup_intent" + "$ref": "#/components/schemas/account" } ], - "description": "You can use this [SetupIntent](https://stripe.com/docs/api/setup_intents) to collect user authentication when creating a subscription without immediate payment or updating a subscription's payment method, allowing you to optimize for off-session payments. Learn more in the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication#scenario-2).", - "nullable": true, + "description": "The connected account receiving the transfer.", "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/setup_intent" + "$ref": "#/components/schemas/account" } ] } + } + }, + "required": ["destination"], + "title": "PaymentLinksResourceTransferData", + "type": "object", + "x-expandableFields": ["destination"] + }, + "payment_method": { + "description": "PaymentMethod objects represent your customer's payment instruments.\nYou can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to\nCustomer objects to store instrument details for future payments.\n\nRelated guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios).", + "properties": { + "acss_debit": { + "$ref": "#/components/schemas/payment_method_acss_debit" }, - "pending_update": { - "anyOf": [ - { - "$ref": "#/components/schemas/subscriptions_resource_pending_update" - } - ], - "description": "If specified, [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates) that will be applied to the subscription once the `latest_invoice` has been paid.", - "nullable": true + "affirm": { + "$ref": "#/components/schemas/payment_method_affirm" }, - "schedule": { + "afterpay_clearpay": { + "$ref": "#/components/schemas/payment_method_afterpay_clearpay" + }, + "alipay": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_alipay" + }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to “unspecified”.", + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "amazon_pay": { + "$ref": "#/components/schemas/payment_method_amazon_pay" + }, + "au_becs_debit": { + "$ref": "#/components/schemas/payment_method_au_becs_debit" + }, + "bacs_debit": { + "$ref": "#/components/schemas/payment_method_bacs_debit" + }, + "bancontact": { + "$ref": "#/components/schemas/payment_method_bancontact" + }, + "billing_details": { + "$ref": "#/components/schemas/billing_details" + }, + "blik": { + "$ref": "#/components/schemas/payment_method_blik" + }, + "boleto": { + "$ref": "#/components/schemas/payment_method_boleto" + }, + "card": { + "$ref": "#/components/schemas/payment_method_card" + }, + "card_present": { + "$ref": "#/components/schemas/payment_method_card_present" + }, + "cashapp": { + "$ref": "#/components/schemas/payment_method_cashapp" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "customer": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/subscription_schedule" + "$ref": "#/components/schemas/customer" } ], - "description": "The schedule attached to the subscription", + "description": "The ID of the Customer to which this PaymentMethod is saved. This will not be set when the PaymentMethod has not been saved to a Customer.", "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/subscription_schedule" + "$ref": "#/components/schemas/customer" } ] } }, - "start_date": { - "description": "Date when the subscription was first created. The date might differ from the `created` date due to backdating.", - "format": "unix-time", - "type": "integer" - }, - "status": { - "description": "Possible values are `incomplete`, `incomplete_expired`, `trialing`, `active`, `past_due`, `canceled`, or `unpaid`. \n\nFor `collection_method=charge_automatically` a subscription moves into `incomplete` if the initial payment attempt fails. A subscription in this state can only have metadata and default_source updated. Once the first invoice is paid, the subscription moves into an `active` state. If the first invoice is not paid within 23 hours, the subscription transitions to `incomplete_expired`. This is a terminal state, the open invoice will be voided and no further invoices will be generated. \n\nA subscription that is currently in a trial period is `trialing` and moves to `active` when the trial period is over. \n\nIf subscription `collection_method=charge_automatically` it becomes `past_due` when payment to renew it fails and `canceled` or `unpaid` (depending on your subscriptions settings) when Stripe has exhausted all payment retry attempts. \n\nIf subscription `collection_method=send_invoice` it becomes `past_due` when its invoice is not paid by the due date, and `canceled` or `unpaid` if it is still not paid by an additional deadline after that. Note that when a subscription has a status of `unpaid`, no subsequent invoices will be attempted (invoices will be created, but then immediately automatically closed). After receiving updated payment information from a customer, you may choose to reopen and pay their closed invoices.", - "enum": [ - "active", - "canceled", - "incomplete", - "incomplete_expired", - "past_due", - "trialing", - "unpaid" - ], - "type": "string" - }, - "transfer_data": { - "anyOf": [ - { - "$ref": "#/components/schemas/subscription_transfer_data" - } - ], - "description": "The account (if any) the subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.", - "nullable": true + "customer_balance": { + "$ref": "#/components/schemas/payment_method_customer_balance" }, - "trial_end": { - "description": "If the subscription has a trial, the end of that trial.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "eps": { + "$ref": "#/components/schemas/payment_method_eps" }, - "trial_start": { - "description": "If the subscription has a trial, the beginning of that trial.", - "format": "unix-time", - "nullable": true, - "type": "integer" - } - }, - "required": [ - "billing_cycle_anchor", - "cancel_at_period_end", - "created", - "current_period_end", - "current_period_start", - "customer", - "id", - "items", - "livemode", - "metadata", - "object", - "start_date", - "status" - ], - "title": "Subscription", - "type": "object", - "x-expandableFields": [ - "billing_thresholds", - "customer", - "default_payment_method", - "default_source", - "default_tax_rates", - "discount", - "items", - "latest_invoice", - "pause_collection", - "pending_invoice_item_interval", - "pending_setup_intent", - "pending_update", - "schedule", - "transfer_data" - ], - "x-resourceId": "subscription" - }, - "subscription_billing_thresholds": { - "description": "", - "properties": { - "amount_gte": { - "description": "Monetary threshold that triggers the subscription to create an invoice", - "nullable": true, - "type": "integer" + "fpx": { + "$ref": "#/components/schemas/payment_method_fpx" }, - "reset_billing_cycle_anchor": { - "description": "Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged. This value may not be `true` if the subscription contains items with plans that have `aggregate_usage=last_ever`.", - "nullable": true, - "type": "boolean" - } - }, - "title": "SubscriptionBillingThresholds", - "type": "object", - "x-expandableFields": [] - }, - "subscription_item": { - "description": "Subscription items allow you to create customer subscriptions with more than\none plan, making it easy to represent complex billing relationships.", - "properties": { - "billing_thresholds": { - "anyOf": [ - { - "$ref": "#/components/schemas/subscription_item_billing_thresholds" - } - ], - "description": "Define thresholds at which an invoice will be sent, and the related subscription advanced to a new billing period", - "nullable": true + "giropay": { + "$ref": "#/components/schemas/payment_method_giropay" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "type": "integer" + "grabpay": { + "$ref": "#/components/schemas/payment_method_grabpay" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, + "ideal": { + "$ref": "#/components/schemas/payment_method_ideal" + }, + "interac_present": { + "$ref": "#/components/schemas/payment_method_interac_present" + }, + "klarna": { + "$ref": "#/components/schemas/payment_method_klarna" + }, + "konbini": { + "$ref": "#/components/schemas/payment_method_konbini" + }, + "link": { + "$ref": "#/components/schemas/payment_method_link" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, "metadata": { "additionalProperties": { "maxLength": 500, "type": "string" }, "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, "type": "object" }, + "mobilepay": { + "$ref": "#/components/schemas/payment_method_mobilepay" + }, + "multibanco": { + "$ref": "#/components/schemas/payment_method_multibanco" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["subscription_item"], + "enum": ["payment_method"], "type": "string" }, - "price": { - "$ref": "#/components/schemas/price" + "oxxo": { + "$ref": "#/components/schemas/payment_method_oxxo" }, - "quantity": { - "description": "The [quantity](https://stripe.com/docs/subscriptions/quantities) of the plan to which the customer should be subscribed.", - "type": "integer" + "p24": { + "$ref": "#/components/schemas/payment_method_p24" }, - "subscription": { - "description": "The `subscription` this `subscription_item` belongs to.", - "maxLength": 5000, - "type": "string" + "paynow": { + "$ref": "#/components/schemas/payment_method_paynow" }, - "tax_rates": { - "description": "The tax rates which apply to this `subscription_item`. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.", - "items": { - "$ref": "#/components/schemas/tax_rate" - }, - "nullable": true, - "type": "array" + "paypal": { + "$ref": "#/components/schemas/payment_method_paypal" + }, + "pix": { + "$ref": "#/components/schemas/payment_method_pix" + }, + "promptpay": { + "$ref": "#/components/schemas/payment_method_promptpay" + }, + "radar_options": { + "$ref": "#/components/schemas/radar_radar_options" + }, + "revolut_pay": { + "$ref": "#/components/schemas/payment_method_revolut_pay" + }, + "sepa_debit": { + "$ref": "#/components/schemas/payment_method_sepa_debit" + }, + "sofort": { + "$ref": "#/components/schemas/payment_method_sofort" + }, + "swish": { + "$ref": "#/components/schemas/payment_method_swish" + }, + "twint": { + "$ref": "#/components/schemas/payment_method_twint" + }, + "type": { + "description": "The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.", + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "card_present", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "interac_present", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "$ref": "#/components/schemas/payment_method_us_bank_account" + }, + "wechat_pay": { + "$ref": "#/components/schemas/payment_method_wechat_pay" + }, + "zip": { + "$ref": "#/components/schemas/payment_method_zip" } }, "required": [ + "billing_details", "created", "id", - "metadata", + "livemode", "object", - "price", - "subscription" + "type" ], - "title": "SubscriptionItem", + "title": "PaymentMethod", "type": "object", - "x-expandableFields": ["billing_thresholds", "price", "tax_rates"], - "x-resourceId": "subscription_item" + "x-expandableFields": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "billing_details", + "blik", + "boleto", + "card", + "card_present", + "cashapp", + "customer", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "interac_present", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "radar_options", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "x-resourceId": "payment_method" }, - "subscription_item_billing_thresholds": { + "payment_method_acss_debit": { "description": "", "properties": { - "usage_gte": { - "description": "Usage threshold that triggers the subscription to create an invoice", + "bank_name": { + "description": "Name of the bank associated with the bank account.", + "maxLength": 5000, "nullable": true, - "type": "integer" + "type": "string" + }, + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "institution_number": { + "description": "Institution number of the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "transit_number": { + "description": "Transit number of the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "title": "SubscriptionItemBillingThresholds", + "title": "payment_method_acss_debit", "type": "object", "x-expandableFields": [] }, - "subscription_pending_invoice_item_interval": { + "payment_method_affirm": { + "description": "", + "properties": {}, + "title": "payment_method_affirm", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_afterpay_clearpay": { + "description": "", + "properties": {}, + "title": "payment_method_afterpay_clearpay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_amazon_pay": { + "description": "", + "properties": {}, + "title": "payment_method_amazon_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_au_becs_debit": { "description": "", "properties": { - "interval": { - "description": "Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.", - "enum": ["day", "month", "week", "year"], + "bsb_number": { + "description": "Six-digit number identifying bank and branch associated with this bank account.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "interval_count": { - "description": "The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).", - "type": "integer" + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "required": ["interval", "interval_count"], - "title": "SubscriptionPendingInvoiceItemInterval", + "title": "payment_method_au_becs_debit", "type": "object", "x-expandableFields": [] }, - "subscription_schedule": { - "description": "A subscription schedule allows you to create and manage the lifecycle of a subscription by predefining expected changes.\n\nRelated guide: [Subscription Schedules](https://stripe.com/docs/billing/subscriptions/subscription-schedules).", + "payment_method_bacs_debit": { + "description": "", "properties": { - "canceled_at": { - "description": "Time at which the subscription schedule was canceled. Measured in seconds since the Unix epoch.", - "format": "unix-time", + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, "nullable": true, - "type": "integer" + "type": "string" }, - "completed_at": { - "description": "Time at which the subscription schedule was completed. Measured in seconds since the Unix epoch.", - "format": "unix-time", + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, "nullable": true, - "type": "integer" + "type": "string" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "sort_code": { + "description": "Sort code of the bank account. (e.g., `10-20-30`)", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_bacs_debit", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_bancontact": { + "description": "", + "properties": {}, + "title": "payment_method_bancontact", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_blik": { + "description": "", + "properties": {}, + "title": "payment_method_blik", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_boleto": { + "description": "", + "properties": { + "tax_id": { + "description": "Uniquely identifies the customer tax id (CNPJ or CPF)", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "payment_method_boleto", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_card": { + "description": "", + "properties": { + "brand": { + "description": "Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + "maxLength": 5000, + "type": "string" }, - "current_phase": { + "checks": { "anyOf": [ { - "$ref": "#/components/schemas/subscription_schedule_current_phase" + "$ref": "#/components/schemas/payment_method_card_checks" } ], - "description": "Object representing the start and end dates for the current phase of the subscription schedule, if it is `active`.", + "description": "Checks on Card address and CVC if provided.", "nullable": true }, - "customer": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ], - "description": "ID of the customer who owns the subscription schedule.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ] - } - }, - "default_settings": { - "$ref": "#/components/schemas/subscription_schedules_resource_default_settings" - }, - "end_behavior": { - "description": "Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` and `cancel`.", - "enum": ["cancel", "none", "release", "renew"], - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", + "country": { + "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "display_brand": { + "description": "The brand to use when displaying the card, this accounts for customer's brand choice on dual-branded cards. Can be `american_express`, `cartes_bancaires`, `diners_club`, `discover`, `eftpos_australia`, `interac`, `jcb`, `mastercard`, `union_pay`, `visa`, or `other` and may contain more values in the future.", + "maxLength": 5000, "nullable": true, - "type": "object" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["subscription_schedule"], "type": "string" }, - "phases": { - "description": "Configuration for the subscription schedule's phases.", - "items": { - "$ref": "#/components/schemas/subscription_schedule_phase_configuration" - }, - "type": "array" + "exp_month": { + "description": "Two-digit number representing the card's expiration month.", + "type": "integer" }, - "released_at": { - "description": "Time at which the subscription schedule was released. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "nullable": true, + "exp_year": { + "description": "Four-digit number representing the card's expiration year.", "type": "integer" }, - "released_subscription": { - "description": "ID of the subscription once managed by the subscription schedule (if it is released).", + "fingerprint": { + "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.\n\n*As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*", "maxLength": 5000, "nullable": true, "type": "string" }, - "status": { - "description": "The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules).", - "enum": [ - "active", - "canceled", - "completed", - "not_started", - "released" + "funding": { + "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", + "maxLength": 5000, + "type": "string" + }, + "generated_from": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_card_generated_card" + } ], + "description": "Details of the original PaymentMethod that created this object.", + "nullable": true + }, + "last4": { + "description": "The last four digits of the card.", + "maxLength": 5000, "type": "string" }, - "subscription": { + "networks": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, + "$ref": "#/components/schemas/networks" + } + ], + "description": "Contains information about card networks that can be used to process the payment.", + "nullable": true + }, + "three_d_secure_usage": { + "anyOf": [ { - "$ref": "#/components/schemas/subscription" + "$ref": "#/components/schemas/three_d_secure_usage" } ], - "description": "ID of the subscription managed by the subscription schedule.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/subscription" - } - ] - } + "description": "Contains details on how this Card may be used for 3D Secure authentication.", + "nullable": true + }, + "wallet": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_card_wallet" + } + ], + "description": "If this Card is part of a card wallet, this contains the details of the card wallet.", + "nullable": true } }, - "required": [ - "created", - "customer", - "default_settings", - "end_behavior", - "id", - "livemode", - "object", - "phases", - "status" - ], - "title": "SubscriptionSchedule", + "required": ["brand", "exp_month", "exp_year", "funding", "last4"], + "title": "payment_method_card", "type": "object", "x-expandableFields": [ - "current_phase", - "customer", - "default_settings", - "phases", - "subscription" - ], - "x-resourceId": "subscription_schedule" + "checks", + "generated_from", + "networks", + "three_d_secure_usage", + "wallet" + ] }, - "subscription_schedule_add_invoice_item": { - "description": "An Add Invoice Item describes the prices and quantities that will be added as pending invoice items when entering a phase.", + "payment_method_card_checks": { + "description": "", "properties": { - "price": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/price" - }, - { - "$ref": "#/components/schemas/deleted_price" - } - ], - "description": "ID of the price used to generate the invoice item.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/price" - }, - { - "$ref": "#/components/schemas/deleted_price" - } - ] - } + "address_line1_check": { + "description": "If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "quantity": { - "description": "The quantity of the invoice item.", + "address_postal_code_check": { + "description": "If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, "nullable": true, - "type": "integer" + "type": "string" }, - "tax_rates": { - "description": "The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.", - "items": { - "$ref": "#/components/schemas/tax_rate" - }, + "cvc_check": { + "description": "If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, "nullable": true, - "type": "array" + "type": "string" } }, - "required": ["price"], - "title": "SubscriptionScheduleAddInvoiceItem", + "title": "payment_method_card_checks", "type": "object", - "x-expandableFields": ["price", "tax_rates"] + "x-expandableFields": [] }, - "subscription_schedule_configuration_item": { - "description": "A phase item describes the price and quantity of a phase.", + "payment_method_card_generated_card": { + "description": "", "properties": { - "billing_thresholds": { + "charge": { + "description": "The charge that created this object.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "payment_method_details": { "anyOf": [ { - "$ref": "#/components/schemas/subscription_item_billing_thresholds" + "$ref": "#/components/schemas/card_generated_from_payment_method_details" } ], - "description": "Define thresholds at which an invoice will be sent, and the related subscription advanced to a new billing period", + "description": "Transaction-specific details of the payment method used in the payment.", "nullable": true }, - "price": { + "setup_attempt": { "anyOf": [ { "maxLength": 5000, "type": "string" }, { - "$ref": "#/components/schemas/price" - }, - { - "$ref": "#/components/schemas/deleted_price" + "$ref": "#/components/schemas/setup_attempt" } ], - "description": "ID of the price to which the customer should be subscribed.", + "description": "The ID of the SetupAttempt that generated this PaymentMethod, if any.", + "nullable": true, "x-expansionResources": { "oneOf": [ { - "$ref": "#/components/schemas/price" - }, - { - "$ref": "#/components/schemas/deleted_price" + "$ref": "#/components/schemas/setup_attempt" } ] } - }, - "quantity": { - "description": "Quantity of the plan to which the customer should be subscribed.", - "type": "integer" - }, - "tax_rates": { - "description": "The tax rates which apply to this `phase_item`. When set, the `default_tax_rates` on the phase do not apply to this `phase_item`.", - "items": { - "$ref": "#/components/schemas/tax_rate" - }, - "nullable": true, - "type": "array" } }, - "required": ["price"], - "title": "SubscriptionScheduleConfigurationItem", + "title": "payment_method_card_generated_card", "type": "object", - "x-expandableFields": ["billing_thresholds", "price", "tax_rates"] + "x-expandableFields": ["payment_method_details", "setup_attempt"] }, - "subscription_schedule_current_phase": { + "payment_method_card_present": { "description": "", "properties": { - "end_date": { - "description": "The end of this phase of the subscription schedule.", - "format": "unix-time", + "brand": { + "description": "Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "brand_product": { + "description": "The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "cardholder_name": { + "description": "The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "country": { + "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "description": { + "description": "A high-level description of the type of cards issued in this range.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "exp_month": { + "description": "Two-digit number representing the card's expiration month.", "type": "integer" }, - "start_date": { - "description": "The start of this phase of the subscription schedule.", - "format": "unix-time", + "exp_year": { + "description": "Four-digit number representing the card's expiration year.", "type": "integer" - } - }, - "required": ["end_date", "start_date"], - "title": "SubscriptionScheduleCurrentPhase", - "type": "object", - "x-expandableFields": [] - }, - "subscription_schedule_phase_configuration": { - "description": "A phase describes the plans, coupon, and trialing status of a subscription for a predefined time period.", - "properties": { - "add_invoice_items": { - "description": "A list of prices and quantities that will generate invoice items appended to the first invoice for this phase.", - "items": { - "$ref": "#/components/schemas/subscription_schedule_add_invoice_item" - }, - "type": "array" }, - "application_fee_percent": { - "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account during this phase of the schedule.", + "fingerprint": { + "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.\n\n*As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*", + "maxLength": 5000, "nullable": true, - "type": "number" + "type": "string" }, - "billing_cycle_anchor": { - "description": "Possible values are `phase_start` or `automatic`. If `phase_start` then billing cycle anchor of the subscription is set to the start of the phase when entering the phase. If `automatic` then the billing cycle anchor is automatically modified as needed when entering the phase. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", - "enum": ["automatic", "phase_start"], + "funding": { + "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "billing_thresholds": { - "anyOf": [ - { - "$ref": "#/components/schemas/subscription_billing_thresholds" - } - ], - "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period", - "nullable": true + "issuer": { + "description": "The name of the card's issuing bank.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "collection_method": { - "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions.", - "enum": ["charge_automatically", "send_invoice"], + "last4": { + "description": "The last four digits of the card.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "coupon": { + "networks": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/coupon" - }, - { - "$ref": "#/components/schemas/deleted_coupon" + "$ref": "#/components/schemas/payment_method_card_present_networks" } ], - "description": "ID of the coupon to use during this phase of the subscription schedule.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/coupon" - }, - { - "$ref": "#/components/schemas/deleted_coupon" - } - ] - } + "description": "Contains information about card networks that can be used to process the payment.", + "nullable": true }, - "default_payment_method": { + "offline": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/payment_method_details_card_present_offline" } ], - "description": "ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } + "description": "Details about payment methods collected offline.", + "nullable": true }, - "default_tax_rates": { - "description": "The default tax rates to apply to the subscription during this phase of the subscription schedule.", + "preferred_locales": { + "description": "EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.", "items": { - "$ref": "#/components/schemas/tax_rate" + "maxLength": 5000, + "type": "string" }, "nullable": true, "type": "array" }, - "end_date": { - "description": "The end of this phase of the subscription schedule.", - "format": "unix-time", - "type": "integer" - }, - "invoice_settings": { - "anyOf": [ - { - "$ref": "#/components/schemas/invoice_setting_subscription_schedule_setting" - } + "read_method": { + "description": "How card details were read in this transaction.", + "enum": [ + "contact_emv", + "contactless_emv", + "contactless_magstripe_mode", + "magnetic_stripe_fallback", + "magnetic_stripe_track2" ], - "description": "The invoice settings applicable during this phase.", - "nullable": true + "nullable": true, + "type": "string" }, - "items": { - "description": "Subscription items to configure the subscription to during this phase of the subscription schedule.", + "wallet": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_card_present_common_wallet" + } + }, + "required": ["exp_month", "exp_year"], + "title": "payment_method_card_present", + "type": "object", + "x-expandableFields": ["networks", "offline", "wallet"] + }, + "payment_method_card_present_networks": { + "description": "", + "properties": { + "available": { + "description": "All available networks for the card.", "items": { - "$ref": "#/components/schemas/subscription_schedule_configuration_item" + "maxLength": 5000, + "type": "string" }, "type": "array" }, - "proration_behavior": { - "description": "If the subscription schedule will prorate when transitioning to this phase. Possible values are `create_prorations` and `none`.", - "enum": ["always_invoice", "create_prorations", "none"], + "preferred": { + "description": "The preferred network for the card.", + "maxLength": 5000, + "nullable": true, "type": "string" + } + }, + "required": ["available"], + "title": "payment_method_card_present_networks", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_card_wallet": { + "description": "", + "properties": { + "amex_express_checkout": { + "$ref": "#/components/schemas/payment_method_card_wallet_amex_express_checkout" }, - "start_date": { - "description": "The start of this phase of the subscription schedule.", - "format": "unix-time", - "type": "integer" + "apple_pay": { + "$ref": "#/components/schemas/payment_method_card_wallet_apple_pay" }, - "transfer_data": { - "anyOf": [ - { - "$ref": "#/components/schemas/subscription_transfer_data" - } + "dynamic_last4": { + "description": "(For tokenized numbers only.) The last four digits of the device account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "google_pay": { + "$ref": "#/components/schemas/payment_method_card_wallet_google_pay" + }, + "link": { + "$ref": "#/components/schemas/payment_method_card_wallet_link" + }, + "masterpass": { + "$ref": "#/components/schemas/payment_method_card_wallet_masterpass" + }, + "samsung_pay": { + "$ref": "#/components/schemas/payment_method_card_wallet_samsung_pay" + }, + "type": { + "description": "The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, `visa_checkout`, or `link`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type.", + "enum": [ + "amex_express_checkout", + "apple_pay", + "google_pay", + "link", + "masterpass", + "samsung_pay", + "visa_checkout" ], - "description": "The account (if any) the associated subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.", - "nullable": true + "type": "string" }, - "trial_end": { - "description": "When the trial ends within the phase.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "visa_checkout": { + "$ref": "#/components/schemas/payment_method_card_wallet_visa_checkout" } }, - "required": [ - "add_invoice_items", - "end_date", - "items", - "proration_behavior", - "start_date" - ], - "title": "SubscriptionSchedulePhaseConfiguration", + "required": ["type"], + "title": "payment_method_card_wallet", "type": "object", "x-expandableFields": [ - "add_invoice_items", - "billing_thresholds", - "coupon", - "default_payment_method", - "default_tax_rates", - "invoice_settings", - "items", - "transfer_data" + "amex_express_checkout", + "apple_pay", + "google_pay", + "link", + "masterpass", + "samsung_pay", + "visa_checkout" ] }, - "subscription_schedules_resource_default_settings": { + "payment_method_card_wallet_amex_express_checkout": { + "description": "", + "properties": {}, + "title": "payment_method_card_wallet_amex_express_checkout", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_card_wallet_apple_pay": { + "description": "", + "properties": {}, + "title": "payment_method_card_wallet_apple_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_card_wallet_google_pay": { + "description": "", + "properties": {}, + "title": "payment_method_card_wallet_google_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_card_wallet_link": { + "description": "", + "properties": {}, + "title": "payment_method_card_wallet_link", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_card_wallet_masterpass": { "description": "", "properties": { - "application_fee_percent": { - "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account during this phase of the schedule.", - "nullable": true, - "type": "number" - }, - "billing_cycle_anchor": { - "description": "Possible values are `phase_start` or `automatic`. If `phase_start` then billing cycle anchor of the subscription is set to the start of the phase when entering the phase. If `automatic` then the billing cycle anchor is automatically modified as needed when entering the phase. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", - "enum": ["automatic", "phase_start"], - "type": "string" - }, - "billing_thresholds": { + "billing_address": { "anyOf": [ { - "$ref": "#/components/schemas/subscription_billing_thresholds" + "$ref": "#/components/schemas/address" } ], - "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period", + "description": "Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", "nullable": true }, - "collection_method": { - "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions.", - "enum": ["charge_automatically", "send_invoice"], + "email": { + "description": "Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "default_payment_method": { + "name": { + "description": "Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "shipping_address": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/address" } ], - "description": "ID of the default payment method for the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/payment_method" - } - ] - } - }, - "invoice_settings": { + "description": "Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "nullable": true + } + }, + "title": "payment_method_card_wallet_masterpass", + "type": "object", + "x-expandableFields": ["billing_address", "shipping_address"] + }, + "payment_method_card_wallet_samsung_pay": { + "description": "", + "properties": {}, + "title": "payment_method_card_wallet_samsung_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_card_wallet_visa_checkout": { + "description": "", + "properties": { + "billing_address": { "anyOf": [ { - "$ref": "#/components/schemas/invoice_setting_subscription_schedule_setting" + "$ref": "#/components/schemas/address" } ], - "description": "The subscription schedule's default invoice settings.", + "description": "Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", "nullable": true }, - "transfer_data": { + "email": { + "description": "Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "name": { + "description": "Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "shipping_address": { "anyOf": [ { - "$ref": "#/components/schemas/subscription_transfer_data" + "$ref": "#/components/schemas/address" } ], - "description": "The account (if any) the associated subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.", + "description": "Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", "nullable": true } }, - "required": ["billing_cycle_anchor"], - "title": "SubscriptionSchedulesResourceDefaultSettings", + "title": "payment_method_card_wallet_visa_checkout", "type": "object", - "x-expandableFields": [ - "billing_thresholds", - "default_payment_method", - "invoice_settings", - "transfer_data" - ] + "x-expandableFields": ["billing_address", "shipping_address"] }, - "subscription_transfer_data": { + "payment_method_cashapp": { "description": "", "properties": { - "amount_percent": { - "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the destination account. By default, the entire amount is transferred to the destination.", + "buyer_id": { + "description": "A unique and immutable identifier assigned by Cash App to every buyer.", + "maxLength": 5000, "nullable": true, - "type": "number" + "type": "string" }, - "destination": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/account" - } - ], - "description": "The account where funds from the payment will be transferred to upon payment success.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/account" - } - ] - } + "cashtag": { + "description": "A public identifier for buyers using Cash App.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "required": ["destination"], - "title": "SubscriptionTransferData", + "title": "payment_method_cashapp", "type": "object", - "x-expandableFields": ["destination"] + "x-expandableFields": [] }, - "subscriptions_resource_pause_collection": { - "description": "The Pause Collection settings determine how we will pause collection for this subscription and for how long the subscription\nshould be paused.", + "payment_method_config_biz_payment_method_configuration_details": { + "description": "", "properties": { - "behavior": { - "description": "The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.", - "enum": ["keep_as_draft", "mark_uncollectible", "void"], + "id": { + "description": "ID of the payment method configuration used.", + "maxLength": 5000, "type": "string" }, - "resumes_at": { - "description": "The time after which the subscription will resume collecting payments.", - "format": "unix-time", + "parent": { + "description": "ID of the parent payment method configuration used.", + "maxLength": 5000, "nullable": true, - "type": "integer" + "type": "string" } }, - "required": ["behavior"], - "title": "SubscriptionsResourcePauseCollection", + "required": ["id"], + "title": "PaymentMethodConfigBizPaymentMethodConfigurationDetails", "type": "object", "x-expandableFields": [] }, - "subscriptions_resource_pending_update": { - "description": "Pending Updates store the changes pending from a previous update that will be applied\nto the Subscription upon successful payment.", + "payment_method_config_resource_display_preference": { + "description": "", "properties": { - "billing_cycle_anchor": { - "description": "If the update is applied, determines the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices.", - "format": "unix-time", - "nullable": true, - "type": "integer" - }, - "expires_at": { - "description": "The point after which the changes reflected by this update will be discarded and no longer applied.", - "format": "unix-time", - "type": "integer" - }, - "subscription_items": { - "description": "List of subscription items, each with an attached plan, that will be set if the update is applied.", - "items": { - "$ref": "#/components/schemas/subscription_item" - }, + "overridable": { + "description": "For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.", "nullable": true, - "type": "array" + "type": "boolean" }, - "trial_end": { - "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time, if the update is applied.", - "format": "unix-time", - "nullable": true, - "type": "integer" + "preference": { + "description": "The account's display preference.", + "enum": ["none", "off", "on"], + "type": "string" }, - "trial_from_plan": { - "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed.", - "nullable": true, - "type": "boolean" + "value": { + "description": "The effective display preference value.", + "enum": ["off", "on"], + "type": "string" } }, - "required": ["expires_at"], - "title": "SubscriptionsResourcePendingUpdate", + "required": ["preference", "value"], + "title": "PaymentMethodConfigResourceDisplayPreference", "type": "object", - "x-expandableFields": ["subscription_items"] + "x-expandableFields": [] }, - "tax_deducted_at_source": { + "payment_method_config_resource_payment_method_properties": { "description": "", "properties": { - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["tax_deducted_at_source"], - "type": "string" - }, - "period_end": { - "description": "The end of the invoicing period. This TDS applies to Stripe fees collected during this invoicing period.", - "format": "unix-time", - "type": "integer" - }, - "period_start": { - "description": "The start of the invoicing period. This TDS applies to Stripe fees collected during this invoicing period.", - "format": "unix-time", - "type": "integer" + "available": { + "description": "Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.", + "type": "boolean" }, - "tax_deduction_account_number": { - "description": "The TAN that was supplied to Stripe when TDS was assessed", - "maxLength": 5000, - "type": "string" + "display_preference": { + "$ref": "#/components/schemas/payment_method_config_resource_display_preference" } }, - "required": [ - "id", - "object", - "period_end", - "period_start", - "tax_deduction_account_number" - ], - "title": "TaxDeductedAtSource", + "required": ["available", "display_preference"], + "title": "PaymentMethodConfigResourcePaymentMethodProperties", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["display_preference"] }, - "tax_id": { - "description": "You can add one or multiple tax IDs to a [customer](https://stripe.com/docs/api/customers).\nA customer's tax IDs are displayed on invoices and credit notes issued for the customer.\n\nRelated guide: [Customer Tax Identification Numbers](https://stripe.com/docs/billing/taxes/tax-ids).", + "payment_method_configuration": { + "description": "PaymentMethodConfigurations control which payment methods are displayed to your customers when you don't explicitly specify payment method types. You can have multiple configurations with different sets of payment methods for different scenarios.\n\nThere are two types of PaymentMethodConfigurations. Which is used depends on the [charge type](https://stripe.com/docs/connect/charges):\n\n**Direct** configurations apply to payments created on your account, including Connect destination charges, Connect separate charges and transfers, and payments not involving Connect.\n\n**Child** configurations apply to payments created on your connected accounts using direct charges, and charges with the on_behalf_of parameter.\n\nChild configurations have a `parent` that sets default values and controls which settings connected accounts may override. You can specify a parent ID at payment time, and Stripe will automatically resolve the connected account’s associated child configuration. Parent configurations are [managed in the dashboard](https://dashboard.stripe.com/settings/payment_methods/connected_accounts) and are not available in this API.\n\nRelated guides:\n- [Payment Method Configurations API](https://stripe.com/docs/connect/payment-method-configurations)\n- [Multiple configurations on dynamic payment methods](https://stripe.com/docs/payments/multiple-payment-method-configs)\n- [Multiple configurations for your Connect accounts](https://stripe.com/docs/connect/multiple-payment-method-configurations)", "properties": { - "country": { - "description": "Two-letter ISO code representing the country of the tax ID.", + "acss_debit": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "active": { + "description": "Whether the configuration can be used for new payments.", + "type": "boolean" + }, + "affirm": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "afterpay_clearpay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "alipay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "amazon_pay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "apple_pay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "application": { + "description": "For child configs, the Connect application associated with the configuration.", "maxLength": 5000, "nullable": true, "type": "string" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "au_becs_debit": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" }, - "customer": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/customer" - } - ], - "description": "ID of the customer.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/customer" - } - ] - } + "bacs_debit": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "bancontact": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "blik": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "boleto": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "card": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "cartes_bancaires": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "cashapp": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "customer_balance": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "eps": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "fpx": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "giropay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "google_pay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "grabpay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" }, "id": { "description": "Unique identifier for the object.", "maxLength": 5000, "type": "string" }, + "ideal": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "is_default": { + "description": "The default configuration is used whenever a payment method configuration is not specified.", + "type": "boolean" + }, + "jcb": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "klarna": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "konbini": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "link": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, "livemode": { "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", "type": "boolean" }, + "mobilepay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "multibanco": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "name": { + "description": "The configuration's name.", + "maxLength": 5000, + "type": "string" + }, "object": { "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["tax_id"], + "enum": ["payment_method_configuration"], "type": "string" }, - "type": { - "description": "Type of the tax ID, one of `ae_trn`, `au_abn`, `br_cnpj`, `br_cpf`, `ca_bn`, `ca_qst`, `ch_vat`, `cl_tin`, `es_cif`, `eu_vat`, `gb_vat`, `hk_br`, `id_npwp`, `in_gst`, `jp_cn`, `jp_rn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`. Note that some legacy tax IDs have type `unknown`", - "enum": [ - "ae_trn", - "au_abn", - "br_cnpj", - "br_cpf", - "ca_bn", - "ca_qst", - "ch_vat", - "cl_tin", - "es_cif", - "eu_vat", - "gb_vat", - "hk_br", - "id_npwp", - "in_gst", - "jp_cn", - "jp_rn", - "kr_brn", - "li_uid", - "mx_rfc", - "my_frp", - "my_itn", - "my_sst", - "no_vat", - "nz_gst", - "ru_inn", - "ru_kpp", - "sa_vat", - "sg_gst", - "sg_uen", - "th_vat", - "tw_vat", - "unknown", - "us_ein", - "za_vat" - ], + "oxxo": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "p24": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "parent": { + "description": "For child configs, the configuration's parent configuration.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "value": { - "description": "Value of the tax ID.", + "paynow": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "paypal": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "promptpay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "revolut_pay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "sepa_debit": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "sofort": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "swish": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "twint": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "us_bank_account": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "wechat_pay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, + "zip": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + } + }, + "required": [ + "active", + "id", + "is_default", + "livemode", + "name", + "object" + ], + "title": "PaymentMethodConfigResourcePaymentMethodConfiguration", + "type": "object", + "x-expandableFields": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "apple_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "cartes_bancaires", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "google_pay", + "grabpay", + "ideal", + "jcb", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "x-resourceId": "payment_method_configuration" + }, + "payment_method_customer_balance": { + "description": "", + "properties": {}, + "title": "payment_method_customer_balance", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details": { + "description": "", + "properties": { + "ach_credit_transfer": { + "$ref": "#/components/schemas/payment_method_details_ach_credit_transfer" + }, + "ach_debit": { + "$ref": "#/components/schemas/payment_method_details_ach_debit" + }, + "acss_debit": { + "$ref": "#/components/schemas/payment_method_details_acss_debit" + }, + "affirm": { + "$ref": "#/components/schemas/payment_method_details_affirm" + }, + "afterpay_clearpay": { + "$ref": "#/components/schemas/payment_method_details_afterpay_clearpay" + }, + "alipay": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_alipay_details" + }, + "amazon_pay": { + "$ref": "#/components/schemas/payment_method_details_amazon_pay" + }, + "au_becs_debit": { + "$ref": "#/components/schemas/payment_method_details_au_becs_debit" + }, + "bacs_debit": { + "$ref": "#/components/schemas/payment_method_details_bacs_debit" + }, + "bancontact": { + "$ref": "#/components/schemas/payment_method_details_bancontact" + }, + "blik": { + "$ref": "#/components/schemas/payment_method_details_blik" + }, + "boleto": { + "$ref": "#/components/schemas/payment_method_details_boleto" + }, + "card": { + "$ref": "#/components/schemas/payment_method_details_card" + }, + "card_present": { + "$ref": "#/components/schemas/payment_method_details_card_present" + }, + "cashapp": { + "$ref": "#/components/schemas/payment_method_details_cashapp" + }, + "customer_balance": { + "$ref": "#/components/schemas/payment_method_details_customer_balance" + }, + "eps": { + "$ref": "#/components/schemas/payment_method_details_eps" + }, + "fpx": { + "$ref": "#/components/schemas/payment_method_details_fpx" + }, + "giropay": { + "$ref": "#/components/schemas/payment_method_details_giropay" + }, + "grabpay": { + "$ref": "#/components/schemas/payment_method_details_grabpay" + }, + "ideal": { + "$ref": "#/components/schemas/payment_method_details_ideal" + }, + "interac_present": { + "$ref": "#/components/schemas/payment_method_details_interac_present" + }, + "klarna": { + "$ref": "#/components/schemas/payment_method_details_klarna" + }, + "konbini": { + "$ref": "#/components/schemas/payment_method_details_konbini" + }, + "link": { + "$ref": "#/components/schemas/payment_method_details_link" + }, + "mobilepay": { + "$ref": "#/components/schemas/payment_method_details_mobilepay" + }, + "multibanco": { + "$ref": "#/components/schemas/payment_method_details_multibanco" + }, + "oxxo": { + "$ref": "#/components/schemas/payment_method_details_oxxo" + }, + "p24": { + "$ref": "#/components/schemas/payment_method_details_p24" + }, + "paynow": { + "$ref": "#/components/schemas/payment_method_details_paynow" + }, + "paypal": { + "$ref": "#/components/schemas/payment_method_details_paypal" + }, + "pix": { + "$ref": "#/components/schemas/payment_method_details_pix" + }, + "promptpay": { + "$ref": "#/components/schemas/payment_method_details_promptpay" + }, + "revolut_pay": { + "$ref": "#/components/schemas/payment_method_details_revolut_pay" + }, + "sepa_debit": { + "$ref": "#/components/schemas/payment_method_details_sepa_debit" + }, + "sofort": { + "$ref": "#/components/schemas/payment_method_details_sofort" + }, + "stripe_account": { + "$ref": "#/components/schemas/payment_method_details_stripe_account" + }, + "swish": { + "$ref": "#/components/schemas/payment_method_details_swish" + }, + "twint": { + "$ref": "#/components/schemas/payment_method_details_twint" + }, + "type": { + "description": "The type of transaction-specific details of the payment method used in the payment, one of `ach_credit_transfer`, `ach_debit`, `acss_debit`, `alipay`, `au_becs_debit`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `klarna`, `multibanco`, `p24`, `sepa_debit`, `sofort`, `stripe_account`, or `wechat`.\nAn additional hash is included on `payment_method_details` with a name matching this value.\nIt contains information specific to the payment method.", "maxLength": 5000, "type": "string" }, - "verification": { - "anyOf": [ - { - "$ref": "#/components/schemas/tax_id_verification" - } - ], - "description": "Tax ID verification information.", - "nullable": true + "us_bank_account": { + "$ref": "#/components/schemas/payment_method_details_us_bank_account" + }, + "wechat": { + "$ref": "#/components/schemas/payment_method_details_wechat" + }, + "wechat_pay": { + "$ref": "#/components/schemas/payment_method_details_wechat_pay" + }, + "zip": { + "$ref": "#/components/schemas/payment_method_details_zip" } }, - "required": ["created", "id", "livemode", "object", "type", "value"], - "title": "tax_id", + "required": ["type"], + "title": "payment_method_details", "type": "object", - "x-expandableFields": ["customer", "verification"], - "x-resourceId": "tax_id" + "x-expandableFields": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "card_present", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "interac_present", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "stripe_account", + "swish", + "twint", + "us_bank_account", + "wechat", + "wechat_pay", + "zip" + ] }, - "tax_id_verification": { + "payment_method_details_ach_credit_transfer": { "description": "", "properties": { - "status": { - "description": "Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`.", - "enum": ["pending", "unavailable", "unverified", "verified"], + "account_number": { + "description": "Account number to transfer funds to.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "verified_address": { - "description": "Verified address.", + "bank_name": { + "description": "Name of the bank associated with the routing number.", "maxLength": 5000, "nullable": true, "type": "string" }, - "verified_name": { - "description": "Verified name.", + "routing_number": { + "description": "Routing transit number for the bank account to transfer funds to.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "swift_code": { + "description": "SWIFT code of the bank associated with the routing number.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "required": ["status"], - "title": "tax_id_verification", + "title": "payment_method_details_ach_credit_transfer", "type": "object", "x-expandableFields": [] }, - "tax_rate": { - "description": "Tax rates can be applied to [invoices](https://stripe.com/docs/billing/invoices/tax-rates), [subscriptions](https://stripe.com/docs/billing/subscriptions/taxes) and [Checkout Sessions](https://stripe.com/docs/payments/checkout/set-up-a-subscription#tax-rates) to collect tax.\n\nRelated guide: [Tax Rates](https://stripe.com/docs/billing/taxes/tax-rates).", + "payment_method_details_ach_debit": { + "description": "", "properties": { - "active": { - "description": "Defaults to `true`. When set to `false`, this tax rate cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.", - "type": "boolean" + "account_holder_type": { + "description": "Type of entity that holds the account. This can be either `individual` or `company`.", + "enum": ["company", "individual"], + "nullable": true, + "type": "string" }, - "country": { - "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "bank_name": { + "description": "Name of the bank associated with the bank account.", "maxLength": 5000, "nullable": true, "type": "string" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" - }, - "description": { - "description": "An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.", + "country": { + "description": "Two-letter ISO code representing the country the bank account is located in.", "maxLength": 5000, "nullable": true, "type": "string" }, - "display_name": { - "description": "The display name of the tax rates as it will appear to your customer on their receipt email, PDF, and the hosted invoice page.", + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "last4": { + "description": "Last four digits of the bank account number.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "inclusive": { - "description": "This specifies if the tax rate is inclusive or exclusive.", - "type": "boolean" - }, - "jurisdiction": { - "description": "The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.", + "routing_number": { + "description": "Routing transit number of the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_ach_debit", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_acss_debit": { + "description": "", + "properties": { + "bank_name": { + "description": "Name of the bank associated with the bank account.", "maxLength": 5000, "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "institution_number": { + "description": "Institution number of the bank account", + "maxLength": 5000, "nullable": true, - "type": "object" + "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["tax_rate"], + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "percentage": { - "description": "This represents the tax rate percent out of 100.", - "type": "number" + "mandate": { + "description": "ID of the mandate used to make this payment.", + "maxLength": 5000, + "type": "string" }, - "state": { - "description": "[ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, \"NY\" for New York, United States.", + "transit_number": { + "description": "Transit number of the bank account.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "required": [ - "active", - "created", - "display_name", - "id", - "inclusive", - "livemode", - "object", - "percentage" - ], - "title": "TaxRate", + "title": "payment_method_details_acss_debit", "type": "object", - "x-expandableFields": [], - "x-resourceId": "tax_rate" + "x-expandableFields": [] }, - "terminal.connection_token": { - "description": "A Connection Token is used by the Stripe Terminal SDK to connect to a reader.\n\nRelated guide: [Fleet Management](https://stripe.com/docs/terminal/readers/fleet-management#create).", + "payment_method_details_affirm": { + "description": "", "properties": { - "location": { - "description": "The id of the location that this connection token is scoped to.", + "transaction_id": { + "description": "The Affirm transaction ID associated with this payment.", "maxLength": 5000, + "nullable": true, "type": "string" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["terminal.connection_token"], + } + }, + "title": "payment_method_details_affirm", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_afterpay_clearpay": { + "description": "", + "properties": { + "order_id": { + "description": "The Afterpay order ID associated with this payment intent.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "secret": { - "description": "Your application should pass this token to the Stripe Terminal SDK.", + "reference": { + "description": "Order identifier shown to the merchant in Afterpay’s online portal.", "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["object", "secret"], - "title": "TerminalConnectionToken", + "title": "payment_method_details_afterpay_clearpay", "type": "object", - "x-expandableFields": [], - "x-resourceId": "terminal.connection_token" + "x-expandableFields": [] }, - "terminal.location": { - "description": "A Location represents a grouping of readers.\n\nRelated guide: [Fleet Management](https://stripe.com/docs/terminal/readers/fleet-management#create).", + "payment_method_details_amazon_pay": { + "description": "", + "properties": {}, + "title": "payment_method_details_amazon_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_au_becs_debit": { + "description": "", "properties": { - "address": { - "$ref": "#/components/schemas/address" - }, - "display_name": { - "description": "The display name of the location.", + "bsb_number": { + "description": "Bank-State-Branch number of the bank account.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["terminal.location"], + "mandate": { + "description": "ID of the mandate used to make this payment.", + "maxLength": 5000, "type": "string" } }, - "required": [ - "address", - "display_name", - "id", - "livemode", - "metadata", - "object" - ], - "title": "TerminalLocationLocation", + "title": "payment_method_details_au_becs_debit", "type": "object", - "x-expandableFields": ["address"], - "x-resourceId": "terminal.location" + "x-expandableFields": [] }, - "terminal.reader": { - "description": "A Reader represents a physical device for accepting payment details.\n\nRelated guide: [Connecting to a Reader](https://stripe.com/docs/terminal/readers/connecting).", + "payment_method_details_bacs_debit": { + "description": "", "properties": { - "device_sw_version": { - "description": "The current software version of the reader.", + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", "maxLength": 5000, "nullable": true, "type": "string" }, - "device_type": { - "description": "Type of reader, one of `bbpos_chipper2x` or `verifone_P400`.", - "enum": ["bbpos_chipper2x", "verifone_P400"], + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "mandate": { + "description": "ID of the mandate used to make this payment.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "ip_address": { - "description": "The local IP address of the reader.", + "sort_code": { + "description": "Sort code of the bank account. (e.g., `10-20-30`)", "maxLength": 5000, "nullable": true, "type": "string" - }, - "label": { - "description": "Custom label given to the reader for easier identification.", + } + }, + "title": "payment_method_details_bacs_debit", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_bancontact": { + "description": "", + "properties": { + "bank_code": { + "description": "Bank code of bank associated with the bank account.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "bank_name": { + "description": "Name of the bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "location": { - "description": "The location identifier of the reader.", + "bic": { + "description": "Bank Identifier Code of the bank associated with the bank account.", "maxLength": 5000, "nullable": true, "type": "string" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" + "generated_sepa_debit": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["terminal.reader"], - "type": "string" + "generated_sepa_debit_mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/mandate" + } + ], + "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" + } + ] + } }, - "serial_number": { - "description": "Serial number of the reader.", + "iban_last4": { + "description": "Last four characters of the IBAN.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "status": { - "description": "The networking status of the reader.", + "preferred_language": { + "description": "Preferred language of the Bancontact authorization page that the customer is redirected to.\nCan be one of `en`, `de`, `fr`, or `nl`", + "enum": ["de", "en", "fr", "nl"], + "nullable": true, + "type": "string" + }, + "verified_name": { + "description": "Owner's verified full name. Values are verified or provided by Bancontact directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "required": [ - "device_type", - "id", - "label", - "livemode", - "metadata", - "object", - "serial_number" - ], - "title": "TerminalReaderReader", + "title": "payment_method_details_bancontact", "type": "object", - "x-expandableFields": [], - "x-resourceId": "terminal.reader" + "x-expandableFields": [ + "generated_sepa_debit", + "generated_sepa_debit_mandate" + ] }, - "three_d_secure": { - "description": "Cardholder authentication via 3D Secure is initiated by creating a `3D Secure`\nobject. Once the object has been created, you can use it to authenticate the\ncardholder and create a charge.", + "payment_method_details_blik": { + "description": "", "properties": { - "amount": { - "description": "Amount of the charge that you will create when authentication completes.", + "buyer_id": { + "description": "A unique and immutable identifier assigned by BLIK to every buyer.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_blik", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_boleto": { + "description": "", + "properties": { + "tax_id": { + "description": "The tax ID of the customer (CPF for individuals consumers or CNPJ for businesses consumers)", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "payment_method_details_boleto", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_card": { + "description": "", + "properties": { + "amount_authorized": { + "description": "The authorized amount.", + "nullable": true, "type": "integer" }, - "authenticated": { - "description": "True if the cardholder went through the authentication flow and their bank indicated that authentication succeeded.", - "type": "boolean" + "authorization_code": { + "description": "Authorization code on the charge.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "card": { - "$ref": "#/components/schemas/card" + "brand": { + "description": "Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "capture_before": { + "description": "When using manual capture, a future timestamp at which the charge will be automatically refunded if uncaptured.", "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "checks": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_details_card_checks" + } + ], + "description": "Check results by Card networks on Card address and CVC at time of payment.", + "nullable": true + }, + "country": { + "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "exp_month": { + "description": "Two-digit number representing the card's expiration month.", + "type": "integer" + }, + "exp_year": { + "description": "Four-digit number representing the card's expiration year.", + "type": "integer" + }, + "extended_authorization": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_card_details_api_resource_enterprise_features_extended_authorization_extended_authorization" + }, + "fingerprint": { + "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.\n\n*As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*", "maxLength": 5000, + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "funding": { + "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["three_d_secure"], + "incremental_authorization": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_card_details_api_resource_enterprise_features_incremental_authorization_incremental_authorization" + }, + "installments": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_details_card_installments" + } + ], + "description": "Installment details for this payment (Mexico only).\n\nFor more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).", + "nullable": true + }, + "last4": { + "description": "The last four digits of the card.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "redirect_url": { - "description": "If present, this is the URL that you should send the cardholder to for authentication. If you are going to use Stripe.js to display the authentication page in an iframe, you should use the value \"_callback\".", + "mandate": { + "description": "ID of the mandate used to make this payment or created by it.", "maxLength": 5000, "nullable": true, "type": "string" }, - "status": { - "description": "Possible values are `redirect_pending`, `succeeded`, or `failed`. When the cardholder can be authenticated, the object starts with status `redirect_pending`. When liability will be shifted to the cardholder's bank (either because the cardholder was successfully authenticated, or because the bank has not implemented 3D Secure, the object wlil be in status `succeeded`. `failed` indicates that authentication was attempted unsuccessfully.", + "multicapture": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_card_details_api_resource_multicapture" + }, + "network": { + "description": "Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", "maxLength": 5000, + "nullable": true, "type": "string" + }, + "network_token": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_details_card_network_token" + } + ], + "description": "If this card has network token credentials, this contains the details of the network token credentials.", + "nullable": true + }, + "overcapture": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_card_details_api_resource_enterprise_features_overcapture_overcapture" + }, + "three_d_secure": { + "anyOf": [ + { + "$ref": "#/components/schemas/three_d_secure_details_charge" + } + ], + "description": "Populated if this transaction used 3D Secure authentication.", + "nullable": true + }, + "wallet": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_details_card_wallet" + } + ], + "description": "If this Card is part of a card wallet, this contains the details of the card wallet.", + "nullable": true } }, - "required": [ - "amount", - "authenticated", - "card", - "created", - "currency", - "id", - "livemode", - "object", - "status" - ], - "title": "ThreeDSecure", + "required": ["exp_month", "exp_year"], + "title": "payment_method_details_card", "type": "object", - "x-expandableFields": ["card"], - "x-resourceId": "three_d_secure" + "x-expandableFields": [ + "checks", + "extended_authorization", + "incremental_authorization", + "installments", + "multicapture", + "network_token", + "overcapture", + "three_d_secure", + "wallet" + ] }, - "three_d_secure_details": { + "payment_method_details_card_checks": { "description": "", "properties": { - "authentication_flow": { - "description": "For authenticated transactions: how the customer was authenticated by\nthe issuing bank.", - "enum": ["challenge", "frictionless"], + "address_line1_check": { + "description": "If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "result": { - "description": "Indicates the outcome of 3D Secure authentication.", - "enum": [ - "attempt_acknowledged", - "authenticated", - "failed", - "not_supported", - "processing_error" - ], - "type": "string" - }, - "result_reason": { - "description": "Additional information about why 3D Secure succeeded or failed based\non the `result`.", - "enum": [ - "abandoned", - "bypassed", - "canceled", - "card_not_enrolled", - "network_not_supported", - "protocol_error", - "rejected" - ], + "address_postal_code_check": { + "description": "If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, "nullable": true, "type": "string" }, - "version": { - "description": "The version of 3D Secure that was used.", - "enum": ["1.0.2", "2.1.0", "2.2.0"], + "cvc_check": { + "description": "If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["result", "version"], - "title": "three_d_secure_details", + "title": "payment_method_details_card_checks", "type": "object", "x-expandableFields": [] }, - "three_d_secure_usage": { + "payment_method_details_card_installments": { "description": "", "properties": { - "supported": { - "description": "Whether 3D Secure is supported on this card.", - "type": "boolean" + "plan": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_details_card_installments_plan" + } + ], + "description": "Installment plan selected for the payment.", + "nullable": true } }, - "required": ["supported"], - "title": "three_d_secure_usage", + "title": "payment_method_details_card_installments", "type": "object", - "x-expandableFields": [] + "x-expandableFields": ["plan"] }, - "token": { - "description": "Tokenization is the process Stripe uses to collect sensitive card or bank\naccount details, or personally identifiable information (PII), directly from\nyour customers in a secure manner. A token representing this information is\nreturned to your server to use. You should use our\n[recommended payments integrations](https://stripe.com/docs/payments) to perform this process\nclient-side. This ensures that no sensitive card data touches your server,\nand allows your integration to operate in a PCI-compliant way.\n\nIf you cannot use client-side tokenization, you can also create tokens using\nthe API with either your publishable or secret API key. Keep in mind that if\nyour integration uses this method, you are responsible for any PCI compliance\nthat may be required, and you must keep your secret API key safe. Unlike with\nclient-side tokenization, your customer's information is not sent directly to\nStripe, so we cannot determine how it is handled or stored.\n\nTokens cannot be stored or used more than once. To store card or bank account\ninformation for later use, you can create [Customer](https://stripe.com/docs/api#customers)\nobjects or [Custom accounts](https://stripe.com/docs/api#external_accounts). Note that\n[Radar](https://stripe.com/docs/radar), our integrated solution for automatic fraud protection,\nsupports only integrations that use client-side tokenization.\n\nRelated guide: [Accept a payment](https://stripe.com/docs/payments/accept-a-payment-charges#web-create-token)", + "payment_method_details_card_installments_plan": { + "description": "", "properties": { - "bank_account": { - "$ref": "#/components/schemas/bank_account" - }, - "card": { - "$ref": "#/components/schemas/card" - }, - "client_ip": { - "description": "IP address of the client that generated the token.", - "maxLength": 5000, + "count": { + "description": "For `fixed_count` installment plans, this is the number of installment payments your customer will make to their credit card.", "nullable": true, - "type": "string" - }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", "type": "integer" }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, - "type": "string" - }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["token"], + "interval": { + "description": "For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card.\nOne of `month`.", + "enum": ["month"], + "nullable": true, "type": "string" }, "type": { - "description": "Type of the token: `account`, `bank_account`, `card`, or `pii`.", - "maxLength": 5000, - "type": "string" - }, + "description": "Type of installment plan, one of `fixed_count`.", + "enum": ["fixed_count"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "payment_method_details_card_installments_plan", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_card_network_token": { + "description": "", + "properties": { "used": { - "description": "Whether this token has already been used (tokens can be used only once).", + "description": "Indicates if Stripe used a network token, either user provided or Stripe managed when processing the transaction.", "type": "boolean" } }, - "required": ["created", "id", "livemode", "object", "type", "used"], - "title": "Token", + "required": ["used"], + "title": "payment_method_details_card_network_token", "type": "object", - "x-expandableFields": ["bank_account", "card"], - "x-resourceId": "token" + "x-expandableFields": [] }, - "topup": { - "description": "To top up your Stripe balance, you create a top-up object. You can retrieve\nindividual top-ups, as well as list all top-ups. Top-ups are identified by a\nunique, random ID.\n\nRelated guide: [Topping Up your Platform Account](https://stripe.com/docs/connect/top-ups).", + "payment_method_details_card_present": { + "description": "", "properties": { - "amount": { - "description": "Amount transferred.", + "amount_authorized": { + "description": "The authorized amount", + "nullable": true, "type": "integer" }, - "balance_transaction": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/balance_transaction" - } - ], - "description": "ID of the balance transaction that describes the impact of this top-up on your account balance. May not be specified depending on status of top-up.", + "brand": { + "description": "Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/balance_transaction" - } - ] - } + "type": "string" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "brand_product": { + "description": "The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "capture_before": { + "description": "When using manual capture, a future timestamp after which the charge will be automatically refunded if uncaptured.", "format": "unix-time", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "cardholder_name": { + "description": "The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "country": { + "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", "maxLength": 5000, + "nullable": true, "type": "string" }, "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "description": "A high-level description of the type of cards issued in this range.", "maxLength": 5000, "nullable": true, "type": "string" }, - "expected_availability_date": { - "description": "Date the funds are expected to arrive in your Stripe account for payouts. This factors in delays like weekends or bank holidays. May not be specified depending on status of top-up.", + "emv_auth_data": { + "description": "Authorization response cryptogram.", + "maxLength": 5000, "nullable": true, + "type": "string" + }, + "exp_month": { + "description": "Two-digit number representing the card's expiration month.", "type": "integer" }, - "failure_code": { - "description": "Error code explaining reason for top-up failure if available (see [the errors section](https://stripe.com/docs/api#errors) for a list of codes).", + "exp_year": { + "description": "Four-digit number representing the card's expiration year.", + "type": "integer" + }, + "fingerprint": { + "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.\n\n*As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*", "maxLength": 5000, "nullable": true, "type": "string" }, - "failure_message": { - "description": "Message to user further explaining reason for top-up failure if available.", + "funding": { + "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", "maxLength": 5000, "nullable": true, "type": "string" }, - "id": { - "description": "Unique identifier for the object.", + "generated_card": { + "description": "ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "incremental_authorization_supported": { + "description": "Whether this [PaymentIntent](https://stripe.com/docs/api/payment_intents) is eligible for incremental authorizations. Request support using [request_incremental_authorization_support](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_options-card_present-request_incremental_authorization_support).", "type": "boolean" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["topup"], + "issuer": { + "description": "The name of the card's issuing bank.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "source": { - "$ref": "#/components/schemas/source" - }, - "statement_descriptor": { - "description": "Extra information about a top-up. This will appear on your source's bank statement. It must contain at least one letter.", + "last4": { + "description": "The last four digits of the card.", "maxLength": 5000, "nullable": true, "type": "string" }, - "status": { - "description": "The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`.", - "enum": ["canceled", "failed", "pending", "reversed", "succeeded"], + "network": { + "description": "Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "transfer_group": { - "description": "A string that identifies this top-up as part of a group.", + "network_transaction_id": { + "description": "This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. The first three digits of the Trace ID is the Financial Network Code, the next 6 digits is the Banknet Reference Number, and the last 4 digits represent the date (MM/DD). This field will be available for successful Visa, Mastercard, or American Express transactions and always null for other card brands.", "maxLength": 5000, "nullable": true, "type": "string" - } - }, - "required": [ - "amount", - "created", - "currency", - "id", - "livemode", - "metadata", - "object", - "source", - "status" - ], - "title": "Topup", - "type": "object", - "x-expandableFields": ["balance_transaction", "source"], - "x-resourceId": "topup" - }, - "transfer": { - "description": "A `Transfer` object is created when you move funds between Stripe accounts as\npart of Connect.\n\nBefore April 6, 2017, transfers also represented movement of funds from a\nStripe account to a card or bank account. This behavior has since been split\nout into a [Payout](https://stripe.com/docs/api#payout_object) object, with corresponding payout endpoints. For more\ninformation, read about the\n[transfer/payout split](https://stripe.com/docs/transfer-payout-split).\n\nRelated guide: [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/charges-transfers).", - "properties": { - "amount": { - "description": "Amount in %s to be transferred.", - "type": "integer" - }, - "amount_reversed": { - "description": "Amount in %s reversed (can be less than the amount attribute on the transfer if a partial reversal was issued).", - "type": "integer" }, - "balance_transaction": { + "offline": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/payment_method_details_card_present_offline" } ], - "description": "Balance transaction that describes the impact of this transfer on your account balance.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/balance_transaction" - } - ] - } - }, - "created": { - "description": "Time that this record of the transfer was first created.", - "format": "unix-time", - "type": "integer" + "description": "Details about payments collected offline.", + "nullable": true }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" + "overcapture_supported": { + "description": "Defines whether the authorized amount can be over-captured or not", + "type": "boolean" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 5000, + "preferred_locales": { + "description": "EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.", + "items": { + "maxLength": 5000, + "type": "string" + }, "nullable": true, - "type": "string" + "type": "array" }, - "destination": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/account" - } + "read_method": { + "description": "How card details were read in this transaction.", + "enum": [ + "contact_emv", + "contactless_emv", + "contactless_magstripe_mode", + "magnetic_stripe_fallback", + "magnetic_stripe_track2" ], - "description": "ID of the Stripe account the transfer was sent to.", "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/account" - } - ] - } + "type": "string" }, - "destination_payment": { + "receipt": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/payment_method_details_card_present_receipt" } ], - "description": "If the destination is a Stripe account, this will be the ID of the payment that the destination account received for the transfer.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/charge" - } - ] - } + "description": "A collection of fields required to be displayed on receipts. Only required for EMV transactions.", + "nullable": true }, - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "wallet": { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_card_present_common_wallet" + } + }, + "required": [ + "exp_month", + "exp_year", + "incremental_authorization_supported", + "overcapture_supported" + ], + "title": "payment_method_details_card_present", + "type": "object", + "x-expandableFields": ["offline", "receipt", "wallet"] + }, + "payment_method_details_card_present_offline": { + "description": "", + "properties": { + "stored_at": { + "description": "Time at which the payment was collected while offline", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "type": { + "description": "The method used to process this payment method offline. Only deferred is allowed.", + "enum": ["deferred"], + "nullable": true, "type": "string" + } + }, + "title": "payment_method_details_card_present_offline", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_card_present_receipt": { + "description": "", + "properties": { + "account_type": { + "description": "The type of account being debited or credited", + "enum": ["checking", "credit", "prepaid", "unknown"], + "type": "string", + "x-stripeBypassValidation": true }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "application_cryptogram": { + "description": "EMV tag 9F26, cryptogram generated by the integrated circuit chip.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" + "application_preferred_name": { + "description": "Mnenomic of the Application Identifier.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["transfer"], + "authorization_code": { + "description": "Identifier for this transaction.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "reversals": { - "description": "A list of reversals that have been applied to the transfer.", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/transfer_reversal" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "TransferReversalList", - "type": "object", - "x-expandableFields": ["data"] + "authorization_response_code": { + "description": "EMV tag 8A. A code returned by the card issuer.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "reversed": { - "description": "Whether the transfer has been fully reversed. If the transfer is only partially reversed, this attribute will still be false.", - "type": "boolean" + "cardholder_verification_method": { + "description": "Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "source_transaction": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/charge" - } - ], - "description": "ID of the charge or payment that was used to fund the transfer. If null, the transfer was funded from the available balance.", + "dedicated_file_name": { + "description": "EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/charge" - } - ] - } + "type": "string" }, - "source_type": { - "description": "The source balance this transfer came from. One of `card`, `fpx`, or `bank_account`.", + "terminal_verification_results": { + "description": "The outcome of a series of EMV functions performed by the card reader.", "maxLength": 5000, "nullable": true, "type": "string" }, - "transfer_group": { - "description": "A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details.", + "transaction_status_information": { + "description": "An indication of various EMV functions performed during the transaction.", "maxLength": 5000, "nullable": true, "type": "string" } }, - "required": [ - "amount", - "amount_reversed", - "created", - "currency", - "id", - "livemode", - "metadata", - "object", - "reversals", - "reversed" - ], - "title": "Transfer", + "title": "payment_method_details_card_present_receipt", "type": "object", - "x-expandableFields": [ - "balance_transaction", - "destination", - "destination_payment", - "reversals", - "source_transaction" - ], - "x-resourceId": "transfer" + "x-expandableFields": [] }, - "transfer_data": { + "payment_method_details_card_wallet": { "description": "", "properties": { - "amount": { - "description": "Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", - "type": "integer" + "amex_express_checkout": { + "$ref": "#/components/schemas/payment_method_details_card_wallet_amex_express_checkout" }, - "destination": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/account" - } + "apple_pay": { + "$ref": "#/components/schemas/payment_method_details_card_wallet_apple_pay" + }, + "dynamic_last4": { + "description": "(For tokenized numbers only.) The last four digits of the device account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "google_pay": { + "$ref": "#/components/schemas/payment_method_details_card_wallet_google_pay" + }, + "link": { + "$ref": "#/components/schemas/payment_method_details_card_wallet_link" + }, + "masterpass": { + "$ref": "#/components/schemas/payment_method_details_card_wallet_masterpass" + }, + "samsung_pay": { + "$ref": "#/components/schemas/payment_method_details_card_wallet_samsung_pay" + }, + "type": { + "description": "The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, `visa_checkout`, or `link`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type.", + "enum": [ + "amex_express_checkout", + "apple_pay", + "google_pay", + "link", + "masterpass", + "samsung_pay", + "visa_checkout" ], - "description": "The account (if any) the payment will be attributed to for tax\nreporting, and where funds from the payment will be transferred to upon\npayment success.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/account" - } - ] - } + "type": "string" + }, + "visa_checkout": { + "$ref": "#/components/schemas/payment_method_details_card_wallet_visa_checkout" } }, - "required": ["destination"], - "title": "transfer_data", + "required": ["type"], + "title": "payment_method_details_card_wallet", "type": "object", - "x-expandableFields": ["destination"] + "x-expandableFields": [ + "amex_express_checkout", + "apple_pay", + "google_pay", + "link", + "masterpass", + "samsung_pay", + "visa_checkout" + ] }, - "transfer_reversal": { - "description": "[Stripe Connect](https://stripe.com/docs/connect) platforms can reverse transfers made to a\nconnected account, either entirely or partially, and can also specify whether\nto refund any related application fees. Transfer reversals add to the\nplatform's balance and subtract from the destination account's balance.\n\nReversing a transfer that was made for a [destination\ncharge](/docs/connect/destination-charges) is allowed only up to the amount of\nthe charge. It is possible to reverse a\n[transfer_group](https://stripe.com/docs/connect/charges-transfers#transfer-options)\ntransfer only if the destination account has enough balance to cover the\nreversal.\n\nRelated guide: [Reversing Transfers](https://stripe.com/docs/connect/charges-transfers#reversing-transfers).", + "payment_method_details_card_wallet_amex_express_checkout": { + "description": "", + "properties": {}, + "title": "payment_method_details_card_wallet_amex_express_checkout", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_card_wallet_apple_pay": { + "description": "", + "properties": {}, + "title": "payment_method_details_card_wallet_apple_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_card_wallet_google_pay": { + "description": "", + "properties": {}, + "title": "payment_method_details_card_wallet_google_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_card_wallet_link": { + "description": "", + "properties": {}, + "title": "payment_method_details_card_wallet_link", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_card_wallet_masterpass": { + "description": "", "properties": { - "amount": { - "description": "Amount, in %s.", - "type": "integer" - }, - "balance_transaction": { + "billing_address": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/address" } ], - "description": "Balance transaction that describes the impact on your account balance.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/balance_transaction" - } - ] - } + "description": "Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "nullable": true }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "email": { + "description": "Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "name": { + "description": "Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "destination_payment_refund": { + "shipping_address": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, + "$ref": "#/components/schemas/address" + } + ], + "description": "Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "nullable": true + } + }, + "title": "payment_method_details_card_wallet_masterpass", + "type": "object", + "x-expandableFields": ["billing_address", "shipping_address"] + }, + "payment_method_details_card_wallet_samsung_pay": { + "description": "", + "properties": {}, + "title": "payment_method_details_card_wallet_samsung_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_card_wallet_visa_checkout": { + "description": "", + "properties": { + "billing_address": { + "anyOf": [ { - "$ref": "#/components/schemas/refund" + "$ref": "#/components/schemas/address" } ], - "description": "Linked payment refund for the transfer reversal.", - "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/refund" - } - ] - } + "description": "Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "nullable": true }, - "id": { - "description": "Unique identifier for the object.", + "email": { + "description": "Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", "maxLength": 5000, - "type": "string" - }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", "nullable": true, - "type": "object" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["transfer_reversal"], "type": "string" }, - "source_refund": { - "anyOf": [ - { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/refund" - } - ], - "description": "ID of the refund responsible for the transfer reversal.", + "name": { + "description": "Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, "nullable": true, - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/refund" - } - ] - } + "type": "string" }, - "transfer": { + "shipping_address": { "anyOf": [ { - "maxLength": 5000, - "type": "string" - }, - { - "$ref": "#/components/schemas/transfer" + "$ref": "#/components/schemas/address" } ], - "description": "ID of the transfer that was reversed.", - "x-expansionResources": { - "oneOf": [ - { - "$ref": "#/components/schemas/transfer" - } - ] - } + "description": "Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "nullable": true } }, - "required": [ - "amount", - "created", - "currency", - "id", - "object", - "transfer" - ], - "title": "TransferReversal", + "title": "payment_method_details_card_wallet_visa_checkout", "type": "object", - "x-expandableFields": [ - "balance_transaction", - "destination_payment_refund", - "source_refund", - "transfer" - ], - "x-resourceId": "transfer_reversal" + "x-expandableFields": ["billing_address", "shipping_address"] }, - "transfer_schedule": { + "payment_method_details_cashapp": { "description": "", "properties": { - "delay_days": { - "description": "The number of days charges for the account will be held before being paid out.", - "type": "integer" - }, - "interval": { - "description": "How frequently funds will be paid out. One of `manual` (payouts only created via API call), `daily`, `weekly`, or `monthly`.", + "buyer_id": { + "description": "A unique and immutable identifier assigned by Cash App to every buyer.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "monthly_anchor": { - "description": "The day of the month funds will be paid out. Only shown if `interval` is monthly. Payouts scheduled between the 29th and 31st of the month are sent on the last day of shorter months.", - "type": "integer" - }, - "weekly_anchor": { - "description": "The day of the week funds will be paid out, of the style 'monday', 'tuesday', etc. Only shown if `interval` is weekly.", + "cashtag": { + "description": "A public identifier for buyers using Cash App.", "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": ["delay_days", "interval"], - "title": "TransferSchedule", + "title": "payment_method_details_cashapp", "type": "object", "x-expandableFields": [] }, - "transform_quantity": { + "payment_method_details_customer_balance": { "description": "", - "properties": { - "divide_by": { - "description": "Divide usage by this number.", - "type": "integer" - }, - "round": { - "description": "After division, either round the result `up` or `down`.", - "enum": ["down", "up"], - "type": "string" - } - }, - "required": ["divide_by", "round"], - "title": "TransformQuantity", + "properties": {}, + "title": "payment_method_details_customer_balance", "type": "object", "x-expandableFields": [] }, - "transform_usage": { + "payment_method_details_eps": { "description": "", "properties": { - "divide_by": { - "description": "Divide usage by this number.", - "type": "integer" - }, - "round": { - "description": "After division, either round the result `up` or `down`.", - "enum": ["down", "up"], - "type": "string" - } - }, - "required": ["divide_by", "round"], - "title": "TransformUsage", - "type": "object", - "x-expandableFields": [] - }, - "usage_record": { - "description": "Usage records allow you to report customer usage and metrics to Stripe for\nmetered billing of subscription prices.\n\nRelated guide: [Metered Billing](https://stripe.com/docs/billing/subscriptions/metered-billing).", - "properties": { - "id": { - "description": "Unique identifier for the object.", - "maxLength": 5000, + "bank": { + "description": "The customer's bank. Should be one of `arzte_und_apotheker_bank`, `austrian_anadi_bank_ag`, `bank_austria`, `bankhaus_carl_spangler`, `bankhaus_schelhammer_und_schattera_ag`, `bawag_psk_ag`, `bks_bank_ag`, `brull_kallmus_bank_ag`, `btv_vier_lander_bank`, `capital_bank_grawe_gruppe_ag`, `deutsche_bank_ag`, `dolomitenbank`, `easybank_ag`, `erste_bank_und_sparkassen`, `hypo_alpeadriabank_international_ag`, `hypo_noe_lb_fur_niederosterreich_u_wien`, `hypo_oberosterreich_salzburg_steiermark`, `hypo_tirol_bank_ag`, `hypo_vorarlberg_bank_ag`, `hypo_bank_burgenland_aktiengesellschaft`, `marchfelder_bank`, `oberbank_ag`, `raiffeisen_bankengruppe_osterreich`, `schoellerbank_ag`, `sparda_bank_wien`, `volksbank_gruppe`, `volkskreditbank_ag`, or `vr_bank_braunau`.", + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["usage_record"], + "verified_name": { + "description": "Owner's verified full name. Values are verified or provided by EPS directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.\nEPS rarely provides this information so the attribute is usually empty.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_eps", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_fpx": { + "description": "", + "properties": { + "bank": { + "description": "The customer's bank. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, `pb_enterprise`, or `bank_of_china`.", + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], "type": "string" }, - "quantity": { - "description": "The usage quantity for the specified date.", - "type": "integer" - }, - "subscription_item": { - "description": "The ID of the subscription item this usage record contains data for.", + "transaction_id": { + "description": "Unique transaction id generated by FPX for every request from the merchant", "maxLength": 5000, + "nullable": true, "type": "string" - }, - "timestamp": { - "description": "The timestamp when this usage occurred.", - "format": "unix-time", - "type": "integer" } }, - "required": [ - "id", - "livemode", - "object", - "quantity", - "subscription_item", - "timestamp" - ], - "title": "UsageRecord", + "required": ["bank"], + "title": "payment_method_details_fpx", "type": "object", - "x-expandableFields": [], - "x-resourceId": "usage_record" + "x-expandableFields": [] }, - "usage_record_summary": { + "payment_method_details_giropay": { "description": "", "properties": { - "id": { - "description": "Unique identifier for the object.", + "bank_code": { + "description": "Bank code of bank associated with the bank account.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "invoice": { - "description": "The invoice in which this usage period has been billed for.", + "bank_name": { + "description": "Name of the bank associated with the bank account.", "maxLength": 5000, "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "bic": { + "description": "Bank Identifier Code of the bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["usage_record_summary"], + "verified_name": { + "description": "Owner's verified full name. Values are verified or provided by Giropay directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.\nGiropay rarely provides this information so the attribute is usually empty.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_giropay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_grabpay": { + "description": "", + "properties": { + "transaction_id": { + "description": "Unique transaction id generated by GrabPay", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_grabpay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_ideal": { + "description": "", + "properties": { + "bank": { + "description": "The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `n26`, `nn`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, `van_lanschot`, or `yoursafe`.", + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "nullable": true, "type": "string" }, - "period": { - "$ref": "#/components/schemas/period" + "bic": { + "description": "The Bank Identifier Code of the customer's bank.", + "enum": [ + "ABNANL2A", + "ASNBNL21", + "BITSNL2A", + "BUNQNL2A", + "FVLBNL22", + "HANDNL2A", + "INGBNL2A", + "KNABNL2H", + "MOYONL21", + "NNBANL2G", + "NTSBDEB1", + "RABONL2U", + "RBRBNL21", + "REVOIE23", + "REVOLT21", + "SNSBNL2A", + "TRIONL2U" + ], + "nullable": true, + "type": "string" }, - "subscription_item": { - "description": "The ID of the subscription item this summary is describing.", + "generated_sepa_debit": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "generated_sepa_debit_mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/mandate" + } + ], + "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" + } + ] + } + }, + "iban_last4": { + "description": "Last four characters of the IBAN.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "total_usage": { - "description": "The total usage within this usage period.", - "type": "integer" + "verified_name": { + "description": "Owner's verified full name. Values are verified or provided by iDEAL directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" } }, - "required": [ - "id", - "livemode", - "object", - "period", - "subscription_item", - "total_usage" - ], - "title": "UsageRecordSummary", + "title": "payment_method_details_ideal", "type": "object", - "x-expandableFields": ["period"], - "x-resourceId": "usage_record_summary" + "x-expandableFields": [ + "generated_sepa_debit", + "generated_sepa_debit_mandate" + ] }, - "webhook_endpoint": { - "description": "You can configure [webhook endpoints](https://stripe.com/docs/webhooks/) via the API to be\nnotified about events that happen in your Stripe account or connected\naccounts.\n\nMost users configure webhooks from [the dashboard](https://dashboard.stripe.com/webhooks), which provides a user interface for registering and testing your webhook endpoints.\n\nRelated guide: [Setting up Webhooks](https://stripe.com/docs/webhooks/configure).", + "payment_method_details_interac_present": { + "description": "", "properties": { - "api_version": { - "description": "The API version events are rendered as for this webhook endpoint.", + "brand": { + "description": "Card brand. Can be `interac`, `mastercard` or `visa`.", "maxLength": 5000, "nullable": true, "type": "string" }, - "application": { - "description": "The ID of the associated Connect application.", + "cardholder_name": { + "description": "The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.", "maxLength": 5000, "nullable": true, "type": "string" }, - "created": { - "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", - "format": "unix-time", - "type": "integer" + "country": { + "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, "description": { - "description": "An optional description of what the webhook is used for.", + "description": "A high-level description of the type of cards issued in this range.", "maxLength": 5000, "nullable": true, "type": "string" }, - "enabled_events": { - "description": "The list of events to enable for this endpoint. `['*']` indicates that all events are enabled, except those that require explicit selection.", + "emv_auth_data": { + "description": "Authorization response cryptogram.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "exp_month": { + "description": "Two-digit number representing the card's expiration month.", + "type": "integer" + }, + "exp_year": { + "description": "Four-digit number representing the card's expiration year.", + "type": "integer" + }, + "fingerprint": { + "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.\n\n*As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "funding": { + "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "generated_card": { + "description": "ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "issuer": { + "description": "The name of the card's issuing bank.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "The last four digits of the card.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "network": { + "description": "Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "network_transaction_id": { + "description": "This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. The first three digits of the Trace ID is the Financial Network Code, the next 6 digits is the Banknet Reference Number, and the last 4 digits represent the date (MM/DD). This field will be available for successful Visa, Mastercard, or American Express transactions and always null for other card brands.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "preferred_locales": { + "description": "EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.", "items": { "maxLength": 5000, "type": "string" }, + "nullable": true, "type": "array" }, - "id": { - "description": "Unique identifier for the object.", + "read_method": { + "description": "How card details were read in this transaction.", + "enum": [ + "contact_emv", + "contactless_emv", + "contactless_magstripe_mode", + "magnetic_stripe_fallback", + "magnetic_stripe_track2" + ], + "nullable": true, + "type": "string" + }, + "receipt": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_details_interac_present_receipt" + } + ], + "description": "A collection of fields required to be displayed on receipts. Only required for EMV transactions.", + "nullable": true + } + }, + "required": ["exp_month", "exp_year"], + "title": "payment_method_details_interac_present", + "type": "object", + "x-expandableFields": ["receipt"] + }, + "payment_method_details_interac_present_receipt": { + "description": "", + "properties": { + "account_type": { + "description": "The type of account being debited or credited", + "enum": ["checking", "savings", "unknown"], + "type": "string", + "x-stripeBypassValidation": true + }, + "application_cryptogram": { + "description": "EMV tag 9F26, cryptogram generated by the integrated circuit chip.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "livemode": { - "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", - "type": "boolean" + "application_preferred_name": { + "description": "Mnenomic of the Application Identifier.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "metadata": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", - "type": "object" + "authorization_code": { + "description": "Identifier for this transaction.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value.", - "enum": ["webhook_endpoint"], + "authorization_response_code": { + "description": "EMV tag 8A. A code returned by the card issuer.", + "maxLength": 5000, + "nullable": true, "type": "string" }, - "secret": { - "description": "The endpoint's secret, used to generate [webhook signatures](https://stripe.com/docs/webhooks/signatures). Only returned at creation.", + "cardholder_verification_method": { + "description": "Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "status": { - "description": "The status of the webhook. It can be `enabled` or `disabled`.", + "dedicated_file_name": { + "description": "EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.", "maxLength": 5000, + "nullable": true, "type": "string" }, - "url": { - "description": "The URL of the webhook endpoint.", + "terminal_verification_results": { + "description": "The outcome of a series of EMV functions performed by the card reader.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "transaction_status_information": { + "description": "An indication of various EMV functions performed during the transaction.", "maxLength": 5000, + "nullable": true, "type": "string" } }, - "required": [ - "created", - "enabled_events", - "id", - "livemode", - "metadata", - "object", - "status", - "url" - ], - "title": "NotificationWebhookEndpoint", + "title": "payment_method_details_interac_present_receipt", "type": "object", - "x-expandableFields": [], - "x-resourceId": "webhook_endpoint" - } - }, - "securitySchemes": { - "basicAuth": { - "description": "Basic HTTP authentication. Allowed headers-- Authorization: Basic | Authorization: Basic ", - "scheme": "basic", - "type": "http" + "x-expandableFields": [] }, - "bearerAuth": { - "bearerFormat": "auth-scheme", - "description": "Bearer HTTP authentication. Allowed headers-- Authorization: Bearer ", - "scheme": "bearer", - "type": "http" - } - } - }, - "info": { - "contact": { - "email": "dev-platform@stripe.com", - "name": "Stripe Dev Platform Team", - "url": "https://stripe.com" - }, - "description": "The Stripe REST API. Please see https://stripe.com/docs/api for more details.", - "termsOfService": "https://stripe.com/us/terms/", - "title": "Stripe API", - "version": "2020-08-27", - "x-stripeSpecFilename": "spec3" - }, - "openapi": "3.0.0", - "paths": { - "/v1/3d_secure": { - "post": { - "description": "

Initiate 3D Secure authentication.

", - "operationId": "Post3dSecure", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "amount": { - "description": "Amount of the charge that you will create when authentication completes.", - "type": "integer" - }, - "card": { - "description": "The ID of a card token, or the ID of a card belonging to the given customer.", - "maxLength": 5000, - "type": "string" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "customer": { - "description": "The customer associated with this 3D secure authentication.", - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "return_url": { - "description": "The URL that the cardholder's browser will be returned to when authentication completes.", - "type": "string" - } - }, - "required": ["amount", "currency", "return_url"], - "type": "object" - } - } + "payment_method_details_klarna": { + "description": "", + "properties": { + "payment_method_category": { + "description": "The Klarna payment method used for this transaction.\nCan be one of `pay_later`, `pay_now`, `pay_with_financing`, or `pay_in_installments`", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "required": true + "preferred_locale": { + "description": "Preferred language of the Klarna authorization page that the customer is redirected to.\nCan be one of `de-AT`, `en-AT`, `nl-BE`, `fr-BE`, `en-BE`, `de-DE`, `en-DE`, `da-DK`, `en-DK`, `es-ES`, `en-ES`, `fi-FI`, `sv-FI`, `en-FI`, `en-GB`, `en-IE`, `it-IT`, `en-IT`, `nl-NL`, `en-NL`, `nb-NO`, `en-NO`, `sv-SE`, `en-SE`, `en-US`, `es-US`, `fr-FR`, `en-FR`, `cs-CZ`, `en-CZ`, `ro-RO`, `en-RO`, `el-GR`, `en-GR`, `en-AU`, `en-NZ`, `en-CA`, `fr-CA`, `pl-PL`, `en-PL`, `pt-PT`, `en-PT`, `de-CH`, `fr-CH`, `it-CH`, or `en-CH`", + "maxLength": 5000, + "nullable": true, + "type": "string" + } }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/three_d_secure" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } + "title": "payment_method_details_klarna", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_konbini": { + "description": "", + "properties": { + "store": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_details_konbini_store" } - }, - "description": "Error response." + ], + "description": "If the payment succeeded, this contains the details of the convenience store where the payment was completed.", + "nullable": true } - } - } - }, - "/v1/3d_secure/{three_d_secure}": { - "get": { - "description": "

Retrieves a 3D Secure object.

", - "operationId": "Get3dSecureThreeDSecure", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "three_d_secure", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" + }, + "title": "payment_method_details_konbini", + "type": "object", + "x-expandableFields": ["store"] + }, + "payment_method_details_konbini_store": { + "description": "", + "properties": { + "chain": { + "description": "The name of the convenience store chain where the payment was completed.", + "enum": ["familymart", "lawson", "ministop", "seicomart"], + "nullable": true, + "type": "string" } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" + }, + "title": "payment_method_details_konbini_store", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_link": { + "description": "", + "properties": { + "country": { + "description": "Two-letter ISO code representing the funding source country beneath the Link payment.\nYou could use this attribute to get a sense of international fees.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_link", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_mobilepay": { + "description": "", + "properties": { + "card": { + "anyOf": [ + { + "$ref": "#/components/schemas/internal_card" } - } + ], + "description": "Internal card details", + "nullable": true + } + }, + "title": "payment_method_details_mobilepay", + "type": "object", + "x-expandableFields": ["card"] + }, + "payment_method_details_multibanco": { + "description": "", + "properties": { + "entity": { + "description": "Entity number associated with this Multibanco payment.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "required": false + "reference": { + "description": "Reference number associated with this Multibanco payment.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/three_d_secure" - } - } - }, - "description": "Successful response." + "title": "payment_method_details_multibanco", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_oxxo": { + "description": "", + "properties": { + "number": { + "description": "OXXO reference number", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_oxxo", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_p24": { + "description": "", + "properties": { + "bank": { + "description": "The customer's bank. Can be one of `ing`, `citi_handlowy`, `tmobile_usbugi_bankowe`, `plus_bank`, `etransfer_pocztowy24`, `banki_spbdzielcze`, `bank_nowy_bfg_sa`, `getin_bank`, `velobank`, `blik`, `noble_pay`, `ideabank`, `envelobank`, `santander_przelew24`, `nest_przelew`, `mbank_mtransfer`, `inteligo`, `pbac_z_ipko`, `bnp_paribas`, `credit_agricole`, `toyota_bank`, `bank_pekao_sa`, `volkswagen_bank`, `bank_millennium`, `alior_bank`, or `boz`.", + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "nullable": true, + "type": "string" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." + "reference": { + "description": "Unique reference for this Przelewy24 payment.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "verified_name": { + "description": "Owner's verified full name. Values are verified or provided by Przelewy24 directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.\nPrzelewy24 rarely provides this information so the attribute is usually empty.", + "maxLength": 5000, + "nullable": true, + "type": "string" } - } - } - }, - "/v1/account": { - "delete": { - "description": "

With Connect, you can delete Custom or Express accounts you manage.

\n\n

Accounts created using test-mode keys can be deleted at any time. Accounts created using live-mode keys can only be deleted once all balances are zero.

\n\n

If you want to delete your own account, use the account information tab in your account settings instead.

", - "operationId": "DeleteAccount", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": { - "account": { - "maxLength": 5000, - "type": "string" - } - }, - "type": "object" + }, + "title": "payment_method_details_p24", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_paynow": { + "description": "", + "properties": { + "reference": { + "description": "Reference number associated with this PayNow payment", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_paynow", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_paypal": { + "description": "", + "properties": { + "payer_email": { + "description": "Owner's email. Values are provided by PayPal directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "payer_id": { + "description": "PayPal account PayerID. This identifier uniquely identifies the PayPal customer.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "payer_name": { + "description": "Owner's full name. Values provided by PayPal directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "seller_protection": { + "anyOf": [ + { + "$ref": "#/components/schemas/paypal_seller_protection" } - } + ], + "description": "The level of protection offered as defined by PayPal Seller Protection for Merchants, for this transaction.", + "nullable": true }, - "required": false + "transaction_id": { + "description": "A unique ID generated by PayPal for this transaction.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/deleted_account" - } - } - }, - "description": "Successful response." + "title": "payment_method_details_paypal", + "type": "object", + "x-expandableFields": ["seller_protection"] + }, + "payment_method_details_pix": { + "description": "", + "properties": { + "bank_transaction_id": { + "description": "Unique transaction id generated by BCB", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_pix", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_promptpay": { + "description": "", + "properties": { + "reference": { + "description": "Bill reference generated by PromptPay", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_promptpay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_revolut_pay": { + "description": "", + "properties": {}, + "title": "payment_method_details_revolut_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_sepa_debit": { + "description": "", + "properties": { + "bank_code": { + "description": "Bank code of bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." + "branch_code": { + "description": "Branch code of bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "country": { + "description": "Two-letter ISO code representing the country the bank account is located in.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "Last four characters of the IBAN.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "mandate": { + "description": "Find the ID of the mandate used for this payment under the [payment_method_details.sepa_debit.mandate](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-sepa_debit-mandate) property on the Charge. Use this mandate ID to [retrieve the Mandate](https://stripe.com/docs/api/mandates/retrieve).", + "maxLength": 5000, + "nullable": true, + "type": "string" } - } + }, + "title": "payment_method_details_sepa_debit", + "type": "object", + "x-expandableFields": [] }, - "get": { - "description": "

Retrieves the details of an account.

", - "operationId": "GetAccount", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { + "payment_method_details_sofort": { + "description": "", + "properties": { + "bank_code": { + "description": "Bank code of bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "bank_name": { + "description": "Name of the bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "bic": { + "description": "Bank Identifier Code of the bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "country": { + "description": "Two-letter ISO code representing the country the bank account is located in.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "generated_sepa_debit": { + "anyOf": [ + { "maxLength": 5000, "type": "string" }, - "type": "array" - }, - "style": "deepObject" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" + { + "$ref": "#/components/schemas/payment_method" } + ], + "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] } }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/account" - } + "generated_sepa_debit_mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/mandate" } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" + ], + "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" } - } - }, - "description": "Error response." + ] + } + }, + "iban_last4": { + "description": "Last four characters of the IBAN.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "preferred_language": { + "description": "Preferred language of the SOFORT authorization page that the customer is redirected to.\nCan be one of `de`, `en`, `es`, `fr`, `it`, `nl`, or `pl`", + "enum": ["de", "en", "es", "fr", "it", "nl", "pl"], + "nullable": true, + "type": "string" + }, + "verified_name": { + "description": "Owner's verified full name. Values are verified or provided by SOFORT directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" } - } + }, + "title": "payment_method_details_sofort", + "type": "object", + "x-expandableFields": [ + "generated_sepa_debit", + "generated_sepa_debit_mandate" + ] }, - "post": { - "description": "

Updates a connected Express or Custom account by setting the values of the parameters passed. Any parameters not provided are left unchanged. Most parameters can be changed only for Custom accounts. (These are marked Custom Only below.) Parameters marked Custom and Express are supported by both account types.

\n\n

To update your own account, use the Dashboard. Refer to our Connect documentation to learn more about updating accounts.

", - "operationId": "PostAccount", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "bank_account": { - "explode": true, - "style": "deepObject" - }, - "business_profile": { - "explode": true, - "style": "deepObject" - }, - "capabilities": { - "explode": true, - "style": "deepObject" - }, - "company": { - "explode": true, - "style": "deepObject" - }, - "documents": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "individual": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "settings": { - "explode": true, - "style": "deepObject" - }, - "tos_acceptance": { - "explode": true, - "style": "deepObject" - } + "payment_method_details_stripe_account": { + "description": "", + "properties": {}, + "title": "payment_method_details_stripe_account", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_swish": { + "description": "", + "properties": { + "fingerprint": { + "description": "Uniquely identifies the payer's Swish account. You can use this attribute to check whether two Swish transactions were paid for by the same payer", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "payment_reference": { + "description": "Payer bank reference number for the payment", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "verified_phone_last4": { + "description": "The last four digits of the Swish account phone number", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_swish", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_twint": { + "description": "", + "properties": {}, + "title": "payment_method_details_twint", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_us_bank_account": { + "description": "", + "properties": { + "account_holder_type": { + "description": "Account holder type: individual or company.", + "enum": ["company", "individual"], + "nullable": true, + "type": "string" + }, + "account_type": { + "description": "Account type: checkings or savings. Defaults to checking if omitted.", + "enum": ["checking", "savings"], + "nullable": true, + "type": "string" + }, + "bank_name": { + "description": "Name of the bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" }, - "schema": { - "properties": { - "account_token": { - "description": "An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.", - "maxLength": 5000, - "type": "string" - }, - "bank_account": { - "anyOf": [ - { - "properties": { - "account_holder_name": { - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "type": "string" - }, - "object": { - "enum": ["bank_account"], - "maxLength": 5000, - "type": "string" - }, - "routing_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "country"], - "title": "external_account_payout_bank_account", - "type": "object" - }, - { - "maxLength": 5000, - "type": "string" - } - ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." - }, - "business_profile": { - "description": "Business information about the account.", - "properties": { - "mcc": { - "maxLength": 4, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "product_description": { - "maxLength": 40000, - "type": "string" - }, - "support_address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "support_email": { - "type": "string" - }, - "support_phone": { - "maxLength": 5000, - "type": "string" - }, - "support_url": { - "type": "string" - }, - "url": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "business_profile_specs", - "type": "object" - }, - "business_type": { - "description": "The business type.", - "enum": [ - "company", - "government_entity", - "individual", - "non_profit" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "capabilities": { - "description": "Each key of the dictionary represents a capability, and each capability maps to its settings (e.g. whether it has been requested or not). Each capability will be inactive until you have provided its specific requirements and Stripe has verified them. An account may have some of its requested capabilities be active and some be inactive.", - "properties": { - "afterpay_clearpay_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "au_becs_debit_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "bacs_debit_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "bancontact_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "card_issuing": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "card_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "cartes_bancaires_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "eps_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "fpx_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "giropay_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "grabpay_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "ideal_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "jcb_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "legacy_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "oxxo_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "p24_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "sepa_debit_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "sofort_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "tax_reporting_us_1099_k": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "tax_reporting_us_1099_misc": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "transfers": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - } - }, - "title": "capabilities_param", - "type": "object" - }, - "company": { - "description": "Information about the company or business. This field is available for any `business_type`.", - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kanji_specs", - "type": "object" - }, - "directors_provided": { - "type": "boolean" - }, - "executives_provided": { - "type": "boolean" - }, - "name": { - "maxLength": 100, - "type": "string" - }, - "name_kana": { - "maxLength": 100, - "type": "string" - }, - "name_kanji": { - "maxLength": 100, - "type": "string" - }, - "owners_provided": { - "type": "boolean" - }, - "phone": { - "maxLength": 5000, + { + "$ref": "#/components/schemas/mandate" + } + ], + "description": "ID of the mandate used to make this payment.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" + } + ] + } + }, + "payment_reference": { + "description": "Reference number to locate ACH payments with customer's bank.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "routing_number": { + "description": "Routing number of the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_us_bank_account", + "type": "object", + "x-expandableFields": ["mandate"] + }, + "payment_method_details_wechat": { + "description": "", + "properties": {}, + "title": "payment_method_details_wechat", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_wechat_pay": { + "description": "", + "properties": { + "fingerprint": { + "description": "Uniquely identifies this particular WeChat Pay account. You can use this attribute to check whether two WeChat accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "transaction_id": { + "description": "Transaction ID of this particular WeChat Pay transaction.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_details_wechat_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_details_zip": { + "description": "", + "properties": {}, + "title": "payment_method_details_zip", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_domain": { + "description": "A payment method domain represents a web domain that you have registered with Stripe.\nStripe Elements use registered payment method domains to control where certain payment methods are shown.\n\nRelated guide: [Payment method domains](https://stripe.com/docs/payments/payment-methods/pmd-registration).", + "properties": { + "apple_pay": { + "$ref": "#/components/schemas/payment_method_domain_resource_payment_method_status" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "domain_name": { + "description": "The domain name that this payment method domain object represents.", + "maxLength": 5000, + "type": "string" + }, + "enabled": { + "description": "Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements.", + "type": "boolean" + }, + "google_pay": { + "$ref": "#/components/schemas/payment_method_domain_resource_payment_method_status" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "link": { + "$ref": "#/components/schemas/payment_method_domain_resource_payment_method_status" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["payment_method_domain"], + "type": "string" + }, + "paypal": { + "$ref": "#/components/schemas/payment_method_domain_resource_payment_method_status" + } + }, + "required": [ + "apple_pay", + "created", + "domain_name", + "enabled", + "google_pay", + "id", + "link", + "livemode", + "object", + "paypal" + ], + "title": "PaymentMethodDomainResourcePaymentMethodDomain", + "type": "object", + "x-expandableFields": ["apple_pay", "google_pay", "link", "paypal"], + "x-resourceId": "payment_method_domain" + }, + "payment_method_domain_resource_payment_method_status": { + "description": "Indicates the status of a specific payment method on a payment method domain.", + "properties": { + "status": { + "description": "The status of the payment method on the domain.", + "enum": ["active", "inactive"], + "type": "string" + }, + "status_details": { + "$ref": "#/components/schemas/payment_method_domain_resource_payment_method_status_details" + } + }, + "required": ["status"], + "title": "PaymentMethodDomainResourcePaymentMethodStatus", + "type": "object", + "x-expandableFields": ["status_details"] + }, + "payment_method_domain_resource_payment_method_status_details": { + "description": "Contains additional details about the status of a payment method for a specific payment method domain.", + "properties": { + "error_message": { + "description": "The error message associated with the status of the payment method on the domain.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["error_message"], + "title": "PaymentMethodDomainResourcePaymentMethodStatusDetails", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_eps": { + "description": "", + "properties": { + "bank": { + "description": "The customer's bank. Should be one of `arzte_und_apotheker_bank`, `austrian_anadi_bank_ag`, `bank_austria`, `bankhaus_carl_spangler`, `bankhaus_schelhammer_und_schattera_ag`, `bawag_psk_ag`, `bks_bank_ag`, `brull_kallmus_bank_ag`, `btv_vier_lander_bank`, `capital_bank_grawe_gruppe_ag`, `deutsche_bank_ag`, `dolomitenbank`, `easybank_ag`, `erste_bank_und_sparkassen`, `hypo_alpeadriabank_international_ag`, `hypo_noe_lb_fur_niederosterreich_u_wien`, `hypo_oberosterreich_salzburg_steiermark`, `hypo_tirol_bank_ag`, `hypo_vorarlberg_bank_ag`, `hypo_bank_burgenland_aktiengesellschaft`, `marchfelder_bank`, `oberbank_ag`, `raiffeisen_bankengruppe_osterreich`, `schoellerbank_ag`, `sparda_bank_wien`, `volksbank_gruppe`, `volkskreditbank_ag`, or `vr_bank_braunau`.", + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_eps", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_fpx": { + "description": "", + "properties": { + "bank": { + "description": "The customer's bank, if provided. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, `pb_enterprise`, or `bank_of_china`.", + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], + "type": "string" + } + }, + "required": ["bank"], + "title": "payment_method_fpx", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_giropay": { + "description": "", + "properties": {}, + "title": "payment_method_giropay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_grabpay": { + "description": "", + "properties": {}, + "title": "payment_method_grabpay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_ideal": { + "description": "", + "properties": { + "bank": { + "description": "The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `n26`, `nn`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, `van_lanschot`, or `yoursafe`.", + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "nullable": true, + "type": "string" + }, + "bic": { + "description": "The Bank Identifier Code of the customer's bank, if the bank was provided.", + "enum": [ + "ABNANL2A", + "ASNBNL21", + "BITSNL2A", + "BUNQNL2A", + "FVLBNL22", + "HANDNL2A", + "INGBNL2A", + "KNABNL2H", + "MOYONL21", + "NNBANL2G", + "NTSBDEB1", + "RABONL2U", + "RBRBNL21", + "REVOIE23", + "REVOLT21", + "SNSBNL2A", + "TRIONL2U" + ], + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_ideal", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_interac_present": { + "description": "", + "properties": { + "brand": { + "description": "Card brand. Can be `interac`, `mastercard` or `visa`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "cardholder_name": { + "description": "The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "country": { + "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "description": { + "description": "A high-level description of the type of cards issued in this range.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "exp_month": { + "description": "Two-digit number representing the card's expiration month.", + "type": "integer" + }, + "exp_year": { + "description": "Four-digit number representing the card's expiration year.", + "type": "integer" + }, + "fingerprint": { + "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.\n\n*As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "funding": { + "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "issuer": { + "description": "The name of the card's issuing bank.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "The last four digits of the card.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "networks": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_card_present_networks" + } + ], + "description": "Contains information about card networks that can be used to process the payment.", + "nullable": true + }, + "preferred_locales": { + "description": "EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "read_method": { + "description": "How card details were read in this transaction.", + "enum": [ + "contact_emv", + "contactless_emv", + "contactless_magstripe_mode", + "magnetic_stripe_fallback", + "magnetic_stripe_track2" + ], + "nullable": true, + "type": "string" + } + }, + "required": ["exp_month", "exp_year"], + "title": "payment_method_interac_present", + "type": "object", + "x-expandableFields": ["networks"] + }, + "payment_method_klarna": { + "description": "", + "properties": { + "dob": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_flows_private_payment_methods_klarna_dob" + } + ], + "description": "The customer's date of birth, if provided.", + "nullable": true + } + }, + "title": "payment_method_klarna", + "type": "object", + "x-expandableFields": ["dob"] + }, + "payment_method_konbini": { + "description": "", + "properties": {}, + "title": "payment_method_konbini", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_link": { + "description": "", + "properties": { + "email": { + "description": "Account owner's email address.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_link", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_mobilepay": { + "description": "", + "properties": {}, + "title": "payment_method_mobilepay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_multibanco": { + "description": "", + "properties": {}, + "title": "payment_method_multibanco", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_affirm": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], + "type": "string" + }, + "preferred_locale": { + "description": "Preferred language of the Affirm authorization page that the customer is redirected to.", + "maxLength": 30, + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_affirm", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_afterpay_clearpay": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], + "type": "string" + }, + "reference": { + "description": "An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.\nThis field differs from the statement descriptor and item name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_afterpay_clearpay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_alipay": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_alipay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_amazon_pay": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_amazon_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_bancontact": { + "description": "", + "properties": { + "preferred_language": { + "description": "Preferred language of the Bancontact authorization page that the customer is redirected to.", + "enum": ["de", "en", "fr", "nl"], + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], + "type": "string" + } + }, + "required": ["preferred_language"], + "title": "payment_method_options_bancontact", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_boleto": { + "description": "", + "properties": { + "expires_after_days": { + "description": "The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto voucher will expire on Wednesday at 23:59 America/Sao_Paulo time.", + "type": "integer" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], + "type": "string" + } + }, + "required": ["expires_after_days"], + "title": "payment_method_options_boleto", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_card_installments": { + "description": "", + "properties": { + "available_plans": { + "description": "Installment plans that may be selected for this PaymentIntent.", + "items": { + "$ref": "#/components/schemas/payment_method_details_card_installments_plan" + }, + "nullable": true, + "type": "array" + }, + "enabled": { + "description": "Whether Installments are enabled for this PaymentIntent.", + "type": "boolean" + }, + "plan": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_details_card_installments_plan" + } + ], + "description": "Installment plan selected for this PaymentIntent.", + "nullable": true + } + }, + "required": ["enabled"], + "title": "payment_method_options_card_installments", + "type": "object", + "x-expandableFields": ["available_plans", "plan"] + }, + "payment_method_options_card_mandate_options": { + "description": "", + "properties": { + "amount": { + "description": "Amount to be charged for future payments.", + "type": "integer" + }, + "amount_type": { + "description": "One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.", + "enum": ["fixed", "maximum"], + "type": "string" + }, + "description": { + "description": "A description of the mandate or subscription that is meant to be displayed to the customer.", + "maxLength": 200, + "nullable": true, + "type": "string" + }, + "end_date": { + "description": "End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "interval": { + "description": "Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.", + "enum": ["day", "month", "sporadic", "week", "year"], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.", + "nullable": true, + "type": "integer" + }, + "reference": { + "description": "Unique identifier for the mandate or subscription.", + "maxLength": 80, + "type": "string" + }, + "start_date": { + "description": "Start date of the mandate or subscription. Start date should not be lesser than yesterday.", + "format": "unix-time", + "type": "integer" + }, + "supported_types": { + "description": "Specifies the type of mandates supported. Possible values are `india`.", + "items": { + "enum": ["india"], + "type": "string" + }, + "nullable": true, + "type": "array" + } + }, + "required": [ + "amount", + "amount_type", + "interval", + "reference", + "start_date" + ], + "title": "payment_method_options_card_mandate_options", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_card_present": { + "description": "", + "properties": { + "request_extended_authorization": { + "description": "Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)", + "nullable": true, + "type": "boolean" + }, + "request_incremental_authorization_support": { + "description": "Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.", + "nullable": true, + "type": "boolean" + }, + "routing": { + "$ref": "#/components/schemas/payment_method_options_card_present_routing" + } + }, + "title": "payment_method_options_card_present", + "type": "object", + "x-expandableFields": ["routing"] + }, + "payment_method_options_card_present_routing": { + "description": "", + "properties": { + "requested_priority": { + "description": "Requested routing priority", + "enum": ["domestic", "international"], + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_options_card_present_routing", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_cashapp": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session", "on_session"], + "type": "string" + } + }, + "title": "payment_method_options_cashapp", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_customer_balance": { + "description": "", + "properties": { + "bank_transfer": { + "$ref": "#/components/schemas/payment_method_options_customer_balance_bank_transfer" + }, + "funding_type": { + "description": "The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.", + "enum": ["bank_transfer"], + "nullable": true, + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_customer_balance", + "type": "object", + "x-expandableFields": ["bank_transfer"] + }, + "payment_method_options_customer_balance_bank_transfer": { + "description": "", + "properties": { + "eu_bank_transfer": { + "$ref": "#/components/schemas/payment_method_options_customer_balance_eu_bank_account" + }, + "requested_address_types": { + "description": "List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.\n\nPermitted values include: `sort_code`, `zengin`, `iban`, or `spei`.", + "items": { + "enum": [ + "aba", + "iban", + "sepa", + "sort_code", + "spei", + "swift", + "zengin" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "type": { + "description": "The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.", + "enum": [ + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "mx_bank_transfer", + "us_bank_transfer" + ], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_customer_balance_bank_transfer", + "type": "object", + "x-expandableFields": ["eu_bank_transfer"] + }, + "payment_method_options_customer_balance_eu_bank_account": { + "description": "", + "properties": { + "country": { + "description": "The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.", + "enum": ["BE", "DE", "ES", "FR", "IE", "NL"], + "type": "string" + } + }, + "required": ["country"], + "title": "payment_method_options_customer_balance_eu_bank_account", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_fpx": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_fpx", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_giropay": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_giropay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_grabpay": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_grabpay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_ideal": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_ideal", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_interac_present": { + "description": "", + "properties": {}, + "title": "payment_method_options_interac_present", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_klarna": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], + "type": "string" + }, + "preferred_locale": { + "description": "Preferred locale of the Klarna checkout page that the customer is redirected to.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_klarna", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_konbini": { + "description": "", + "properties": { + "confirmation_number": { + "description": "An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "expires_after_days": { + "description": "The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST.", + "nullable": true, + "type": "integer" + }, + "expires_at": { + "description": "The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "product_description": { + "description": "A product descriptor of up to 22 characters, which will appear to customers at the convenience store.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_konbini", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_multibanco": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_multibanco", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_oxxo": { + "description": "", + "properties": { + "expires_after_days": { + "description": "The number of calendar days before an OXXO invoice expires. For example, if you create an OXXO invoice on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.", + "type": "integer" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "required": ["expires_after_days"], + "title": "payment_method_options_oxxo", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_p24": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_p24", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_paynow": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_paynow", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_paypal": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], + "type": "string" + }, + "preferred_locale": { + "description": "Preferred locale of the PayPal checkout page that the customer is redirected to.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "reference": { + "description": "A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_paypal", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_pix": { + "description": "", + "properties": { + "expires_after_seconds": { + "description": "The number of seconds (between 10 and 1209600) after which Pix payment will expire.", + "nullable": true, + "type": "integer" + }, + "expires_at": { + "description": "The timestamp at which the Pix expires.", + "nullable": true, + "type": "integer" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_pix", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_promptpay": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_promptpay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_revolut_pay": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["manual"], + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_revolut_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_sofort": { + "description": "", + "properties": { + "preferred_language": { + "description": "Preferred language of the SOFORT authorization page that the customer is redirected to.", + "enum": ["de", "en", "es", "fr", "it", "nl", "pl"], + "nullable": true, + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_sofort", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_twint": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_twint", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_us_bank_account_mandate_options": { + "description": "", + "properties": { + "collection_method": { + "description": "Mandate collection method", + "enum": ["paper"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_us_bank_account_mandate_options", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_wechat_pay": { + "description": "", + "properties": { + "app_id": { + "description": "The app ID registered with WeChat Pay. Only required when client is ios or android.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "client": { + "description": "The client type that the end customer will pay from", + "enum": ["android", "ios", "web"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_wechat_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_options_zip": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_zip", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_oxxo": { + "description": "", + "properties": {}, + "title": "payment_method_oxxo", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_p24": { + "description": "", + "properties": { + "bank": { + "description": "The customer's bank, if provided.", + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_p24", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_paynow": { + "description": "", + "properties": {}, + "title": "payment_method_paynow", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_paypal": { + "description": "", + "properties": { + "payer_email": { + "description": "Owner's email. Values are provided by PayPal directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "payer_id": { + "description": "PayPal account PayerID. This identifier uniquely identifies the PayPal customer.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_paypal", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_pix": { + "description": "", + "properties": {}, + "title": "payment_method_pix", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_promptpay": { + "description": "", + "properties": {}, + "title": "payment_method_promptpay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_revolut_pay": { + "description": "", + "properties": {}, + "title": "payment_method_revolut_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_sepa_debit": { + "description": "", + "properties": { + "bank_code": { + "description": "Bank code of bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "branch_code": { + "description": "Branch code of bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "country": { + "description": "Two-letter ISO code representing the country the bank account is located in.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "generated_from": { + "anyOf": [ + { + "$ref": "#/components/schemas/sepa_debit_generated_from" + } + ], + "description": "Information about the object that generated this PaymentMethod.", + "nullable": true + }, + "last4": { + "description": "Last four characters of the IBAN.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_sepa_debit", + "type": "object", + "x-expandableFields": ["generated_from"] + }, + "payment_method_sofort": { + "description": "", + "properties": { + "country": { + "description": "Two-letter ISO code representing the country the bank account is located in.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_sofort", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_swish": { + "description": "", + "properties": {}, + "title": "payment_method_swish", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_twint": { + "description": "", + "properties": {}, + "title": "payment_method_twint", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_us_bank_account": { + "description": "", + "properties": { + "account_holder_type": { + "description": "Account holder type: individual or company.", + "enum": ["company", "individual"], + "nullable": true, + "type": "string" + }, + "account_type": { + "description": "Account type: checkings or savings. Defaults to checking if omitted.", + "enum": ["checking", "savings"], + "nullable": true, + "type": "string" + }, + "bank_name": { + "description": "The name of the bank.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "financial_connections_account": { + "description": "The ID of the Financial Connections Account used to create the payment method.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "fingerprint": { + "description": "Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "Last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "networks": { + "anyOf": [ + { + "$ref": "#/components/schemas/us_bank_account_networks" + } + ], + "description": "Contains information about US bank account networks that can be used.", + "nullable": true + }, + "routing_number": { + "description": "Routing number of the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "status_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_us_bank_account_status_details" + } + ], + "description": "Contains information about the future reusability of this PaymentMethod.", + "nullable": true + } + }, + "title": "payment_method_us_bank_account", + "type": "object", + "x-expandableFields": ["networks", "status_details"] + }, + "payment_method_us_bank_account_blocked": { + "description": "", + "properties": { + "network_code": { + "description": "The ACH network code that resulted in this block.", + "enum": [ + "R02", + "R03", + "R04", + "R05", + "R07", + "R08", + "R10", + "R11", + "R16", + "R20", + "R29", + "R31" + ], + "nullable": true, + "type": "string" + }, + "reason": { + "description": "The reason why this PaymentMethod's fingerprint has been blocked", + "enum": [ + "bank_account_closed", + "bank_account_frozen", + "bank_account_invalid_details", + "bank_account_restricted", + "bank_account_unusable", + "debit_not_authorized" + ], + "nullable": true, + "type": "string" + } + }, + "title": "payment_method_us_bank_account_blocked", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_us_bank_account_status_details": { + "description": "", + "properties": { + "blocked": { + "$ref": "#/components/schemas/payment_method_us_bank_account_blocked" + } + }, + "title": "payment_method_us_bank_account_status_details", + "type": "object", + "x-expandableFields": ["blocked"] + }, + "payment_method_wechat_pay": { + "description": "", + "properties": {}, + "title": "payment_method_wechat_pay", + "type": "object", + "x-expandableFields": [] + }, + "payment_method_zip": { + "description": "", + "properties": {}, + "title": "payment_method_zip", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_after_expiration": { + "description": "", + "properties": { + "recovery": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_after_expiration_recovery" + } + ], + "description": "When set, configuration used to recover the Checkout Session on expiry.", + "nullable": true + } + }, + "title": "PaymentPagesCheckoutSessionAfterExpiration", + "type": "object", + "x-expandableFields": ["recovery"] + }, + "payment_pages_checkout_session_after_expiration_recovery": { + "description": "", + "properties": { + "allow_promotion_codes": { + "description": "Enables user redeemable promotion codes on the recovered Checkout Sessions. Defaults to `false`", + "type": "boolean" + }, + "enabled": { + "description": "If `true`, a recovery url will be generated to recover this Checkout Session if it\nexpires before a transaction is completed. It will be attached to the\nCheckout Session object upon expiration.", + "type": "boolean" + }, + "expires_at": { + "description": "The timestamp at which the recovery URL will expire.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "url": { + "description": "URL that creates a new Checkout Session when clicked that is a copy of this expired Checkout Session", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["allow_promotion_codes", "enabled"], + "title": "PaymentPagesCheckoutSessionAfterExpirationRecovery", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_automatic_tax": { + "description": "", + "properties": { + "enabled": { + "description": "Indicates whether automatic tax is enabled for the session", + "type": "boolean" + }, + "liability": { + "anyOf": [ + { + "$ref": "#/components/schemas/connect_account_reference" + } + ], + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "nullable": true + }, + "status": { + "description": "The status of the most recent automated tax calculation for this session.", + "enum": ["complete", "failed", "requires_location_inputs"], + "nullable": true, + "type": "string" + } + }, + "required": ["enabled"], + "title": "PaymentPagesCheckoutSessionAutomaticTax", + "type": "object", + "x-expandableFields": ["liability"] + }, + "payment_pages_checkout_session_consent": { + "description": "", + "properties": { + "promotions": { + "description": "If `opt_in`, the customer consents to receiving promotional communications\nfrom the merchant about this Checkout Session.", + "enum": ["opt_in", "opt_out"], + "nullable": true, + "type": "string" + }, + "terms_of_service": { + "description": "If `accepted`, the customer in this Checkout Session has agreed to the merchant's terms of service.", + "enum": ["accepted"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "PaymentPagesCheckoutSessionConsent", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_consent_collection": { + "description": "", + "properties": { + "payment_method_reuse_agreement": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_payment_method_reuse_agreement" + } + ], + "description": "If set to `hidden`, it will hide legal text related to the reuse of a payment method.", + "nullable": true + }, + "promotions": { + "description": "If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout\nSession will determine whether to display an option to opt into promotional communication\nfrom the merchant depending on the customer's locale. Only available to US merchants.", + "enum": ["auto", "none"], + "nullable": true, + "type": "string" + }, + "terms_of_service": { + "description": "If set to `required`, it requires customers to accept the terms of service before being able to pay.", + "enum": ["none", "required"], + "nullable": true, + "type": "string" + } + }, + "title": "PaymentPagesCheckoutSessionConsentCollection", + "type": "object", + "x-expandableFields": ["payment_method_reuse_agreement"] + }, + "payment_pages_checkout_session_currency_conversion": { + "description": "", + "properties": { + "amount_subtotal": { + "description": "Total of all items in source currency before discounts or taxes are applied.", + "type": "integer" + }, + "amount_total": { + "description": "Total of all items in source currency after discounts and taxes are applied.", + "type": "integer" + }, + "fx_rate": { + "description": "Exchange rate used to convert source currency amounts to customer currency amounts", + "format": "decimal", + "type": "string" + }, + "source_currency": { + "description": "Creation currency of the CheckoutSession before localization", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "amount_subtotal", + "amount_total", + "fx_rate", + "source_currency" + ], + "title": "PaymentPagesCheckoutSessionCurrencyConversion", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_custom_fields": { + "description": "", + "properties": { + "dropdown": { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_fields_dropdown" + }, + "key": { + "description": "String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.", + "maxLength": 5000, + "type": "string" + }, + "label": { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_fields_label" + }, + "numeric": { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_fields_numeric" + }, + "optional": { + "description": "Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.", + "type": "boolean" + }, + "text": { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_fields_text" + }, + "type": { + "description": "The type of the field.", + "enum": ["dropdown", "numeric", "text"], + "type": "string" + } + }, + "required": ["key", "label", "optional", "type"], + "title": "PaymentPagesCheckoutSessionCustomFields", + "type": "object", + "x-expandableFields": ["dropdown", "label", "numeric", "text"] + }, + "payment_pages_checkout_session_custom_fields_dropdown": { + "description": "", + "properties": { + "default_value": { + "description": "The value that will pre-fill on the payment page.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "options": { + "description": "The options available for the customer to select. Up to 200 options allowed.", + "items": { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_fields_option" + }, + "type": "array" + }, + "value": { + "description": "The option selected by the customer. This will be the `value` for the option.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["options"], + "title": "PaymentPagesCheckoutSessionCustomFieldsDropdown", + "type": "object", + "x-expandableFields": ["options"] + }, + "payment_pages_checkout_session_custom_fields_label": { + "description": "", + "properties": { + "custom": { + "description": "Custom text for the label, displayed to the customer. Up to 50 characters.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "type": { + "description": "The type of the label.", + "enum": ["custom"], + "type": "string" + } + }, + "required": ["type"], + "title": "PaymentPagesCheckoutSessionCustomFieldsLabel", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_custom_fields_numeric": { + "description": "", + "properties": { + "default_value": { + "description": "The value that will pre-fill the field on the payment page.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "maximum_length": { + "description": "The maximum character length constraint for the customer's input.", + "nullable": true, + "type": "integer" + }, + "minimum_length": { + "description": "The minimum character length requirement for the customer's input.", + "nullable": true, + "type": "integer" + }, + "value": { + "description": "The value entered by the customer, containing only digits.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "PaymentPagesCheckoutSessionCustomFieldsNumeric", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_custom_fields_option": { + "description": "", + "properties": { + "label": { + "description": "The label for the option, displayed to the customer. Up to 100 characters.", + "maxLength": 5000, + "type": "string" + }, + "value": { + "description": "The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["label", "value"], + "title": "PaymentPagesCheckoutSessionCustomFieldsOption", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_custom_fields_text": { + "description": "", + "properties": { + "default_value": { + "description": "The value that will pre-fill the field on the payment page.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "maximum_length": { + "description": "The maximum character length constraint for the customer's input.", + "nullable": true, + "type": "integer" + }, + "minimum_length": { + "description": "The minimum character length requirement for the customer's input.", + "nullable": true, + "type": "integer" + }, + "value": { + "description": "The value entered by the customer.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "PaymentPagesCheckoutSessionCustomFieldsText", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_custom_text": { + "description": "", + "properties": { + "after_submit": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_text_position" + } + ], + "description": "Custom text that should be displayed after the payment confirmation button.", + "nullable": true + }, + "shipping_address": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_text_position" + } + ], + "description": "Custom text that should be displayed alongside shipping address collection.", + "nullable": true + }, + "submit": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_text_position" + } + ], + "description": "Custom text that should be displayed alongside the payment confirmation button.", + "nullable": true + }, + "terms_of_service_acceptance": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_custom_text_position" + } + ], + "description": "Custom text that should be displayed in place of the default terms of service agreement text.", + "nullable": true + } + }, + "title": "PaymentPagesCheckoutSessionCustomText", + "type": "object", + "x-expandableFields": [ + "after_submit", + "shipping_address", + "submit", + "terms_of_service_acceptance" + ] + }, + "payment_pages_checkout_session_custom_text_position": { + "description": "", + "properties": { + "message": { + "description": "Text may be up to 1200 characters in length.", + "maxLength": 500, + "type": "string" + } + }, + "required": ["message"], + "title": "PaymentPagesCheckoutSessionCustomTextPosition", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_customer_details": { + "description": "", + "properties": { + "address": { + "anyOf": [ + { + "$ref": "#/components/schemas/address" + } + ], + "description": "The customer's address after a completed Checkout Session. Note: This property is populated only for sessions on or after March 30, 2022.", + "nullable": true + }, + "email": { + "description": "The email associated with the Customer, if one exists, on the Checkout Session after a completed Checkout Session or at time of session expiry.\nOtherwise, if the customer has consented to promotional content, this value is the most recent valid email provided by the customer on the Checkout form.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "name": { + "description": "The customer's name after a completed Checkout Session. Note: This property is populated only for sessions on or after March 30, 2022.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "phone": { + "description": "The customer's phone number after a completed Checkout Session.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "tax_exempt": { + "description": "The customer’s tax exempt status after a completed Checkout Session.", + "enum": ["exempt", "none", "reverse"], + "nullable": true, + "type": "string" + }, + "tax_ids": { + "description": "The customer’s tax IDs after a completed Checkout Session.", + "items": { + "$ref": "#/components/schemas/payment_pages_checkout_session_tax_id" + }, + "nullable": true, + "type": "array" + } + }, + "title": "PaymentPagesCheckoutSessionCustomerDetails", + "type": "object", + "x-expandableFields": ["address", "tax_ids"] + }, + "payment_pages_checkout_session_invoice_creation": { + "description": "", + "properties": { + "enabled": { + "description": "Indicates whether invoice creation is enabled for the Checkout Session.", + "type": "boolean" + }, + "invoice_data": { + "$ref": "#/components/schemas/payment_pages_checkout_session_invoice_settings" + } + }, + "required": ["enabled", "invoice_data"], + "title": "PaymentPagesCheckoutSessionInvoiceCreation", + "type": "object", + "x-expandableFields": ["invoice_data"] + }, + "payment_pages_checkout_session_invoice_settings": { + "description": "", + "properties": { + "account_tax_ids": { + "description": "The account tax IDs associated with the invoice.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ] + } + }, + "nullable": true, + "type": "array" + }, + "custom_fields": { + "description": "Custom fields displayed on the invoice.", + "items": { + "$ref": "#/components/schemas/invoice_setting_custom_field" + }, + "nullable": true, + "type": "array" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "footer": { + "description": "Footer displayed on the invoice.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "issuer": { + "anyOf": [ + { + "$ref": "#/components/schemas/connect_account_reference" + } + ], + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", + "nullable": true + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "rendering_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_setting_rendering_options" + } + ], + "description": "Options for invoice PDF rendering.", + "nullable": true + } + }, + "title": "PaymentPagesCheckoutSessionInvoiceSettings", + "type": "object", + "x-expandableFields": [ + "account_tax_ids", + "custom_fields", + "issuer", + "rendering_options" + ] + }, + "payment_pages_checkout_session_payment_method_reuse_agreement": { + "description": "", + "properties": { + "position": { + "description": "Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's defaults will be used.\n\nWhen set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.", + "enum": ["auto", "hidden"], + "type": "string" + } + }, + "required": ["position"], + "title": "PaymentPagesCheckoutSessionPaymentMethodReuseAgreement", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_phone_number_collection": { + "description": "", + "properties": { + "enabled": { + "description": "Indicates whether phone number collection is enabled for the session", + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "PaymentPagesCheckoutSessionPhoneNumberCollection", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_saved_payment_method_options": { + "description": "", + "properties": { + "allow_redisplay_filters": { + "description": "Uses the `allow_redisplay` value of each saved payment method to filter the set presented to a returning customer. By default, only saved payment methods with ’allow_redisplay: ‘always’ are shown in Checkout.", + "items": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "payment_method_remove": { + "description": "Enable customers to choose if they wish to remove their saved payment methods. Disabled by default.", + "enum": ["disabled", "enabled"], + "nullable": true, + "type": "string" + }, + "payment_method_save": { + "description": "Enable customers to choose if they wish to save their payment method for future use. Disabled by default.", + "enum": ["disabled", "enabled"], + "nullable": true, + "type": "string" + } + }, + "title": "PaymentPagesCheckoutSessionSavedPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_shipping_address_collection": { + "description": "", + "properties": { + "allowed_countries": { + "description": "An array of two-letter ISO country codes representing which countries Checkout should provide as options for\nshipping locations. Unsupported country codes: `AS, CX, CC, CU, HM, IR, KP, MH, FM, NF, MP, PW, SD, SY, UM, VI`.", + "items": { + "enum": [ + "AC", + "AD", + "AE", + "AF", + "AG", + "AI", + "AL", + "AM", + "AO", + "AQ", + "AR", + "AT", + "AU", + "AW", + "AX", + "AZ", + "BA", + "BB", + "BD", + "BE", + "BF", + "BG", + "BH", + "BI", + "BJ", + "BL", + "BM", + "BN", + "BO", + "BQ", + "BR", + "BS", + "BT", + "BV", + "BW", + "BY", + "BZ", + "CA", + "CD", + "CF", + "CG", + "CH", + "CI", + "CK", + "CL", + "CM", + "CN", + "CO", + "CR", + "CV", + "CW", + "CY", + "CZ", + "DE", + "DJ", + "DK", + "DM", + "DO", + "DZ", + "EC", + "EE", + "EG", + "EH", + "ER", + "ES", + "ET", + "FI", + "FJ", + "FK", + "FO", + "FR", + "GA", + "GB", + "GD", + "GE", + "GF", + "GG", + "GH", + "GI", + "GL", + "GM", + "GN", + "GP", + "GQ", + "GR", + "GS", + "GT", + "GU", + "GW", + "GY", + "HK", + "HN", + "HR", + "HT", + "HU", + "ID", + "IE", + "IL", + "IM", + "IN", + "IO", + "IQ", + "IS", + "IT", + "JE", + "JM", + "JO", + "JP", + "KE", + "KG", + "KH", + "KI", + "KM", + "KN", + "KR", + "KW", + "KY", + "KZ", + "LA", + "LB", + "LC", + "LI", + "LK", + "LR", + "LS", + "LT", + "LU", + "LV", + "LY", + "MA", + "MC", + "MD", + "ME", + "MF", + "MG", + "MK", + "ML", + "MM", + "MN", + "MO", + "MQ", + "MR", + "MS", + "MT", + "MU", + "MV", + "MW", + "MX", + "MY", + "MZ", + "NA", + "NC", + "NE", + "NG", + "NI", + "NL", + "NO", + "NP", + "NR", + "NU", + "NZ", + "OM", + "PA", + "PE", + "PF", + "PG", + "PH", + "PK", + "PL", + "PM", + "PN", + "PR", + "PS", + "PT", + "PY", + "QA", + "RE", + "RO", + "RS", + "RU", + "RW", + "SA", + "SB", + "SC", + "SE", + "SG", + "SH", + "SI", + "SJ", + "SK", + "SL", + "SM", + "SN", + "SO", + "SR", + "SS", + "ST", + "SV", + "SX", + "SZ", + "TA", + "TC", + "TD", + "TF", + "TG", + "TH", + "TJ", + "TK", + "TL", + "TM", + "TN", + "TO", + "TR", + "TT", + "TV", + "TW", + "TZ", + "UA", + "UG", + "US", + "UY", + "UZ", + "VA", + "VC", + "VE", + "VG", + "VN", + "VU", + "WF", + "WS", + "XK", + "YE", + "YT", + "ZA", + "ZM", + "ZW", + "ZZ" + ], + "type": "string" + }, + "type": "array" + } + }, + "required": ["allowed_countries"], + "title": "PaymentPagesCheckoutSessionShippingAddressCollection", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_shipping_cost": { + "description": "", + "properties": { + "amount_subtotal": { + "description": "Total shipping cost before any discounts or taxes are applied.", + "type": "integer" + }, + "amount_tax": { + "description": "Total tax amount applied due to shipping costs. If no tax was applied, defaults to 0.", + "type": "integer" + }, + "amount_total": { + "description": "Total shipping cost after discounts and taxes are applied.", + "type": "integer" + }, + "shipping_rate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/shipping_rate" + } + ], + "description": "The ID of the ShippingRate for this order.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/shipping_rate" + } + ] + } + }, + "taxes": { + "description": "The taxes applied to the shipping rate.", + "items": { + "$ref": "#/components/schemas/line_items_tax_amount" + }, + "type": "array" + } + }, + "required": ["amount_subtotal", "amount_tax", "amount_total"], + "title": "PaymentPagesCheckoutSessionShippingCost", + "type": "object", + "x-expandableFields": ["shipping_rate", "taxes"] + }, + "payment_pages_checkout_session_shipping_option": { + "description": "", + "properties": { + "shipping_amount": { + "description": "A non-negative integer in cents representing how much to charge.", + "type": "integer" + }, + "shipping_rate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/shipping_rate" + } + ], + "description": "The shipping rate.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/shipping_rate" + } + ] + } + } + }, + "required": ["shipping_amount", "shipping_rate"], + "title": "PaymentPagesCheckoutSessionShippingOption", + "type": "object", + "x-expandableFields": ["shipping_rate"] + }, + "payment_pages_checkout_session_tax_id": { + "description": "", + "properties": { + "type": { + "description": "The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, or `unknown`", + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "unknown", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "type": "string" + }, + "value": { + "description": "The value of the tax ID.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["type"], + "title": "PaymentPagesCheckoutSessionTaxID", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_tax_id_collection": { + "description": "", + "properties": { + "enabled": { + "description": "Indicates whether tax ID collection is enabled for the session", + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "PaymentPagesCheckoutSessionTaxIDCollection", + "type": "object", + "x-expandableFields": [] + }, + "payment_pages_checkout_session_total_details": { + "description": "", + "properties": { + "amount_discount": { + "description": "This is the sum of all the discounts.", + "type": "integer" + }, + "amount_shipping": { + "description": "This is the sum of all the shipping amounts.", + "nullable": true, + "type": "integer" + }, + "amount_tax": { + "description": "This is the sum of all the tax amounts.", + "type": "integer" + }, + "breakdown": { + "$ref": "#/components/schemas/payment_pages_checkout_session_total_details_resource_breakdown" + } + }, + "required": ["amount_discount", "amount_tax"], + "title": "PaymentPagesCheckoutSessionTotalDetails", + "type": "object", + "x-expandableFields": ["breakdown"] + }, + "payment_pages_checkout_session_total_details_resource_breakdown": { + "description": "", + "properties": { + "discounts": { + "description": "The aggregated discounts.", + "items": { + "$ref": "#/components/schemas/line_items_discount_amount" + }, + "type": "array" + }, + "taxes": { + "description": "The aggregated tax amounts by rate.", + "items": { + "$ref": "#/components/schemas/line_items_tax_amount" + }, + "type": "array" + } + }, + "required": ["discounts", "taxes"], + "title": "PaymentPagesCheckoutSessionTotalDetailsResourceBreakdown", + "type": "object", + "x-expandableFields": ["discounts", "taxes"] + }, + "payment_source": { + "anyOf": [ + { + "$ref": "#/components/schemas/account" + }, + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/source" + } + ], + "title": "Polymorphic", + "x-resourceId": "payment_source", + "x-stripeBypassValidation": true + }, + "payout": { + "description": "A `Payout` object is created when you receive funds from Stripe, or when you\ninitiate a payout to either a bank account or debit card of a [connected\nStripe account](/docs/connect/bank-debit-card-payouts). You can retrieve individual payouts,\nand list all payouts. Payouts are made on [varying\nschedules](/docs/connect/manage-payout-schedule), depending on your country and\nindustry.\n\nRelated guide: [Receiving payouts](https://stripe.com/docs/payouts)", + "properties": { + "amount": { + "description": "The amount (in cents (or local equivalent)) that transfers to your bank account or debit card.", + "type": "integer" + }, + "application_fee": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application_fee" + } + ], + "description": "The application fee (if any) for the payout. [See the Connect documentation](https://stripe.com/docs/connect/instant-payouts#monetization-and-fees) for details.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application_fee" + } + ] + } + }, + "application_fee_amount": { + "description": "The amount of the application fee (if any) requested for the payout. [See the Connect documentation](https://stripe.com/docs/connect/instant-payouts#monetization-and-fees) for details.", + "nullable": true, + "type": "integer" + }, + "arrival_date": { + "description": "Date that you can expect the payout to arrive in the bank. This factors in delays to account for weekends or bank holidays.", + "format": "unix-time", + "type": "integer" + }, + "automatic": { + "description": "Returns `true` if the payout is created by an [automated payout schedule](https://stripe.com/docs/payouts#payout-schedule) and `false` if it's [requested manually](https://stripe.com/docs/payouts#manual-payouts).", + "type": "boolean" + }, + "balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "ID of the balance transaction that describes the impact of this payout on your account balance.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "destination": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/deleted_bank_account" + }, + { + "$ref": "#/components/schemas/deleted_card" + } + ], + "description": "ID of the bank account or card the payout is sent to.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/deleted_bank_account" + }, + { + "$ref": "#/components/schemas/deleted_card" + } + ] + }, + "x-stripeBypassValidation": true + }, + "failure_balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "If the payout fails or cancels, this is the ID of the balance transaction that reverses the initial balance transaction and returns the funds from the failed payout back in your balance.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } + }, + "failure_code": { + "description": "Error code that provides a reason for a payout failure, if available. View our [list of failure codes](https://stripe.com/docs/api#payout_failures).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "failure_message": { + "description": "Message that provides the reason for a payout failure, if available.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "method": { + "description": "The method used to send this payout, which can be `standard` or `instant`. `instant` is supported for payouts to debit cards and bank accounts in certain countries. Learn more about [bank support for Instant Payouts](https://stripe.com/docs/payouts/instant-payouts-banks).", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["payout"], + "type": "string" + }, + "original_payout": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payout" + } + ], + "description": "If the payout reverses another, this is the ID of the original payout.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payout" + } + ] + } + }, + "reconciliation_status": { + "description": "If `completed`, you can use the [Balance Transactions API](https://stripe.com/docs/api/balance_transactions/list#balance_transaction_list-payout) to list all balance transactions that are paid out in this payout.", + "enum": ["completed", "in_progress", "not_applicable"], + "type": "string" + }, + "reversed_by": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payout" + } + ], + "description": "If the payout reverses, this is the ID of the payout that reverses this payout.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payout" + } + ] + } + }, + "source_type": { + "description": "The source balance this payout came from, which can be one of the following: `card`, `fpx`, or `bank_account`.", + "maxLength": 5000, + "type": "string" + }, + "statement_descriptor": { + "description": "Extra information about a payout that displays on the user's bank statement.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "status": { + "description": "Current status of the payout: `paid`, `pending`, `in_transit`, `canceled` or `failed`. A payout is `pending` until it's submitted to the bank, when it becomes `in_transit`. The status changes to `paid` if the transaction succeeds, or to `failed` or `canceled` (within 5 business days). Some payouts that fail might initially show as `paid`, then change to `failed`.", + "maxLength": 5000, + "type": "string" + }, + "type": { + "description": "Can be `bank_account` or `card`.", + "enum": ["bank_account", "card"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "amount", + "arrival_date", + "automatic", + "created", + "currency", + "id", + "livemode", + "method", + "object", + "reconciliation_status", + "source_type", + "status", + "type" + ], + "title": "Payout", + "type": "object", + "x-expandableFields": [ + "application_fee", + "balance_transaction", + "destination", + "failure_balance_transaction", + "original_payout", + "reversed_by" + ], + "x-resourceId": "payout" + }, + "paypal_seller_protection": { + "description": "", + "properties": { + "dispute_categories": { + "description": "An array of conditions that are covered for the transaction, if applicable.", + "items": { + "enum": ["fraudulent", "product_not_received"], + "type": "string", + "x-stripeBypassValidation": true + }, + "nullable": true, + "type": "array" + }, + "status": { + "description": "Indicates whether the transaction is eligible for PayPal's seller protection.", + "enum": ["eligible", "not_eligible", "partially_eligible"], + "type": "string" + } + }, + "required": ["status"], + "title": "paypal_seller_protection", + "type": "object", + "x-expandableFields": [] + }, + "period": { + "description": "", + "properties": { + "end": { + "description": "The end date of this usage period. All usage up to and including this point in time is included.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "start": { + "description": "The start date of this usage period. All usage after this point in time is included.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "title": "Period", + "type": "object", + "x-expandableFields": [] + }, + "person": { + "description": "This is an object representing a person associated with a Stripe account.\n\nA platform cannot access a person for an account where [account.controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`, which includes Standard and Express accounts, after creating an Account Link or Account Session to start Connect onboarding.\n\nSee the [Standard onboarding](/connect/standard-accounts) or [Express onboarding](/connect/express-accounts) documentation for information about prefilling information and account onboarding steps. Learn more about [handling identity verification with the API](/connect/handling-api-verification#person-information).", + "properties": { + "account": { + "description": "The account the person is associated with.", + "maxLength": 5000, + "type": "string" + }, + "additional_tos_acceptances": { + "$ref": "#/components/schemas/person_additional_tos_acceptances" + }, + "address": { + "$ref": "#/components/schemas/address" + }, + "address_kana": { + "anyOf": [ + { + "$ref": "#/components/schemas/legal_entity_japan_address" + } + ], + "nullable": true + }, + "address_kanji": { + "anyOf": [ + { + "$ref": "#/components/schemas/legal_entity_japan_address" + } + ], + "nullable": true + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "dob": { + "$ref": "#/components/schemas/legal_entity_dob" + }, + "email": { + "description": "The person's email address.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "first_name": { + "description": "The person's first name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "first_name_kana": { + "description": "The Kana variation of the person's first name (Japan only).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "first_name_kanji": { + "description": "The Kanji variation of the person's first name (Japan only).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "full_name_aliases": { + "description": "A list of alternate names or aliases that the person is known by.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "future_requirements": { + "anyOf": [ + { + "$ref": "#/components/schemas/person_future_requirements" + } + ], + "nullable": true + }, + "gender": { + "description": "The person's gender (International regulations require either \"male\" or \"female\").", + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "id_number_provided": { + "description": "Whether the person's `id_number` was provided. True if either the full ID number was provided or if only the required part of the ID number was provided (ex. last four of an individual's SSN for the US indicated by `ssn_last_4_provided`).", + "type": "boolean" + }, + "id_number_secondary_provided": { + "description": "Whether the person's `id_number_secondary` was provided.", + "type": "boolean" + }, + "last_name": { + "description": "The person's last name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last_name_kana": { + "description": "The Kana variation of the person's last name (Japan only).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last_name_kanji": { + "description": "The Kanji variation of the person's last name (Japan only).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "maiden_name": { + "description": "The person's maiden name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "nationality": { + "description": "The country where the person is a national.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["person"], + "type": "string" + }, + "phone": { + "description": "The person's phone number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "political_exposure": { + "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", + "enum": ["existing", "none"], + "type": "string" + }, + "registered_address": { + "$ref": "#/components/schemas/address" + }, + "relationship": { + "$ref": "#/components/schemas/person_relationship" + }, + "requirements": { + "anyOf": [ + { + "$ref": "#/components/schemas/person_requirements" + } + ], + "nullable": true + }, + "ssn_last_4_provided": { + "description": "Whether the last four digits of the person's Social Security number have been provided (U.S. only).", + "type": "boolean" + }, + "verification": { + "$ref": "#/components/schemas/legal_entity_person_verification" + } + }, + "required": ["account", "created", "id", "object"], + "title": "Person", + "type": "object", + "x-expandableFields": [ + "additional_tos_acceptances", + "address", + "address_kana", + "address_kanji", + "dob", + "future_requirements", + "registered_address", + "relationship", + "requirements", + "verification" + ], + "x-resourceId": "person" + }, + "person_additional_tos_acceptance": { + "description": "", + "properties": { + "date": { + "description": "The Unix timestamp marking when the legal guardian accepted the service agreement.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "ip": { + "description": "The IP address from which the legal guardian accepted the service agreement.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "user_agent": { + "description": "The user agent of the browser from which the legal guardian accepted the service agreement.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "PersonAdditionalTOSAcceptance", + "type": "object", + "x-expandableFields": [] + }, + "person_additional_tos_acceptances": { + "description": "", + "properties": { + "account": { + "anyOf": [ + { + "$ref": "#/components/schemas/person_additional_tos_acceptance" + } + ], + "description": "Details on the legal guardian's acceptance of the main Stripe service agreement.", + "nullable": true + } + }, + "title": "PersonAdditionalTOSAcceptances", + "type": "object", + "x-expandableFields": ["account"] + }, + "person_future_requirements": { + "description": "", + "properties": { + "alternatives": { + "description": "Fields that are due and can be satisfied by providing the corresponding alternative fields instead.", + "items": { + "$ref": "#/components/schemas/account_requirements_alternative" + }, + "nullable": true, + "type": "array" + }, + "currently_due": { + "description": "Fields that need to be collected to keep the person's account enabled. If not collected by the account's `future_requirements[current_deadline]`, these fields will transition to the main `requirements` hash, and may immediately become `past_due`, but the account may also be given a grace period depending on the account's enablement state prior to transition.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "errors": { + "description": "Fields that are `currently_due` and need to be collected again because validation or verification failed.", + "items": { + "$ref": "#/components/schemas/account_requirements_error" + }, + "type": "array" + }, + "eventually_due": { + "description": "Fields that need to be collected assuming all volume thresholds are reached. As they become required, they appear in `currently_due` as well, and the account's `future_requirements[current_deadline]` becomes set.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "past_due": { + "description": "Fields that weren't collected by the account's `requirements.current_deadline`. These fields need to be collected to enable the person's account. New fields will never appear here; `future_requirements.past_due` will always be a subset of `requirements.past_due`.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "pending_verification": { + "description": "Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`. Fields might appear in `eventually_due` or `currently_due` and in `pending_verification` if verification fails but another verification is still pending.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "currently_due", + "errors", + "eventually_due", + "past_due", + "pending_verification" + ], + "title": "PersonFutureRequirements", + "type": "object", + "x-expandableFields": ["alternatives", "errors"] + }, + "person_relationship": { + "description": "", + "properties": { + "director": { + "description": "Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.", + "nullable": true, + "type": "boolean" + }, + "executive": { + "description": "Whether the person has significant responsibility to control, manage, or direct the organization.", + "nullable": true, + "type": "boolean" + }, + "legal_guardian": { + "description": "Whether the person is the legal guardian of the account's representative.", + "nullable": true, + "type": "boolean" + }, + "owner": { + "description": "Whether the person is an owner of the account’s legal entity.", + "nullable": true, + "type": "boolean" + }, + "percent_ownership": { + "description": "The percent owned by the person of the account's legal entity.", + "nullable": true, + "type": "number" + }, + "representative": { + "description": "Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.", + "nullable": true, + "type": "boolean" + }, + "title": { + "description": "The person's title (e.g., CEO, Support Engineer).", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "PersonRelationship", + "type": "object", + "x-expandableFields": [] + }, + "person_requirements": { + "description": "", + "properties": { + "alternatives": { + "description": "Fields that are due and can be satisfied by providing the corresponding alternative fields instead.", + "items": { + "$ref": "#/components/schemas/account_requirements_alternative" + }, + "nullable": true, + "type": "array" + }, + "currently_due": { + "description": "Fields that need to be collected to keep the person's account enabled. If not collected by the account's `current_deadline`, these fields appear in `past_due` as well, and the account is disabled.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "errors": { + "description": "Fields that are `currently_due` and need to be collected again because validation or verification failed.", + "items": { + "$ref": "#/components/schemas/account_requirements_error" + }, + "type": "array" + }, + "eventually_due": { + "description": "Fields that need to be collected assuming all volume thresholds are reached. As they become required, they appear in `currently_due` as well, and the account's `current_deadline` becomes set.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "past_due": { + "description": "Fields that weren't collected by the account's `current_deadline`. These fields need to be collected to enable the person's account.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "pending_verification": { + "description": "Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "currently_due", + "errors", + "eventually_due", + "past_due", + "pending_verification" + ], + "title": "PersonRequirements", + "type": "object", + "x-expandableFields": ["alternatives", "errors"] + }, + "plan": { + "description": "You can now model subscriptions more flexibly using the [Prices API](https://stripe.com/docs/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration.\n\nPlans define the base price, currency, and billing cycle for recurring purchases of products.\n[Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and plans help you track pricing. Different physical goods or levels of service should be represented by products, and pricing options should be represented by plans. This approach lets you change prices without having to change your provisioning scheme.\n\nFor example, you might have a single \"gold\" product that has plans for $10/month, $100/year, €9/month, and €90/year.\n\nRelated guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/products-prices/overview).", + "properties": { + "active": { + "description": "Whether the plan can be used for new purchases.", + "type": "boolean" + }, + "aggregate_usage": { + "description": "Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`.", + "enum": ["last_during_period", "last_ever", "max", "sum"], + "nullable": true, + "type": "string" + }, + "amount": { + "description": "The unit amount in cents (or local equivalent) to be charged, represented as a whole integer if possible. Only set if `billing_scheme=per_unit`.", + "nullable": true, + "type": "integer" + }, + "amount_decimal": { + "description": "The unit amount in cents (or local equivalent) to be charged, represented as a decimal string with at most 12 decimal places. Only set if `billing_scheme=per_unit`.", + "format": "decimal", + "nullable": true, + "type": "string" + }, + "billing_scheme": { + "description": "Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.", + "enum": ["per_unit", "tiered"], + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "interval": { + "description": "The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.", + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months.", + "type": "integer" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "meter": { + "description": "The meter tracking the usage of a metered price", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "nickname": { + "description": "A brief description of the plan, hidden from customers.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["plan"], + "type": "string" + }, + "product": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/product" + }, + { + "$ref": "#/components/schemas/deleted_product" + } + ], + "description": "The product whose pricing this plan determines.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/product" + }, + { + "$ref": "#/components/schemas/deleted_product" + } + ] + } + }, + "tiers": { + "description": "Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.", + "items": { + "$ref": "#/components/schemas/plan_tier" + }, + "type": "array" + }, + "tiers_mode": { + "description": "Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows.", + "enum": ["graduated", "volume"], + "nullable": true, + "type": "string" + }, + "transform_usage": { + "anyOf": [ + { + "$ref": "#/components/schemas/transform_usage" + } + ], + "description": "Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with `tiers`.", + "nullable": true + }, + "trial_period_days": { + "description": "Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).", + "nullable": true, + "type": "integer" + }, + "usage_type": { + "description": "Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.", + "enum": ["licensed", "metered"], + "type": "string" + } + }, + "required": [ + "active", + "billing_scheme", + "created", + "currency", + "id", + "interval", + "interval_count", + "livemode", + "object", + "usage_type" + ], + "title": "Plan", + "type": "object", + "x-expandableFields": ["product", "tiers", "transform_usage"], + "x-resourceId": "plan" + }, + "plan_tier": { + "description": "", + "properties": { + "flat_amount": { + "description": "Price for the entire tier.", + "nullable": true, + "type": "integer" + }, + "flat_amount_decimal": { + "description": "Same as `flat_amount`, but contains a decimal value with at most 12 decimal places.", + "format": "decimal", + "nullable": true, + "type": "string" + }, + "unit_amount": { + "description": "Per unit price for units relevant to the tier.", + "nullable": true, + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.", + "format": "decimal", + "nullable": true, + "type": "string" + }, + "up_to": { + "description": "Up to and including to this quantity will be contained in the tier.", + "nullable": true, + "type": "integer" + } + }, + "title": "PlanTier", + "type": "object", + "x-expandableFields": [] + }, + "platform_earning_fee_source": { + "description": "", + "properties": { + "charge": { + "description": "Charge ID that created this application fee.", + "maxLength": 5000, + "type": "string" + }, + "payout": { + "description": "Payout ID that created this application fee.", + "maxLength": 5000, + "type": "string" + }, + "type": { + "description": "Type of object that created the application fee, either `charge` or `payout`.", + "enum": ["charge", "payout"], + "type": "string" + } + }, + "required": ["type"], + "title": "PlatformEarningFeeSource", + "type": "object", + "x-expandableFields": [] + }, + "portal_business_profile": { + "description": "", + "properties": { + "headline": { + "description": "The messaging shown to customers in the portal.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "privacy_policy_url": { + "description": "A link to the business’s publicly available privacy policy.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "terms_of_service_url": { + "description": "A link to the business’s publicly available terms of service.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "PortalBusinessProfile", + "type": "object", + "x-expandableFields": [] + }, + "portal_customer_update": { + "description": "", + "properties": { + "allowed_updates": { + "description": "The types of customer updates that are supported. When empty, customers are not updateable.", + "items": { + "enum": [ + "address", + "email", + "name", + "phone", + "shipping", + "tax_id" + ], + "type": "string" + }, + "type": "array" + }, + "enabled": { + "description": "Whether the feature is enabled.", + "type": "boolean" + } + }, + "required": ["allowed_updates", "enabled"], + "title": "PortalCustomerUpdate", + "type": "object", + "x-expandableFields": [] + }, + "portal_features": { + "description": "", + "properties": { + "customer_update": { + "$ref": "#/components/schemas/portal_customer_update" + }, + "invoice_history": { + "$ref": "#/components/schemas/portal_invoice_list" + }, + "payment_method_update": { + "$ref": "#/components/schemas/portal_payment_method_update" + }, + "subscription_cancel": { + "$ref": "#/components/schemas/portal_subscription_cancel" + }, + "subscription_update": { + "$ref": "#/components/schemas/portal_subscription_update" + } + }, + "required": [ + "customer_update", + "invoice_history", + "payment_method_update", + "subscription_cancel", + "subscription_update" + ], + "title": "PortalFeatures", + "type": "object", + "x-expandableFields": [ + "customer_update", + "invoice_history", + "payment_method_update", + "subscription_cancel", + "subscription_update" + ] + }, + "portal_flows_after_completion_hosted_confirmation": { + "description": "", + "properties": { + "custom_message": { + "description": "A custom message to display to the customer after the flow is completed.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "PortalFlowsAfterCompletionHostedConfirmation", + "type": "object", + "x-expandableFields": [] + }, + "portal_flows_after_completion_redirect": { + "description": "", + "properties": { + "return_url": { + "description": "The URL the customer will be redirected to after the flow is completed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["return_url"], + "title": "PortalFlowsAfterCompletionRedirect", + "type": "object", + "x-expandableFields": [] + }, + "portal_flows_coupon_offer": { + "description": "", + "properties": { + "coupon": { + "description": "The ID of the coupon to be offered.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["coupon"], + "title": "PortalFlowsCouponOffer", + "type": "object", + "x-expandableFields": [] + }, + "portal_flows_flow": { + "description": "", + "properties": { + "after_completion": { + "$ref": "#/components/schemas/portal_flows_flow_after_completion" + }, + "subscription_cancel": { + "anyOf": [ + { + "$ref": "#/components/schemas/portal_flows_flow_subscription_cancel" + } + ], + "description": "Configuration when `flow.type=subscription_cancel`.", + "nullable": true + }, + "subscription_update": { + "anyOf": [ + { + "$ref": "#/components/schemas/portal_flows_flow_subscription_update" + } + ], + "description": "Configuration when `flow.type=subscription_update`.", + "nullable": true + }, + "subscription_update_confirm": { + "anyOf": [ + { + "$ref": "#/components/schemas/portal_flows_flow_subscription_update_confirm" + } + ], + "description": "Configuration when `flow.type=subscription_update_confirm`.", + "nullable": true + }, + "type": { + "description": "Type of flow that the customer will go through.", + "enum": [ + "payment_method_update", + "subscription_cancel", + "subscription_update", + "subscription_update_confirm" + ], + "type": "string" + } + }, + "required": ["after_completion", "type"], + "title": "PortalFlowsFlow", + "type": "object", + "x-expandableFields": [ + "after_completion", + "subscription_cancel", + "subscription_update", + "subscription_update_confirm" + ] + }, + "portal_flows_flow_after_completion": { + "description": "", + "properties": { + "hosted_confirmation": { + "anyOf": [ + { + "$ref": "#/components/schemas/portal_flows_after_completion_hosted_confirmation" + } + ], + "description": "Configuration when `after_completion.type=hosted_confirmation`.", + "nullable": true + }, + "redirect": { + "anyOf": [ + { + "$ref": "#/components/schemas/portal_flows_after_completion_redirect" + } + ], + "description": "Configuration when `after_completion.type=redirect`.", + "nullable": true + }, + "type": { + "description": "The specified type of behavior after the flow is completed.", + "enum": ["hosted_confirmation", "portal_homepage", "redirect"], + "type": "string" + } + }, + "required": ["type"], + "title": "PortalFlowsFlowAfterCompletion", + "type": "object", + "x-expandableFields": ["hosted_confirmation", "redirect"] + }, + "portal_flows_flow_subscription_cancel": { + "description": "", + "properties": { + "retention": { + "anyOf": [ + { + "$ref": "#/components/schemas/portal_flows_retention" + } + ], + "description": "Specify a retention strategy to be used in the cancellation flow.", + "nullable": true + }, + "subscription": { + "description": "The ID of the subscription to be canceled.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["subscription"], + "title": "PortalFlowsFlowSubscriptionCancel", + "type": "object", + "x-expandableFields": ["retention"] + }, + "portal_flows_flow_subscription_update": { + "description": "", + "properties": { + "subscription": { + "description": "The ID of the subscription to be updated.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["subscription"], + "title": "PortalFlowsFlowSubscriptionUpdate", + "type": "object", + "x-expandableFields": [] + }, + "portal_flows_flow_subscription_update_confirm": { + "description": "", + "properties": { + "discounts": { + "description": "The coupon or promotion code to apply to this subscription update. Currently, only up to one may be specified.", + "items": { + "$ref": "#/components/schemas/portal_flows_subscription_update_confirm_discount" + }, + "nullable": true, + "type": "array" + }, + "items": { + "description": "The [subscription item](https://stripe.com/docs/api/subscription_items) to be updated through this flow. Currently, only up to one may be specified and subscriptions with multiple items are not updatable.", + "items": { + "$ref": "#/components/schemas/portal_flows_subscription_update_confirm_item" + }, + "type": "array" + }, + "subscription": { + "description": "The ID of the subscription to be updated.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["items", "subscription"], + "title": "PortalFlowsFlowSubscriptionUpdateConfirm", + "type": "object", + "x-expandableFields": ["discounts", "items"] + }, + "portal_flows_retention": { + "description": "", + "properties": { + "coupon_offer": { + "anyOf": [ + { + "$ref": "#/components/schemas/portal_flows_coupon_offer" + } + ], + "description": "Configuration when `retention.type=coupon_offer`.", + "nullable": true + }, + "type": { + "description": "Type of retention strategy that will be used.", + "enum": ["coupon_offer"], + "type": "string" + } + }, + "required": ["type"], + "title": "PortalFlowsRetention", + "type": "object", + "x-expandableFields": ["coupon_offer"] + }, + "portal_flows_subscription_update_confirm_discount": { + "description": "", + "properties": { + "coupon": { + "description": "The ID of the coupon to apply to this subscription update.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "promotion_code": { + "description": "The ID of a promotion code to apply to this subscription update.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "PortalFlowsSubscriptionUpdateConfirmDiscount", + "type": "object", + "x-expandableFields": [] + }, + "portal_flows_subscription_update_confirm_item": { + "description": "", + "properties": { + "id": { + "description": "The ID of the [subscription item](https://stripe.com/docs/api/subscriptions/object#subscription_object-items-data-id) to be updated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "price": { + "description": "The price the customer should subscribe to through this flow. The price must also be included in the configuration's [`features.subscription_update.products`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-features-subscription_update-products).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "quantity": { + "description": "[Quantity](https://stripe.com/docs/subscriptions/quantities) for this item that the customer should subscribe to through this flow.", + "type": "integer" + } + }, + "title": "PortalFlowsSubscriptionUpdateConfirmItem", + "type": "object", + "x-expandableFields": [] + }, + "portal_invoice_list": { + "description": "", + "properties": { + "enabled": { + "description": "Whether the feature is enabled.", + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "PortalInvoiceList", + "type": "object", + "x-expandableFields": [] + }, + "portal_login_page": { + "description": "", + "properties": { + "enabled": { + "description": "If `true`, a shareable `url` will be generated that will take your customers to a hosted login page for the customer portal.\n\nIf `false`, the previously generated `url`, if any, will be deactivated.", + "type": "boolean" + }, + "url": { + "description": "A shareable URL to the hosted portal login page. Your customers will be able to log in with their [email](https://stripe.com/docs/api/customers/object#customer_object-email) and receive a link to their customer portal.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["enabled"], + "title": "PortalLoginPage", + "type": "object", + "x-expandableFields": [] + }, + "portal_payment_method_update": { + "description": "", + "properties": { + "enabled": { + "description": "Whether the feature is enabled.", + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "PortalPaymentMethodUpdate", + "type": "object", + "x-expandableFields": [] + }, + "portal_subscription_cancel": { + "description": "", + "properties": { + "cancellation_reason": { + "$ref": "#/components/schemas/portal_subscription_cancellation_reason" + }, + "enabled": { + "description": "Whether the feature is enabled.", + "type": "boolean" + }, + "mode": { + "description": "Whether to cancel subscriptions immediately or at the end of the billing period.", + "enum": ["at_period_end", "immediately"], + "type": "string" + }, + "proration_behavior": { + "description": "Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + } + }, + "required": [ + "cancellation_reason", + "enabled", + "mode", + "proration_behavior" + ], + "title": "PortalSubscriptionCancel", + "type": "object", + "x-expandableFields": ["cancellation_reason"] + }, + "portal_subscription_cancellation_reason": { + "description": "", + "properties": { + "enabled": { + "description": "Whether the feature is enabled.", + "type": "boolean" + }, + "options": { + "description": "Which cancellation reasons will be given as options to the customer.", + "items": { + "enum": [ + "customer_service", + "low_quality", + "missing_features", + "other", + "switched_service", + "too_complex", + "too_expensive", + "unused" + ], + "type": "string" + }, + "type": "array" + } + }, + "required": ["enabled", "options"], + "title": "PortalSubscriptionCancellationReason", + "type": "object", + "x-expandableFields": [] + }, + "portal_subscription_update": { + "description": "", + "properties": { + "default_allowed_updates": { + "description": "The types of subscription updates that are supported for items listed in the `products` attribute. When empty, subscriptions are not updateable.", + "items": { + "enum": ["price", "promotion_code", "quantity"], + "type": "string" + }, + "type": "array" + }, + "enabled": { + "description": "Whether the feature is enabled.", + "type": "boolean" + }, + "products": { + "description": "The list of up to 10 products that support subscription updates.", + "items": { + "$ref": "#/components/schemas/portal_subscription_update_product" + }, + "nullable": true, + "type": "array" + }, + "proration_behavior": { + "description": "Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`. Defaults to a value of `none` if you don't set it during creation.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + } + }, + "required": [ + "default_allowed_updates", + "enabled", + "proration_behavior" + ], + "title": "PortalSubscriptionUpdate", + "type": "object", + "x-expandableFields": ["products"] + }, + "portal_subscription_update_product": { + "description": "", + "properties": { + "prices": { + "description": "The list of price IDs which, when subscribed to, a subscription can be updated.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "product": { + "description": "The product ID.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["prices", "product"], + "title": "PortalSubscriptionUpdateProduct", + "type": "object", + "x-expandableFields": [] + }, + "price": { + "description": "Prices define the unit cost, currency, and (optional) billing cycle for both recurring and one-time purchases of products.\n[Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and prices help you track payment terms. Different physical goods or levels of service should be represented by products, and pricing options should be represented by prices. This approach lets you change prices without having to change your provisioning scheme.\n\nFor example, you might have a single \"gold\" product that has prices for $10/month, $100/year, and €9 once.\n\nRelated guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription), [create an invoice](https://stripe.com/docs/billing/invoices/create), and more about [products and prices](https://stripe.com/docs/products-prices/overview).", + "properties": { + "active": { + "description": "Whether the price can be used for new purchases.", + "type": "boolean" + }, + "billing_scheme": { + "description": "Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.", + "enum": ["per_unit", "tiered"], + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "currency_options": { + "additionalProperties": { + "$ref": "#/components/schemas/currency_option" + }, + "description": "Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).", + "type": "object" + }, + "custom_unit_amount": { + "anyOf": [ + { + "$ref": "#/components/schemas/custom_unit_amount" + } + ], + "description": "When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.", + "nullable": true + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "lookup_key": { + "description": "A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "nickname": { + "description": "A brief description of the price, hidden from customers.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["price"], + "type": "string" + }, + "product": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/product" + }, + { + "$ref": "#/components/schemas/deleted_product" + } + ], + "description": "The ID of the product this price is associated with.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/product" + }, + { + "$ref": "#/components/schemas/deleted_product" + } + ] + } + }, + "recurring": { + "anyOf": [ + { + "$ref": "#/components/schemas/recurring" + } + ], + "description": "The recurring components of a price such as `interval` and `usage_type`.", + "nullable": true + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": ["exclusive", "inclusive", "unspecified"], + "nullable": true, + "type": "string" + }, + "tiers": { + "description": "Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.", + "items": { + "$ref": "#/components/schemas/price_tier" + }, + "type": "array" + }, + "tiers_mode": { + "description": "Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows.", + "enum": ["graduated", "volume"], + "nullable": true, + "type": "string" + }, + "transform_quantity": { + "anyOf": [ + { + "$ref": "#/components/schemas/transform_quantity" + } + ], + "description": "Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with `tiers`.", + "nullable": true + }, + "type": { + "description": "One of `one_time` or `recurring` depending on whether the price is for a one-time purchase or a recurring (subscription) purchase.", + "enum": ["one_time", "recurring"], + "type": "string" + }, + "unit_amount": { + "description": "The unit amount in cents (or local equivalent) to be charged, represented as a whole integer if possible. Only set if `billing_scheme=per_unit`.", + "nullable": true, + "type": "integer" + }, + "unit_amount_decimal": { + "description": "The unit amount in cents (or local equivalent) to be charged, represented as a decimal string with at most 12 decimal places. Only set if `billing_scheme=per_unit`.", + "format": "decimal", + "nullable": true, + "type": "string" + } + }, + "required": [ + "active", + "billing_scheme", + "created", + "currency", + "id", + "livemode", + "metadata", + "object", + "product", + "type" + ], + "title": "Price", + "type": "object", + "x-expandableFields": [ + "currency_options", + "custom_unit_amount", + "product", + "recurring", + "tiers", + "transform_quantity" + ], + "x-resourceId": "price" + }, + "price_tier": { + "description": "", + "properties": { + "flat_amount": { + "description": "Price for the entire tier.", + "nullable": true, + "type": "integer" + }, + "flat_amount_decimal": { + "description": "Same as `flat_amount`, but contains a decimal value with at most 12 decimal places.", + "format": "decimal", + "nullable": true, + "type": "string" + }, + "unit_amount": { + "description": "Per unit price for units relevant to the tier.", + "nullable": true, + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.", + "format": "decimal", + "nullable": true, + "type": "string" + }, + "up_to": { + "description": "Up to and including to this quantity will be contained in the tier.", + "nullable": true, + "type": "integer" + } + }, + "title": "PriceTier", + "type": "object", + "x-expandableFields": [] + }, + "product": { + "description": "Products describe the specific goods or services you offer to your customers.\nFor example, you might offer a Standard and Premium version of your goods or service; each version would be a separate Product.\nThey can be used in conjunction with [Prices](https://stripe.com/docs/api#prices) to configure pricing in Payment Links, Checkout, and Subscriptions.\n\nRelated guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription),\n[share a Payment Link](https://stripe.com/docs/payment-links),\n[accept payments with Checkout](https://stripe.com/docs/payments/accept-a-payment#create-product-prices-upfront),\nand more about [Products and Prices](https://stripe.com/docs/products-prices/overview)", + "properties": { + "active": { + "description": "Whether the product is currently available for purchase.", + "type": "boolean" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "default_price": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/price" + } + ], + "description": "The ID of the [Price](https://stripe.com/docs/api/prices) object that is the default price for this product.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/price" + } + ] + } + }, + "description": { + "description": "The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "images": { + "description": "A list of up to 8 URLs of images for this product, meant to be displayable to the customer.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "marketing_features": { + "description": "A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).", + "items": { + "$ref": "#/components/schemas/product_marketing_feature" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "name": { + "description": "The product's name, meant to be displayable to the customer.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["product"], + "type": "string" + }, + "package_dimensions": { + "anyOf": [ + { + "$ref": "#/components/schemas/package_dimensions" + } + ], + "description": "The dimensions of this product for shipping purposes.", + "nullable": true + }, + "shippable": { + "description": "Whether this product is shipped (i.e., physical goods).", + "nullable": true, + "type": "boolean" + }, + "statement_descriptor": { + "description": "Extra information about a product which will appear on your customer's credit card statement. In the case that multiple products are billed at once, the first statement descriptor will be used. Only used for subscription payments.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "tax_code": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_code" + } + ], + "description": "A [tax code](https://stripe.com/docs/tax/tax-categories) ID.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_code" + } + ] + } + }, + "unit_label": { + "description": "A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "updated": { + "description": "Time at which the object was last updated. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "url": { + "description": "A URL of a publicly-accessible webpage for this product.", + "maxLength": 2048, + "nullable": true, + "type": "string" + } + }, + "required": [ + "active", + "created", + "id", + "images", + "livemode", + "marketing_features", + "metadata", + "name", + "object", + "updated" + ], + "title": "Product", + "type": "object", + "x-expandableFields": [ + "default_price", + "marketing_features", + "package_dimensions", + "tax_code" + ], + "x-resourceId": "product" + }, + "product_feature": { + "description": "A product_feature represents an attachment between a feature and a product.\nWhen a product is purchased that has a feature attached, Stripe will create an entitlement to the feature for the purchasing customer.", + "properties": { + "entitlement_feature": { + "$ref": "#/components/schemas/entitlements.feature" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["product_feature"], + "type": "string" + } + }, + "required": ["entitlement_feature", "id", "livemode", "object"], + "title": "ProductFeature", + "type": "object", + "x-expandableFields": ["entitlement_feature"], + "x-resourceId": "product_feature" + }, + "product_marketing_feature": { + "description": "", + "properties": { + "name": { + "description": "The marketing feature name. Up to 80 characters long.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "ProductMarketingFeature", + "type": "object", + "x-expandableFields": [] + }, + "promotion_code": { + "description": "A Promotion Code represents a customer-redeemable code for a [coupon](https://stripe.com/docs/api#coupons). It can be used to\ncreate multiple codes for a single coupon.", + "properties": { + "active": { + "description": "Whether the promotion code is currently active. A promotion code is only active if the coupon is also valid.", + "type": "boolean" + }, + "code": { + "description": "The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for each customer.", + "maxLength": 5000, + "type": "string" + }, + "coupon": { + "$ref": "#/components/schemas/coupon" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ], + "description": "The customer that this promotion code can be used by.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ] + } + }, + "expires_at": { + "description": "Date at which the promotion code can no longer be redeemed.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "max_redemptions": { + "description": "Maximum number of times this promotion code can be redeemed.", + "nullable": true, + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["promotion_code"], + "type": "string" + }, + "restrictions": { + "$ref": "#/components/schemas/promotion_codes_resource_restrictions" + }, + "times_redeemed": { + "description": "Number of times this promotion code has been used.", + "type": "integer" + } + }, + "required": [ + "active", + "code", + "coupon", + "created", + "id", + "livemode", + "object", + "restrictions", + "times_redeemed" + ], + "title": "PromotionCode", + "type": "object", + "x-expandableFields": ["coupon", "customer", "restrictions"], + "x-resourceId": "promotion_code" + }, + "promotion_code_currency_option": { + "description": "", + "properties": { + "minimum_amount": { + "description": "Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).", + "type": "integer" + } + }, + "required": ["minimum_amount"], + "title": "PromotionCodeCurrencyOption", + "type": "object", + "x-expandableFields": [] + }, + "promotion_codes_resource_restrictions": { + "description": "", + "properties": { + "currency_options": { + "additionalProperties": { + "$ref": "#/components/schemas/promotion_code_currency_option" + }, + "description": "Promotion code restrictions defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).", + "type": "object" + }, + "first_time_transaction": { + "description": "A Boolean indicating if the Promotion Code should only be redeemed for Customers without any successful payments or invoices", + "type": "boolean" + }, + "minimum_amount": { + "description": "Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).", + "nullable": true, + "type": "integer" + }, + "minimum_amount_currency": { + "description": "Three-letter [ISO code](https://stripe.com/docs/currencies) for minimum_amount", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["first_time_transaction"], + "title": "PromotionCodesResourceRestrictions", + "type": "object", + "x-expandableFields": ["currency_options"] + }, + "quote": { + "description": "A Quote is a way to model prices that you'd like to provide to a customer.\nOnce accepted, it will automatically create an invoice, subscription or subscription schedule.", + "properties": { + "amount_subtotal": { + "description": "Total before any discounts or taxes are applied.", + "type": "integer" + }, + "amount_total": { + "description": "Total after discounts and taxes are applied.", + "type": "integer" + }, + "application": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" + } + ], + "description": "ID of the Connect Application that created the quote.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" + } + ] + } + }, + "application_fee_amount": { + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. Only applicable if there are no line items with recurring prices on the quote.", + "nullable": true, + "type": "integer" + }, + "application_fee_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. Only applicable if there are line items with recurring prices on the quote.", + "nullable": true, + "type": "number" + }, + "automatic_tax": { + "$ref": "#/components/schemas/quotes_resource_automatic_tax" + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or on finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "computed": { + "$ref": "#/components/schemas/quotes_resource_computed" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ], + "description": "The customer which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ] + } + }, + "default_tax_rates": { + "description": "The tax rates applied to this quote.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_rate" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_rate" + } + ] + } + }, + "type": "array" + }, + "description": { + "description": "A description that will be displayed on the quote PDF.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "discounts": { + "description": "The discounts applied to this quote.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/discount" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/discount" + } + ] + } + }, + "type": "array" + }, + "expires_at": { + "description": "The date on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "footer": { + "description": "A footer that will be displayed on the quote PDF.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "from_quote": { + "anyOf": [ + { + "$ref": "#/components/schemas/quotes_resource_from_quote" + } + ], + "description": "Details of the quote that was cloned. See the [cloning documentation](https://stripe.com/docs/quotes/clone) for more details.", + "nullable": true + }, + "header": { + "description": "A header that will be displayed on the quote PDF.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "invoice": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/invoice" + }, + { + "$ref": "#/components/schemas/deleted_invoice" + } + ], + "description": "The invoice that was created from this quote.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/invoice" + }, + { + "$ref": "#/components/schemas/deleted_invoice" + } + ] + } + }, + "invoice_settings": { + "$ref": "#/components/schemas/invoice_setting_quote_setting" + }, + "line_items": { + "description": "A list of items the customer is being quoted for.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "QuotesResourceListLineItems", + "type": "object", + "x-expandableFields": ["data"] + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "number": { + "description": "A unique number that identifies this particular quote. This number is assigned once the quote is [finalized](https://stripe.com/docs/quotes/overview#finalize).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["quote"], + "type": "string" + }, + "on_behalf_of": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account on behalf of which to charge. See the [Connect documentation](https://support.stripe.com/questions/sending-invoices-on-behalf-of-connected-accounts) for details.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + }, + "status": { + "description": "The status of the quote.", + "enum": ["accepted", "canceled", "draft", "open"], + "type": "string", + "x-stripeBypassValidation": true + }, + "status_transitions": { + "$ref": "#/components/schemas/quotes_resource_status_transitions" + }, + "subscription": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/subscription" + } + ], + "description": "The subscription that was created or updated from this quote.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/subscription" + } + ] + } + }, + "subscription_data": { + "$ref": "#/components/schemas/quotes_resource_subscription_data_subscription_data" + }, + "subscription_schedule": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/subscription_schedule" + } + ], + "description": "The subscription schedule that was created or updated from this quote.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/subscription_schedule" + } + ] + } + }, + "test_clock": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ], + "description": "ID of the test clock this quote belongs to.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ] + } + }, + "total_details": { + "$ref": "#/components/schemas/quotes_resource_total_details" + }, + "transfer_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/quotes_resource_transfer_data" + } + ], + "description": "The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the invoices.", + "nullable": true + } + }, + "required": [ + "amount_subtotal", + "amount_total", + "automatic_tax", + "collection_method", + "computed", + "created", + "discounts", + "expires_at", + "id", + "invoice_settings", + "livemode", + "metadata", + "object", + "status", + "status_transitions", + "subscription_data", + "total_details" + ], + "title": "Quote", + "type": "object", + "x-expandableFields": [ + "application", + "automatic_tax", + "computed", + "customer", + "default_tax_rates", + "discounts", + "from_quote", + "invoice", + "invoice_settings", + "line_items", + "on_behalf_of", + "status_transitions", + "subscription", + "subscription_data", + "subscription_schedule", + "test_clock", + "total_details", + "transfer_data" + ], + "x-resourceId": "quote" + }, + "quotes_resource_automatic_tax": { + "description": "", + "properties": { + "enabled": { + "description": "Automatically calculate taxes", + "type": "boolean" + }, + "liability": { + "anyOf": [ + { + "$ref": "#/components/schemas/connect_account_reference" + } + ], + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "nullable": true + }, + "status": { + "description": "The status of the most recent automated tax calculation for this quote.", + "enum": ["complete", "failed", "requires_location_inputs"], + "nullable": true, + "type": "string" + } + }, + "required": ["enabled"], + "title": "QuotesResourceAutomaticTax", + "type": "object", + "x-expandableFields": ["liability"] + }, + "quotes_resource_computed": { + "description": "", + "properties": { + "recurring": { + "anyOf": [ + { + "$ref": "#/components/schemas/quotes_resource_recurring" + } + ], + "description": "The definitive totals and line items the customer will be charged on a recurring basis. Takes into account the line items with recurring prices and discounts with `duration=forever` coupons only. Defaults to `null` if no inputted line items with recurring prices.", + "nullable": true + }, + "upfront": { + "$ref": "#/components/schemas/quotes_resource_upfront" + } + }, + "required": ["upfront"], + "title": "QuotesResourceComputed", + "type": "object", + "x-expandableFields": ["recurring", "upfront"] + }, + "quotes_resource_from_quote": { + "description": "", + "properties": { + "is_revision": { + "description": "Whether this quote is a revision of a different quote.", + "type": "boolean" + }, + "quote": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/quote" + } + ], + "description": "The quote that was cloned.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/quote" + } + ] + } + } + }, + "required": ["is_revision", "quote"], + "title": "QuotesResourceFromQuote", + "type": "object", + "x-expandableFields": ["quote"] + }, + "quotes_resource_recurring": { + "description": "", + "properties": { + "amount_subtotal": { + "description": "Total before any discounts or taxes are applied.", + "type": "integer" + }, + "amount_total": { + "description": "Total after discounts and taxes are applied.", + "type": "integer" + }, + "interval": { + "description": "The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.", + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months.", + "type": "integer" + }, + "total_details": { + "$ref": "#/components/schemas/quotes_resource_total_details" + } + }, + "required": [ + "amount_subtotal", + "amount_total", + "interval", + "interval_count", + "total_details" + ], + "title": "QuotesResourceRecurring", + "type": "object", + "x-expandableFields": ["total_details"] + }, + "quotes_resource_status_transitions": { + "description": "", + "properties": { + "accepted_at": { + "description": "The time that the quote was accepted. Measured in seconds since Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "canceled_at": { + "description": "The time that the quote was canceled. Measured in seconds since Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "finalized_at": { + "description": "The time that the quote was finalized. Measured in seconds since Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "title": "QuotesResourceStatusTransitions", + "type": "object", + "x-expandableFields": [] + }, + "quotes_resource_subscription_data_subscription_data": { + "description": "", + "properties": { + "description": { + "description": "The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "effective_date": { + "description": "When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. This date is ignored if it is in the past when the quote is accepted. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.", + "nullable": true, + "type": "object" + }, + "trial_period_days": { + "description": "Integer representing the number of trial period days before the customer is charged for the first time.", + "nullable": true, + "type": "integer" + } + }, + "title": "QuotesResourceSubscriptionDataSubscriptionData", + "type": "object", + "x-expandableFields": [] + }, + "quotes_resource_total_details": { + "description": "", + "properties": { + "amount_discount": { + "description": "This is the sum of all the discounts.", + "type": "integer" + }, + "amount_shipping": { + "description": "This is the sum of all the shipping amounts.", + "nullable": true, + "type": "integer" + }, + "amount_tax": { + "description": "This is the sum of all the tax amounts.", + "type": "integer" + }, + "breakdown": { + "$ref": "#/components/schemas/quotes_resource_total_details_resource_breakdown" + } + }, + "required": ["amount_discount", "amount_tax"], + "title": "QuotesResourceTotalDetails", + "type": "object", + "x-expandableFields": ["breakdown"] + }, + "quotes_resource_total_details_resource_breakdown": { + "description": "", + "properties": { + "discounts": { + "description": "The aggregated discounts.", + "items": { + "$ref": "#/components/schemas/line_items_discount_amount" + }, + "type": "array" + }, + "taxes": { + "description": "The aggregated tax amounts by rate.", + "items": { + "$ref": "#/components/schemas/line_items_tax_amount" + }, + "type": "array" + } + }, + "required": ["discounts", "taxes"], + "title": "QuotesResourceTotalDetailsResourceBreakdown", + "type": "object", + "x-expandableFields": ["discounts", "taxes"] + }, + "quotes_resource_transfer_data": { + "description": "", + "properties": { + "amount": { + "description": "The amount in cents (or local equivalent) that will be transferred to the destination account when the invoice is paid. By default, the entire amount is transferred to the destination.", + "nullable": true, + "type": "integer" + }, + "amount_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount will be transferred to the destination.", + "nullable": true, + "type": "number" + }, + "destination": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account where funds from the payment will be transferred to upon payment success.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + } + }, + "required": ["destination"], + "title": "QuotesResourceTransferData", + "type": "object", + "x-expandableFields": ["destination"] + }, + "quotes_resource_upfront": { + "description": "", + "properties": { + "amount_subtotal": { + "description": "Total before any discounts or taxes are applied.", + "type": "integer" + }, + "amount_total": { + "description": "Total after discounts and taxes are applied.", + "type": "integer" + }, + "line_items": { + "description": "The line items that will appear on the next invoice after this quote is accepted. This does not include pending invoice items that exist on the customer but may still be included in the next invoice.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "QuotesResourceListLineItems", + "type": "object", + "x-expandableFields": ["data"] + }, + "total_details": { + "$ref": "#/components/schemas/quotes_resource_total_details" + } + }, + "required": ["amount_subtotal", "amount_total", "total_details"], + "title": "QuotesResourceUpfront", + "type": "object", + "x-expandableFields": ["line_items", "total_details"] + }, + "radar.early_fraud_warning": { + "description": "An early fraud warning indicates that the card issuer has notified us that a\ncharge may be fraudulent.\n\nRelated guide: [Early fraud warnings](https://stripe.com/docs/disputes/measuring#early-fraud-warnings)", + "properties": { + "actionable": { + "description": "An EFW is actionable if it has not received a dispute and has not been fully refunded. You may wish to proactively refund a charge that receives an EFW, in order to avoid receiving a dispute later.", + "type": "boolean" + }, + "charge": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/charge" + } + ], + "description": "ID of the charge this early fraud warning is for, optionally expanded.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/charge" + } + ] + } + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "fraud_type": { + "description": "The type of fraud labelled by the issuer. One of `card_never_received`, `fraudulent_card_application`, `made_with_counterfeit_card`, `made_with_lost_card`, `made_with_stolen_card`, `misc`, `unauthorized_use_of_card`.", + "maxLength": 5000, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["radar.early_fraud_warning"], + "type": "string" + }, + "payment_intent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_intent" + } + ], + "description": "ID of the Payment Intent this early fraud warning is for, optionally expanded.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_intent" + } + ] + } + } + }, + "required": [ + "actionable", + "charge", + "created", + "fraud_type", + "id", + "livemode", + "object" + ], + "title": "RadarEarlyFraudWarning", + "type": "object", + "x-expandableFields": ["charge", "payment_intent"], + "x-resourceId": "radar.early_fraud_warning" + }, + "radar.value_list": { + "description": "Value lists allow you to group values together which can then be referenced in rules.\n\nRelated guide: [Default Stripe lists](https://stripe.com/docs/radar/lists#managing-list-items)", + "properties": { + "alias": { + "description": "The name of the value list for use in rules.", + "maxLength": 5000, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "created_by": { + "description": "The name or email address of the user who created this value list.", + "maxLength": 5000, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "item_type": { + "description": "The type of items in the value list. One of `card_fingerprint`, `us_bank_account_fingerprint`, `sepa_debit_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, `case_sensitive_string`, or `customer_id`.", + "enum": [ + "card_bin", + "card_fingerprint", + "case_sensitive_string", + "country", + "customer_id", + "email", + "ip_address", + "sepa_debit_fingerprint", + "string", + "us_bank_account_fingerprint" + ], + "type": "string" + }, + "list_items": { + "description": "List of items contained within this value list.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/radar.value_list_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "RadarListListItemList", + "type": "object", + "x-expandableFields": ["data"] + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "name": { + "description": "The name of the value list.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["radar.value_list"], + "type": "string" + } + }, + "required": [ + "alias", + "created", + "created_by", + "id", + "item_type", + "list_items", + "livemode", + "metadata", + "name", + "object" + ], + "title": "RadarListList", + "type": "object", + "x-expandableFields": ["list_items"], + "x-resourceId": "radar.value_list" + }, + "radar.value_list_item": { + "description": "Value list items allow you to add specific values to a given Radar value list, which can then be used in rules.\n\nRelated guide: [Managing list items](https://stripe.com/docs/radar/lists#managing-list-items)", + "properties": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "created_by": { + "description": "The name or email address of the user who added this item to the value list.", + "maxLength": 5000, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["radar.value_list_item"], + "type": "string" + }, + "value": { + "description": "The value of the item.", + "maxLength": 5000, + "type": "string" + }, + "value_list": { + "description": "The identifier of the value list this item belongs to.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "created", + "created_by", + "id", + "livemode", + "object", + "value", + "value_list" + ], + "title": "RadarListListItem", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "radar.value_list_item" + }, + "radar_radar_options": { + "description": "Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.", + "properties": { + "session": { + "description": "A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "RadarRadarOptions", + "type": "object", + "x-expandableFields": [] + }, + "radar_review_resource_location": { + "description": "", + "properties": { + "city": { + "description": "The city where the payment originated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "country": { + "description": "Two-letter ISO code representing the country where the payment originated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "latitude": { + "description": "The geographic latitude where the payment originated.", + "nullable": true, + "type": "number" + }, + "longitude": { + "description": "The geographic longitude where the payment originated.", + "nullable": true, + "type": "number" + }, + "region": { + "description": "The state/county/province/region where the payment originated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "RadarReviewResourceLocation", + "type": "object", + "x-expandableFields": [] + }, + "radar_review_resource_session": { + "description": "", + "properties": { + "browser": { + "description": "The browser used in this browser session (e.g., `Chrome`).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "device": { + "description": "Information about the device used for the browser session (e.g., `Samsung SM-G930T`).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "platform": { + "description": "The platform for the browser session (e.g., `Macintosh`).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "version": { + "description": "The version for the browser session (e.g., `61.0.3163.100`).", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "RadarReviewResourceSession", + "type": "object", + "x-expandableFields": [] + }, + "received_payment_method_details_financial_account": { + "description": "", + "properties": { + "id": { + "description": "The FinancialAccount ID.", + "maxLength": 5000, + "type": "string" + }, + "network": { + "description": "The rails the ReceivedCredit was sent over. A FinancialAccount can only send funds over `stripe`.", + "enum": ["stripe"], + "type": "string" + } + }, + "required": ["id", "network"], + "title": "received_payment_method_details_financial_account", + "type": "object", + "x-expandableFields": [] + }, + "recurring": { + "description": "", + "properties": { + "aggregate_usage": { + "description": "Specifies a usage aggregation strategy for prices of `usage_type=metered`. Defaults to `sum`.", + "enum": ["last_during_period", "last_ever", "max", "sum"], + "nullable": true, + "type": "string" + }, + "interval": { + "description": "The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.", + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months.", + "type": "integer" + }, + "meter": { + "description": "The meter tracking the usage of a metered price", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "usage_type": { + "description": "Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.", + "enum": ["licensed", "metered"], + "type": "string" + } + }, + "required": ["interval", "interval_count", "usage_type"], + "title": "Recurring", + "type": "object", + "x-expandableFields": [] + }, + "refund": { + "description": "Refund objects allow you to refund a previously created charge that isn't\nrefunded yet. Funds are refunded to the credit or debit card that's\ninitially charged.\n\nRelated guide: [Refunds](https://stripe.com/docs/refunds)", + "properties": { + "amount": { + "description": "Amount, in cents (or local equivalent).", + "type": "integer" + }, + "balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "Balance transaction that describes the impact on your account balance.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } + }, + "charge": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/charge" + } + ], + "description": "ID of the charge that's refunded.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/charge" + } + ] + } + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. You can use this for displaying to users (available on non-card refunds only).", + "maxLength": 5000, + "type": "string" + }, + "destination_details": { + "$ref": "#/components/schemas/refund_destination_details" + }, + "failure_balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "After the refund fails, this balance transaction describes the adjustment made on your account balance that reverses the initial balance transaction.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } + }, + "failure_reason": { + "description": "Provides the reason for the refund failure. Possible values are: `lost_or_stolen_card`, `expired_or_canceled_card`, `charge_for_pending_refund_disputed`, `insufficient_funds`, `declined`, `merchant_request`, or `unknown`.", + "maxLength": 5000, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "instructions_email": { + "description": "For payment methods without native refund support (for example, Konbini, PromptPay), provide an email address for the customer to receive refund instructions.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "next_action": { + "$ref": "#/components/schemas/refund_next_action" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["refund"], + "type": "string" + }, + "payment_intent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_intent" + } + ], + "description": "ID of the PaymentIntent that's refunded.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_intent" + } + ] + } + }, + "reason": { + "description": "Reason for the refund, which is either user-provided (`duplicate`, `fraudulent`, or `requested_by_customer`) or generated by Stripe internally (`expired_uncaptured_charge`).", + "enum": [ + "duplicate", + "expired_uncaptured_charge", + "fraudulent", + "requested_by_customer" + ], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "receipt_number": { + "description": "This is the transaction number that appears on email receipts sent for this refund.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "source_transfer_reversal": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/transfer_reversal" + } + ], + "description": "The transfer reversal that's associated with the refund. Only present if the charge came from another Stripe account.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/transfer_reversal" + } + ] + } + }, + "status": { + "description": "Status of the refund. This can be `pending`, `requires_action`, `succeeded`, `failed`, or `canceled`. Learn more about [failed refunds](https://stripe.com/docs/refunds#failed-refunds).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "transfer_reversal": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/transfer_reversal" + } + ], + "description": "This refers to the transfer reversal object if the accompanying transfer reverses. This is only applicable if the charge was created using the destination parameter.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/transfer_reversal" + } + ] + } + } + }, + "required": ["amount", "created", "currency", "id", "object"], + "title": "Refund", + "type": "object", + "x-expandableFields": [ + "balance_transaction", + "charge", + "destination_details", + "failure_balance_transaction", + "next_action", + "payment_intent", + "source_transfer_reversal", + "transfer_reversal" + ], + "x-resourceId": "refund" + }, + "refund_destination_details": { + "description": "", + "properties": { + "affirm": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "afterpay_clearpay": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "alipay": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "amazon_pay": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "au_bank_transfer": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "blik": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "br_bank_transfer": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "card": { + "$ref": "#/components/schemas/refund_destination_details_card" + }, + "cashapp": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "customer_cash_balance": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "eps": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "eu_bank_transfer": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "gb_bank_transfer": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "giropay": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "grabpay": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "jp_bank_transfer": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "klarna": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "multibanco": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "mx_bank_transfer": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "p24": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "paynow": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "paypal": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "pix": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "revolut": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "sofort": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "swish": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "th_bank_transfer": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "type": { + "description": "The type of transaction-specific details of the payment method used in the refund (e.g., `card`). An additional hash is included on `destination_details` with a name matching this value. It contains information specific to the refund transaction.", + "maxLength": 5000, + "type": "string" + }, + "us_bank_transfer": { + "$ref": "#/components/schemas/refund_destination_details_generic" + }, + "wechat_pay": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, + "zip": { + "$ref": "#/components/schemas/destination_details_unimplemented" + } + }, + "required": ["type"], + "title": "refund_destination_details", + "type": "object", + "x-expandableFields": [ + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_bank_transfer", + "blik", + "br_bank_transfer", + "card", + "cashapp", + "customer_cash_balance", + "eps", + "eu_bank_transfer", + "gb_bank_transfer", + "giropay", + "grabpay", + "jp_bank_transfer", + "klarna", + "multibanco", + "mx_bank_transfer", + "p24", + "paynow", + "paypal", + "pix", + "revolut", + "sofort", + "swish", + "th_bank_transfer", + "us_bank_transfer", + "wechat_pay", + "zip" + ] + }, + "refund_destination_details_card": { + "description": "", + "properties": { + "reference": { + "description": "Value of the reference number assigned to the refund.", + "maxLength": 5000, + "type": "string" + }, + "reference_status": { + "description": "Status of the reference number on the refund. This can be `pending`, `available` or `unavailable`.", + "maxLength": 5000, + "type": "string" + }, + "reference_type": { + "description": "Type of the reference number assigned to the refund.", + "maxLength": 5000, + "type": "string" + }, + "type": { + "description": "The type of refund. This can be `refund`, `reversal`, or `pending`.", + "enum": ["pending", "refund", "reversal"], + "type": "string" + } + }, + "required": ["type"], + "title": "refund_destination_details_card", + "type": "object", + "x-expandableFields": [] + }, + "refund_destination_details_generic": { + "description": "", + "properties": { + "reference": { + "description": "The reference assigned to the refund.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "reference_status": { + "description": "Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "refund_destination_details_generic", + "type": "object", + "x-expandableFields": [] + }, + "refund_next_action": { + "description": "", + "properties": { + "display_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/refund_next_action_display_details" + } + ], + "description": "Contains the refund details.", + "nullable": true + }, + "type": { + "description": "Type of the next action to perform.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "RefundNextAction", + "type": "object", + "x-expandableFields": ["display_details"] + }, + "refund_next_action_display_details": { + "description": "", + "properties": { + "email_sent": { + "$ref": "#/components/schemas/email_sent" + }, + "expires_at": { + "description": "The expiry timestamp.", + "format": "unix-time", + "type": "integer" + } + }, + "required": ["email_sent", "expires_at"], + "title": "RefundNextActionDisplayDetails", + "type": "object", + "x-expandableFields": ["email_sent"] + }, + "reporting.report_run": { + "description": "The Report Run object represents an instance of a report type generated with\nspecific run parameters. Once the object is created, Stripe begins processing the report.\nWhen the report has finished running, it will give you a reference to a file\nwhere you can retrieve your results. For an overview, see\n[API Access to Reports](https://stripe.com/docs/reporting/statements/api).\n\nNote that certain report types can only be run based on your live-mode data (not test-mode\ndata), and will error when queried without a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).", + "properties": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "error": { + "description": "If something should go wrong during the run, a message about the failure (populated when\n `status=failed`).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "`true` if the report is run on live mode data and `false` if it is run on test mode data.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["reporting.report_run"], + "type": "string" + }, + "parameters": { + "$ref": "#/components/schemas/financial_reporting_finance_report_run_run_parameters" + }, + "report_type": { + "description": "The ID of the [report type](https://stripe.com/docs/reports/report-types) to run, such as `\"balance.summary.1\"`.", + "maxLength": 5000, + "type": "string" + }, + "result": { + "anyOf": [ + { + "$ref": "#/components/schemas/file" + } + ], + "description": "The file object representing the result of the report run (populated when\n `status=succeeded`).", + "nullable": true + }, + "status": { + "description": "Status of this report run. This will be `pending` when the run is initially created.\n When the run finishes, this will be set to `succeeded` and the `result` field will be populated.\n Rarely, we may encounter an error, at which point this will be set to `failed` and the `error` field will be populated.", + "maxLength": 5000, + "type": "string" + }, + "succeeded_at": { + "description": "Timestamp at which this run successfully finished (populated when\n `status=succeeded`). Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "required": [ + "created", + "id", + "livemode", + "object", + "parameters", + "report_type", + "status" + ], + "title": "reporting_report_run", + "type": "object", + "x-expandableFields": ["parameters", "result"], + "x-resourceId": "reporting.report_run" + }, + "reporting.report_type": { + "description": "The Report Type resource corresponds to a particular type of report, such as\nthe \"Activity summary\" or \"Itemized payouts\" reports. These objects are\nidentified by an ID belonging to a set of enumerated values. See\n[API Access to Reports documentation](https://stripe.com/docs/reporting/statements/api)\nfor those Report Type IDs, along with required and optional parameters.\n\nNote that certain report types can only be run based on your live-mode data (not test-mode\ndata), and will error when queried without a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).", + "properties": { + "data_available_end": { + "description": "Most recent time for which this Report Type is available. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "data_available_start": { + "description": "Earliest time for which this Report Type is available. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "default_columns": { + "description": "List of column names that are included by default when this Report Type gets run. (If the Report Type doesn't support the `columns` parameter, this will be null.)", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "id": { + "description": "The [ID of the Report Type](https://stripe.com/docs/reporting/statements/api#available-report-types), such as `balance.summary.1`.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "name": { + "description": "Human-readable name of the Report Type", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["reporting.report_type"], + "type": "string" + }, + "updated": { + "description": "When this Report Type was latest updated. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "version": { + "description": "Version of the Report Type. Different versions report with the same ID will have the same purpose, but may take different run parameters or have different result schemas.", + "type": "integer" + } + }, + "required": [ + "data_available_end", + "data_available_start", + "id", + "livemode", + "name", + "object", + "updated", + "version" + ], + "title": "reporting_report_type", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "reporting.report_type" + }, + "reserve_transaction": { + "description": "", + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["reserve_transaction"], + "type": "string" + } + }, + "required": ["amount", "currency", "id", "object"], + "title": "ReserveTransaction", + "type": "object", + "x-expandableFields": [] + }, + "review": { + "description": "Reviews can be used to supplement automated fraud detection with human expertise.\n\nLearn more about [Radar](/radar) and reviewing payments\n[here](https://stripe.com/docs/radar/reviews).", + "properties": { + "billing_zip": { + "description": "The ZIP or postal code of the card used, if applicable.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "charge": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/charge" + } + ], + "description": "The charge associated with this review.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/charge" + } + ] + } + }, + "closed_reason": { + "description": "The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, `disputed`, or `redacted`.", + "enum": [ + "approved", + "disputed", + "redacted", + "refunded", + "refunded_as_fraud" + ], + "nullable": true, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "ip_address": { + "description": "The IP address where the payment originated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "ip_address_location": { + "anyOf": [ + { + "$ref": "#/components/schemas/radar_review_resource_location" + } + ], + "description": "Information related to the location of the payment. Note that this information is an approximation and attempts to locate the nearest population center - it should not be used to determine a specific address.", + "nullable": true + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["review"], + "type": "string" + }, + "open": { + "description": "If `true`, the review needs action.", + "type": "boolean" + }, + "opened_reason": { + "description": "The reason the review was opened. One of `rule` or `manual`.", + "enum": ["manual", "rule"], + "type": "string" + }, + "payment_intent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_intent" + } + ], + "description": "The PaymentIntent ID associated with this review, if one exists.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_intent" + } + ] + } + }, + "reason": { + "description": "The reason the review is currently open or closed. One of `rule`, `manual`, `approved`, `refunded`, `refunded_as_fraud`, `disputed`, or `redacted`.", + "maxLength": 5000, + "type": "string" + }, + "session": { + "anyOf": [ + { + "$ref": "#/components/schemas/radar_review_resource_session" + } + ], + "description": "Information related to the browsing session of the user who initiated the payment.", + "nullable": true + } + }, + "required": [ + "created", + "id", + "livemode", + "object", + "open", + "opened_reason", + "reason" + ], + "title": "RadarReview", + "type": "object", + "x-expandableFields": [ + "charge", + "ip_address_location", + "payment_intent", + "session" + ], + "x-resourceId": "review" + }, + "rule": { + "description": "", + "properties": { + "action": { + "description": "The action taken on the payment.", + "maxLength": 5000, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "predicate": { + "description": "The predicate to evaluate the payment against.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["action", "id", "predicate"], + "title": "RadarRule", + "type": "object", + "x-expandableFields": [] + }, + "scheduled_query_run": { + "description": "If you have [scheduled a Sigma query](https://stripe.com/docs/sigma/scheduled-queries), you'll\nreceive a `sigma.scheduled_query_run.created` webhook each time the query\nruns. The webhook contains a `ScheduledQueryRun` object, which you can use to\nretrieve the query results.", + "properties": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "data_load_time": { + "description": "When the query was run, Sigma contained a snapshot of your Stripe data at this time.", + "format": "unix-time", + "type": "integer" + }, + "error": { + "$ref": "#/components/schemas/sigma_scheduled_query_run_error" + }, + "file": { + "anyOf": [ + { + "$ref": "#/components/schemas/file" + } + ], + "description": "The file object representing the results of the query.", + "nullable": true + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["scheduled_query_run"], + "type": "string" + }, + "result_available_until": { + "description": "Time at which the result expires and is no longer available for download.", + "format": "unix-time", + "type": "integer" + }, + "sql": { + "description": "SQL for the query.", + "maxLength": 100000, + "type": "string" + }, + "status": { + "description": "The query's execution status, which will be `completed` for successful runs, and `canceled`, `failed`, or `timed_out` otherwise.", + "maxLength": 5000, + "type": "string" + }, + "title": { + "description": "Title of the query.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "created", + "data_load_time", + "id", + "livemode", + "object", + "result_available_until", + "sql", + "status", + "title" + ], + "title": "ScheduledQueryRun", + "type": "object", + "x-expandableFields": ["error", "file"], + "x-resourceId": "scheduled_query_run" + }, + "schedules_phase_automatic_tax": { + "description": "", + "properties": { + "enabled": { + "description": "Whether Stripe automatically computes tax on invoices created during this phase.", + "type": "boolean" + }, + "liability": { + "anyOf": [ + { + "$ref": "#/components/schemas/connect_account_reference" + } + ], + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "nullable": true + } + }, + "required": ["enabled"], + "title": "SchedulesPhaseAutomaticTax", + "type": "object", + "x-expandableFields": ["liability"] + }, + "secret_service_resource_scope": { + "description": "", + "properties": { + "type": { + "description": "The secret scope type.", + "enum": ["account", "user"], + "type": "string" + }, + "user": { + "description": "The user ID, if type is set to \"user\"", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "SecretServiceResourceScope", + "type": "object", + "x-expandableFields": [] + }, + "sepa_debit_generated_from": { + "description": "", + "properties": { + "charge": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/charge" + } + ], + "description": "The ID of the Charge that generated this PaymentMethod, if any.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/charge" + } + ] + } + }, + "setup_attempt": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/setup_attempt" + } + ], + "description": "The ID of the SetupAttempt that generated this PaymentMethod, if any.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/setup_attempt" + } + ] + } + } + }, + "title": "sepa_debit_generated_from", + "type": "object", + "x-expandableFields": ["charge", "setup_attempt"] + }, + "setup_attempt": { + "description": "A SetupAttempt describes one attempted confirmation of a SetupIntent,\nwhether that confirmation is successful or unsuccessful. You can use\nSetupAttempts to inspect details of a specific attempt at setting up a\npayment method using a SetupIntent.", + "properties": { + "application": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application" + } + ], + "description": "The value of [application](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-application) on the SetupIntent at the time of this confirmation.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application" + } + ] + } + }, + "attach_to_self": { + "description": "If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.\n\nIt can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.", + "type": "boolean" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ], + "description": "The value of [customer](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-customer) on the SetupIntent at the time of this confirmation.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ] + } + }, + "flow_directions": { + "description": "Indicates the directions of money movement for which this payment method is intended to be used.\n\nInclude `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.", + "items": { + "enum": ["inbound", "outbound"], + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["setup_attempt"], + "type": "string" + }, + "on_behalf_of": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The value of [on_behalf_of](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-on_behalf_of) on the SetupIntent at the time of this confirmation.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + }, + "payment_method": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "ID of the payment method used with this SetupAttempt.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "payment_method_details": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details" + }, + "setup_error": { + "anyOf": [ + { + "$ref": "#/components/schemas/api_errors" + } + ], + "description": "The error encountered during this attempt to confirm the SetupIntent, if any.", + "nullable": true + }, + "setup_intent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/setup_intent" + } + ], + "description": "ID of the SetupIntent that this attempt belongs to.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/setup_intent" + } + ] + } + }, + "status": { + "description": "Status of this SetupAttempt, one of `requires_confirmation`, `requires_action`, `processing`, `succeeded`, `failed`, or `abandoned`.", + "maxLength": 5000, + "type": "string" + }, + "usage": { + "description": "The value of [usage](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-usage) on the SetupIntent at the time of this confirmation, one of `off_session` or `on_session`.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "created", + "id", + "livemode", + "object", + "payment_method", + "payment_method_details", + "setup_intent", + "status", + "usage" + ], + "title": "PaymentFlowsSetupIntentSetupAttempt", + "type": "object", + "x-expandableFields": [ + "application", + "customer", + "on_behalf_of", + "payment_method", + "payment_method_details", + "setup_error", + "setup_intent" + ], + "x-resourceId": "setup_attempt" + }, + "setup_attempt_payment_method_details": { + "description": "", + "properties": { + "acss_debit": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_acss_debit" + }, + "amazon_pay": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_amazon_pay" + }, + "au_becs_debit": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_au_becs_debit" + }, + "bacs_debit": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_bacs_debit" + }, + "bancontact": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_bancontact" + }, + "boleto": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_boleto" + }, + "card": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_card" + }, + "card_present": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_card_present" + }, + "cashapp": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_cashapp" + }, + "ideal": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_ideal" + }, + "klarna": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_klarna" + }, + "link": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_link" + }, + "paypal": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_paypal" + }, + "revolut_pay": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_revolut_pay" + }, + "sepa_debit": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_sepa_debit" + }, + "sofort": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_sofort" + }, + "type": { + "description": "The type of the payment method used in the SetupIntent (e.g., `card`). An additional hash is included on `payment_method_details` with a name matching this value. It contains confirmation-specific information for the payment method.", + "maxLength": 5000, + "type": "string" + }, + "us_bank_account": { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_us_bank_account" + } + }, + "required": ["type"], + "title": "SetupAttemptPaymentMethodDetails", + "type": "object", + "x-expandableFields": [ + "acss_debit", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "card_present", + "cashapp", + "ideal", + "klarna", + "link", + "paypal", + "revolut_pay", + "sepa_debit", + "sofort", + "us_bank_account" + ] + }, + "setup_attempt_payment_method_details_acss_debit": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_acss_debit", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_amazon_pay": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_amazon_pay", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_au_becs_debit": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_au_becs_debit", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_bacs_debit": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_bacs_debit", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_bancontact": { + "description": "", + "properties": { + "bank_code": { + "description": "Bank code of bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "bank_name": { + "description": "Name of the bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "bic": { + "description": "Bank Identifier Code of the bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "generated_sepa_debit": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "generated_sepa_debit_mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/mandate" + } + ], + "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" + } + ] + } + }, + "iban_last4": { + "description": "Last four characters of the IBAN.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "preferred_language": { + "description": "Preferred language of the Bancontact authorization page that the customer is redirected to.\nCan be one of `en`, `de`, `fr`, or `nl`", + "enum": ["de", "en", "fr", "nl"], + "nullable": true, + "type": "string" + }, + "verified_name": { + "description": "Owner's verified full name. Values are verified or provided by Bancontact directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "setup_attempt_payment_method_details_bancontact", + "type": "object", + "x-expandableFields": [ + "generated_sepa_debit", + "generated_sepa_debit_mandate" + ] + }, + "setup_attempt_payment_method_details_boleto": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_boleto", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_card": { + "description": "", + "properties": { + "brand": { + "description": "Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "checks": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_card_checks" + } + ], + "description": "Check results by Card networks on Card address and CVC at the time of authorization", + "nullable": true + }, + "country": { + "description": "Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "exp_month": { + "description": "Two-digit number representing the card's expiration month.", + "nullable": true, + "type": "integer" + }, + "exp_year": { + "description": "Four-digit number representing the card's expiration year.", + "nullable": true, + "type": "integer" + }, + "fingerprint": { + "description": "Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.\n\n*As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "funding": { + "description": "Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "The last four digits of the card.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "network": { + "description": "Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "three_d_secure": { + "anyOf": [ + { + "$ref": "#/components/schemas/three_d_secure_details" + } + ], + "description": "Populated if this authorization used 3D Secure authentication.", + "nullable": true + }, + "wallet": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_attempt_payment_method_details_card_wallet" + } + ], + "description": "If this Card is part of a card wallet, this contains the details of the card wallet.", + "nullable": true + } + }, + "title": "setup_attempt_payment_method_details_card", + "type": "object", + "x-expandableFields": ["checks", "three_d_secure", "wallet"] + }, + "setup_attempt_payment_method_details_card_checks": { + "description": "", + "properties": { + "address_line1_check": { + "description": "If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "address_postal_code_check": { + "description": "If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "cvc_check": { + "description": "If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "setup_attempt_payment_method_details_card_checks", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_card_present": { + "description": "", + "properties": { + "generated_card": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "The ID of the Card PaymentMethod which was generated by this SetupAttempt.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "offline": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_details_card_present_offline" + } + ], + "description": "Details about payments collected offline.", + "nullable": true + } + }, + "title": "setup_attempt_payment_method_details_card_present", + "type": "object", + "x-expandableFields": ["generated_card", "offline"] + }, + "setup_attempt_payment_method_details_card_wallet": { + "description": "", + "properties": { + "apple_pay": { + "$ref": "#/components/schemas/payment_method_details_card_wallet_apple_pay" + }, + "google_pay": { + "$ref": "#/components/schemas/payment_method_details_card_wallet_google_pay" + }, + "type": { + "description": "The type of the card wallet, one of `apple_pay`, `google_pay`, or `link`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type.", + "enum": ["apple_pay", "google_pay", "link"], + "type": "string" + } + }, + "required": ["type"], + "title": "setup_attempt_payment_method_details_card_wallet", + "type": "object", + "x-expandableFields": ["apple_pay", "google_pay"] + }, + "setup_attempt_payment_method_details_cashapp": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_cashapp", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_ideal": { + "description": "", + "properties": { + "bank": { + "description": "The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `n26`, `nn`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, `van_lanschot`, or `yoursafe`.", + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "nullable": true, + "type": "string" + }, + "bic": { + "description": "The Bank Identifier Code of the customer's bank.", + "enum": [ + "ABNANL2A", + "ASNBNL21", + "BITSNL2A", + "BUNQNL2A", + "FVLBNL22", + "HANDNL2A", + "INGBNL2A", + "KNABNL2H", + "MOYONL21", + "NNBANL2G", + "NTSBDEB1", + "RABONL2U", + "RBRBNL21", + "REVOIE23", + "REVOLT21", + "SNSBNL2A", + "TRIONL2U" + ], + "nullable": true, + "type": "string" + }, + "generated_sepa_debit": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "generated_sepa_debit_mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/mandate" + } + ], + "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" + } + ] + } + }, + "iban_last4": { + "description": "Last four characters of the IBAN.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "verified_name": { + "description": "Owner's verified full name. Values are verified or provided by iDEAL directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "setup_attempt_payment_method_details_ideal", + "type": "object", + "x-expandableFields": [ + "generated_sepa_debit", + "generated_sepa_debit_mandate" + ] + }, + "setup_attempt_payment_method_details_klarna": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_klarna", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_link": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_link", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_paypal": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_paypal", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_revolut_pay": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_revolut_pay", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_sepa_debit": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_sepa_debit", + "type": "object", + "x-expandableFields": [] + }, + "setup_attempt_payment_method_details_sofort": { + "description": "", + "properties": { + "bank_code": { + "description": "Bank code of bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "bank_name": { + "description": "Name of the bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "bic": { + "description": "Bank Identifier Code of the bank associated with the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "generated_sepa_debit": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "generated_sepa_debit_mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/mandate" + } + ], + "description": "The mandate for the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" + } + ] + } + }, + "iban_last4": { + "description": "Last four characters of the IBAN.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "preferred_language": { + "description": "Preferred language of the Sofort authorization page that the customer is redirected to.\nCan be one of `en`, `de`, `fr`, or `nl`", + "enum": ["de", "en", "fr", "nl"], + "nullable": true, + "type": "string" + }, + "verified_name": { + "description": "Owner's verified full name. Values are verified or provided by Sofort directly\n(if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "setup_attempt_payment_method_details_sofort", + "type": "object", + "x-expandableFields": [ + "generated_sepa_debit", + "generated_sepa_debit_mandate" + ] + }, + "setup_attempt_payment_method_details_us_bank_account": { + "description": "", + "properties": {}, + "title": "setup_attempt_payment_method_details_us_bank_account", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent": { + "description": "A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.\nFor example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment.\nLater, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.\n\nCreate a SetupIntent when you're ready to collect your customer's payment credentials.\nDon't maintain long-lived, unconfirmed SetupIntents because they might not be valid.\nThe SetupIntent transitions through multiple [statuses](https://docs.stripe.com/payments/intents#intent-statuses) as it guides\nyou through the setup process.\n\nSuccessful SetupIntents result in payment credentials that are optimized for future payments.\nFor example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) might need to be run through\n[Strong Customer Authentication](https://docs.stripe.com/strong-customer-authentication) during payment method collection\nto streamline later [off-session payments](https://docs.stripe.com/payments/setup-intents).\nIf you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer),\nit automatically attaches the resulting payment method to that Customer after successful setup.\nWe recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on\nPaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods.\n\nBy using SetupIntents, you can reduce friction for your customers, even as regulations change over time.\n\nRelated guide: [Setup Intents API](https://docs.stripe.com/payments/setup-intents)", + "properties": { + "application": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application" + } + ], + "description": "ID of the Connect application that created the SetupIntent.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application" + } + ] + } + }, + "attach_to_self": { + "description": "If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.\n\nIt can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.", + "type": "boolean" + }, + "automatic_payment_methods": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_flows_automatic_payment_methods_setup_intent" + } + ], + "description": "Settings for dynamic payment methods compatible with this Setup Intent", + "nullable": true + }, + "cancellation_reason": { + "description": "Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`.", + "enum": ["abandoned", "duplicate", "requested_by_customer"], + "nullable": true, + "type": "string" + }, + "client_secret": { + "description": "The client secret of this SetupIntent. Used for client-side retrieval using a publishable key.\n\nThe client secret can be used to complete payment setup from your frontend. It should not be stored, logged, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ], + "description": "ID of the Customer this SetupIntent belongs to, if one exists.\n\nIf present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ] + } + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "flow_directions": { + "description": "Indicates the directions of money movement for which this payment method is intended to be used.\n\nInclude `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.", + "items": { + "enum": ["inbound", "outbound"], + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "last_setup_error": { + "anyOf": [ + { + "$ref": "#/components/schemas/api_errors" + } + ], + "description": "The error encountered in the previous SetupIntent confirmation.", + "nullable": true + }, + "latest_attempt": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/setup_attempt" + } + ], + "description": "The most recent SetupAttempt for this SetupIntent.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/setup_attempt" + } + ] + } + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/mandate" + } + ], + "description": "ID of the multi use Mandate generated by the SetupIntent.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" + } + ] + } + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "next_action": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_next_action" + } + ], + "description": "If present, this property tells you what actions you need to take in order for your customer to continue payment setup.", + "nullable": true + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["setup_intent"], + "type": "string" + }, + "on_behalf_of": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account (if any) for which the setup is intended.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + }, + "payment_method": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "ID of the payment method used with this SetupIntent. If the payment method is `card_present` and isn't a digital wallet, then the [generated_card](https://docs.stripe.com/api/setup_attempts/object#setup_attempt_object-payment_method_details-card_present-generated_card) associated with the `latest_attempt` is attached to the Customer instead.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "payment_method_configuration_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_method_config_biz_payment_method_configuration_details" + } + ], + "description": "Information about the payment method configuration used for this Setup Intent.", + "nullable": true + }, + "payment_method_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options" + } + ], + "description": "Payment method-specific configuration for this SetupIntent.", + "nullable": true + }, + "payment_method_types": { + "description": "The list of payment method types (e.g. card) that this SetupIntent is allowed to set up.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "single_use_mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/mandate" + } + ], + "description": "ID of the single_use Mandate generated by the SetupIntent.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/mandate" + } + ] + } + }, + "status": { + "description": "[Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`.", + "enum": [ + "canceled", + "processing", + "requires_action", + "requires_confirmation", + "requires_payment_method", + "succeeded" + ], + "type": "string" + }, + "usage": { + "description": "Indicates how the payment method is intended to be used in the future.\n\nUse `on_session` if you intend to only reuse the payment method when the customer is in your checkout flow. Use `off_session` if your customer may or may not be in your checkout flow. If not provided, this value defaults to `off_session`.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "created", + "id", + "livemode", + "object", + "payment_method_types", + "status", + "usage" + ], + "title": "SetupIntent", + "type": "object", + "x-expandableFields": [ + "application", + "automatic_payment_methods", + "customer", + "last_setup_error", + "latest_attempt", + "mandate", + "next_action", + "on_behalf_of", + "payment_method", + "payment_method_configuration_details", + "payment_method_options", + "single_use_mandate" + ], + "x-resourceId": "setup_intent" + }, + "setup_intent_next_action": { + "description": "", + "properties": { + "cashapp_handle_redirect_or_display_qr_code": { + "$ref": "#/components/schemas/payment_intent_next_action_cashapp_handle_redirect_or_display_qr_code" + }, + "redirect_to_url": { + "$ref": "#/components/schemas/setup_intent_next_action_redirect_to_url" + }, + "type": { + "description": "Type of the next action to perform, one of `redirect_to_url`, `use_stripe_sdk`, `alipay_handle_redirect`, `oxxo_display_details`, or `verify_with_microdeposits`.", + "maxLength": 5000, + "type": "string" + }, + "use_stripe_sdk": { + "description": "When confirming a SetupIntent with Stripe.js, Stripe.js depends on the contents of this dictionary to invoke authentication flows. The shape of the contents is subject to change and is only intended to be used by Stripe.js.", + "type": "object" + }, + "verify_with_microdeposits": { + "$ref": "#/components/schemas/setup_intent_next_action_verify_with_microdeposits" + } + }, + "required": ["type"], + "title": "SetupIntentNextAction", + "type": "object", + "x-expandableFields": [ + "cashapp_handle_redirect_or_display_qr_code", + "redirect_to_url", + "verify_with_microdeposits" + ] + }, + "setup_intent_next_action_redirect_to_url": { + "description": "", + "properties": { + "return_url": { + "description": "If the customer does not exit their browser while authenticating, they will be redirected to this specified URL after completion.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "url": { + "description": "The URL you must redirect your customer to in order to authenticate.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "SetupIntentNextActionRedirectToUrl", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_next_action_verify_with_microdeposits": { + "description": "", + "properties": { + "arrival_date": { + "description": "The timestamp when the microdeposits are expected to land.", + "format": "unix-time", + "type": "integer" + }, + "hosted_verification_url": { + "description": "The URL for the hosted verification page, which allows customers to verify their bank account.", + "maxLength": 5000, + "type": "string" + }, + "microdeposit_type": { + "description": "The type of the microdeposit sent to the customer. Used to distinguish between different verification methods.", + "enum": ["amounts", "descriptor_code"], + "nullable": true, + "type": "string" + } + }, + "required": ["arrival_date", "hosted_verification_url"], + "title": "SetupIntentNextActionVerifyWithMicrodeposits", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_payment_method_options": { + "description": "", + "properties": { + "acss_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_acss_debit" + }, + { + "$ref": "#/components/schemas/setup_intent_type_specific_payment_method_options_client" + } + ] + }, + "amazon_pay": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_amazon_pay" + }, + { + "$ref": "#/components/schemas/setup_intent_type_specific_payment_method_options_client" + } + ] + }, + "bacs_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_bacs_debit" + }, + { + "$ref": "#/components/schemas/setup_intent_type_specific_payment_method_options_client" + } + ] + }, + "card": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_card" + }, + { + "$ref": "#/components/schemas/setup_intent_type_specific_payment_method_options_client" + } + ] + }, + "card_present": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_card_present" + }, + { + "$ref": "#/components/schemas/setup_intent_type_specific_payment_method_options_client" + } + ] + }, + "link": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_link" + }, + { + "$ref": "#/components/schemas/setup_intent_type_specific_payment_method_options_client" + } + ] + }, + "paypal": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_paypal" + }, + { + "$ref": "#/components/schemas/setup_intent_type_specific_payment_method_options_client" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_sepa_debit" + }, + { + "$ref": "#/components/schemas/setup_intent_type_specific_payment_method_options_client" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_us_bank_account" + }, + { + "$ref": "#/components/schemas/setup_intent_type_specific_payment_method_options_client" + } + ] + } + }, + "title": "SetupIntentPaymentMethodOptions", + "type": "object", + "x-expandableFields": [ + "acss_debit", + "amazon_pay", + "bacs_debit", + "card", + "card_present", + "link", + "paypal", + "sepa_debit", + "us_bank_account" + ] + }, + "setup_intent_payment_method_options_acss_debit": { + "description": "", + "properties": { + "currency": { + "description": "Currency supported by the bank account", + "enum": ["cad", "usd"], + "nullable": true, + "type": "string" + }, + "mandate_options": { + "$ref": "#/components/schemas/setup_intent_payment_method_options_mandate_options_acss_debit" + }, + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_acss_debit", + "type": "object", + "x-expandableFields": ["mandate_options"] + }, + "setup_intent_payment_method_options_amazon_pay": { + "description": "", + "properties": {}, + "title": "setup_intent_payment_method_options_amazon_pay", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_payment_method_options_bacs_debit": { + "description": "", + "properties": { + "mandate_options": { + "$ref": "#/components/schemas/setup_intent_payment_method_options_mandate_options_bacs_debit" + } + }, + "title": "setup_intent_payment_method_options_bacs_debit", + "type": "object", + "x-expandableFields": ["mandate_options"] + }, + "setup_intent_payment_method_options_card": { + "description": "", + "properties": { + "mandate_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/setup_intent_payment_method_options_card_mandate_options" + } + ], + "description": "Configuration options for setting up an eMandate for cards issued in India.", + "nullable": true + }, + "network": { + "description": "Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the setup intent. Can be only set confirm-time.", + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "nullable": true, + "type": "string" + }, + "request_three_d_secure": { + "description": "We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.", + "enum": ["any", "automatic", "challenge"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_card", + "type": "object", + "x-expandableFields": ["mandate_options"] + }, + "setup_intent_payment_method_options_card_mandate_options": { + "description": "", + "properties": { + "amount": { + "description": "Amount to be charged for future payments.", + "type": "integer" + }, + "amount_type": { + "description": "One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.", + "enum": ["fixed", "maximum"], + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "A description of the mandate or subscription that is meant to be displayed to the customer.", + "maxLength": 200, + "nullable": true, + "type": "string" + }, + "end_date": { + "description": "End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "interval": { + "description": "Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.", + "enum": ["day", "month", "sporadic", "week", "year"], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.", + "nullable": true, + "type": "integer" + }, + "reference": { + "description": "Unique identifier for the mandate or subscription.", + "maxLength": 80, + "type": "string" + }, + "start_date": { + "description": "Start date of the mandate or subscription. Start date should not be lesser than yesterday.", + "format": "unix-time", + "type": "integer" + }, + "supported_types": { + "description": "Specifies the type of mandates supported. Possible values are `india`.", + "items": { + "enum": ["india"], + "type": "string" + }, + "nullable": true, + "type": "array" + } + }, + "required": [ + "amount", + "amount_type", + "currency", + "interval", + "reference", + "start_date" + ], + "title": "setup_intent_payment_method_options_card_mandate_options", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_payment_method_options_card_present": { + "description": "", + "properties": {}, + "title": "setup_intent_payment_method_options_card_present", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_payment_method_options_link": { + "description": "", + "properties": {}, + "title": "setup_intent_payment_method_options_link", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_payment_method_options_mandate_options_acss_debit": { + "description": "", + "properties": { + "custom_mandate_url": { + "description": "A URL for custom mandate text", + "maxLength": 5000, + "type": "string" + }, + "default_for": { + "description": "List of Stripe products where this mandate can be selected automatically.", + "items": { + "enum": ["invoice", "subscription"], + "type": "string" + }, + "type": "array" + }, + "interval_description": { + "description": "Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "payment_schedule": { + "description": "Payment schedule for the mandate.", + "enum": ["combined", "interval", "sporadic"], + "nullable": true, + "type": "string" + }, + "transaction_type": { + "description": "Transaction type of the mandate.", + "enum": ["business", "personal"], + "nullable": true, + "type": "string" + } + }, + "title": "setup_intent_payment_method_options_mandate_options_acss_debit", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_payment_method_options_mandate_options_bacs_debit": { + "description": "", + "properties": {}, + "title": "setup_intent_payment_method_options_mandate_options_bacs_debit", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_payment_method_options_mandate_options_sepa_debit": { + "description": "", + "properties": {}, + "title": "setup_intent_payment_method_options_mandate_options_sepa_debit", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_payment_method_options_paypal": { + "description": "", + "properties": { + "billing_agreement_id": { + "description": "The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "setup_intent_payment_method_options_paypal", + "type": "object", + "x-expandableFields": [] + }, + "setup_intent_payment_method_options_sepa_debit": { + "description": "", + "properties": { + "mandate_options": { + "$ref": "#/components/schemas/setup_intent_payment_method_options_mandate_options_sepa_debit" + } + }, + "title": "setup_intent_payment_method_options_sepa_debit", + "type": "object", + "x-expandableFields": ["mandate_options"] + }, + "setup_intent_payment_method_options_us_bank_account": { + "description": "", + "properties": { + "financial_connections": { + "$ref": "#/components/schemas/linked_account_options_us_bank_account" + }, + "mandate_options": { + "$ref": "#/components/schemas/payment_method_options_us_bank_account_mandate_options" + }, + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_us_bank_account", + "type": "object", + "x-expandableFields": ["financial_connections", "mandate_options"] + }, + "setup_intent_type_specific_payment_method_options_client": { + "description": "", + "properties": { + "verification_method": { + "description": "Bank account verification method.", + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "SetupIntentTypeSpecificPaymentMethodOptionsClient", + "type": "object", + "x-expandableFields": [] + }, + "shipping": { + "description": "", + "properties": { + "address": { + "$ref": "#/components/schemas/address" + }, + "carrier": { + "description": "The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "name": { + "description": "Recipient name.", + "maxLength": 5000, + "type": "string" + }, + "phone": { + "description": "Recipient phone (including extension).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "tracking_number": { + "description": "The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "Shipping", + "type": "object", + "x-expandableFields": ["address"] + }, + "shipping_rate": { + "description": "Shipping rates describe the price of shipping presented to your customers and\napplied to a purchase. For more information, see [Charge for shipping](https://stripe.com/docs/payments/during-payment/charge-shipping).", + "properties": { + "active": { + "description": "Whether the shipping rate can be used for new purchases. Defaults to `true`.", + "type": "boolean" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "delivery_estimate": { + "anyOf": [ + { + "$ref": "#/components/schemas/shipping_rate_delivery_estimate" + } + ], + "description": "The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.", + "nullable": true + }, + "display_name": { + "description": "The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "fixed_amount": { + "$ref": "#/components/schemas/shipping_rate_fixed_amount" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["shipping_rate"], + "type": "string" + }, + "tax_behavior": { + "description": "Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.", + "enum": ["exclusive", "inclusive", "unspecified"], + "nullable": true, + "type": "string" + }, + "tax_code": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_code" + } + ], + "description": "A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_code" + } + ] + } + }, + "type": { + "description": "The type of calculation to use on the shipping rate.", + "enum": ["fixed_amount"], + "type": "string" + } + }, + "required": [ + "active", + "created", + "id", + "livemode", + "metadata", + "object", + "type" + ], + "title": "ShippingRate", + "type": "object", + "x-expandableFields": ["delivery_estimate", "fixed_amount", "tax_code"], + "x-resourceId": "shipping_rate" + }, + "shipping_rate_currency_option": { + "description": "", + "properties": { + "amount": { + "description": "A non-negative integer in cents representing how much to charge.", + "type": "integer" + }, + "tax_behavior": { + "description": "Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.", + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + } + }, + "required": ["amount", "tax_behavior"], + "title": "ShippingRateCurrencyOption", + "type": "object", + "x-expandableFields": [] + }, + "shipping_rate_delivery_estimate": { + "description": "", + "properties": { + "maximum": { + "anyOf": [ + { + "$ref": "#/components/schemas/shipping_rate_delivery_estimate_bound" + } + ], + "description": "The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.", + "nullable": true + }, + "minimum": { + "anyOf": [ + { + "$ref": "#/components/schemas/shipping_rate_delivery_estimate_bound" + } + ], + "description": "The lower bound of the estimated range. If empty, represents no lower bound.", + "nullable": true + } + }, + "title": "ShippingRateDeliveryEstimate", + "type": "object", + "x-expandableFields": ["maximum", "minimum"] + }, + "shipping_rate_delivery_estimate_bound": { + "description": "", + "properties": { + "unit": { + "description": "A unit of time.", + "enum": ["business_day", "day", "hour", "month", "week"], + "type": "string" + }, + "value": { + "description": "Must be greater than 0.", + "type": "integer" + } + }, + "required": ["unit", "value"], + "title": "ShippingRateDeliveryEstimateBound", + "type": "object", + "x-expandableFields": [] + }, + "shipping_rate_fixed_amount": { + "description": "", + "properties": { + "amount": { + "description": "A non-negative integer in cents representing how much to charge.", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "currency_options": { + "additionalProperties": { + "$ref": "#/components/schemas/shipping_rate_currency_option" + }, + "description": "Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).", + "type": "object" + } + }, + "required": ["amount", "currency"], + "title": "ShippingRateFixedAmount", + "type": "object", + "x-expandableFields": ["currency_options"] + }, + "sigma_scheduled_query_run_error": { + "description": "", + "properties": { + "message": { + "description": "Information about the run failure.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["message"], + "title": "SigmaScheduledQueryRunError", + "type": "object", + "x-expandableFields": [] + }, + "source": { + "description": "`Source` objects allow you to accept a variety of payment methods. They\nrepresent a customer's payment instrument, and can be used with the Stripe API\njust like a `Card` object: once chargeable, they can be charged, or can be\nattached to customers.\n\nStripe doesn't recommend using the deprecated [Sources API](https://stripe.com/docs/api/sources).\nWe recommend that you adopt the [PaymentMethods API](https://stripe.com/docs/api/payment_methods).\nThis newer API provides access to our latest features and payment method types.\n\nRelated guides: [Sources API](https://stripe.com/docs/sources) and [Sources & Customers](https://stripe.com/docs/sources/customers).", + "properties": { + "ach_credit_transfer": { + "$ref": "#/components/schemas/source_type_ach_credit_transfer" + }, + "ach_debit": { + "$ref": "#/components/schemas/source_type_ach_debit" + }, + "acss_debit": { + "$ref": "#/components/schemas/source_type_acss_debit" + }, + "alipay": { + "$ref": "#/components/schemas/source_type_alipay" + }, + "amount": { + "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources.", + "nullable": true, + "type": "integer" + }, + "au_becs_debit": { + "$ref": "#/components/schemas/source_type_au_becs_debit" + }, + "bancontact": { + "$ref": "#/components/schemas/source_type_bancontact" + }, + "card": { + "$ref": "#/components/schemas/source_type_card" + }, + "card_present": { + "$ref": "#/components/schemas/source_type_card_present" + }, + "client_secret": { + "description": "The client secret of the source. Used for client-side retrieval using a publishable key.", + "maxLength": 5000, + "type": "string" + }, + "code_verification": { + "$ref": "#/components/schemas/source_code_verification_flow" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready. Required for `single_use` sources.", + "nullable": true, + "type": "string" + }, + "customer": { + "description": "The ID of the customer to which this source is attached. This will not be present when the source has not been attached to a customer.", + "maxLength": 5000, + "type": "string" + }, + "eps": { + "$ref": "#/components/schemas/source_type_eps" + }, + "flow": { + "description": "The authentication `flow` of the source. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`.", + "maxLength": 5000, + "type": "string" + }, + "giropay": { + "$ref": "#/components/schemas/source_type_giropay" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "ideal": { + "$ref": "#/components/schemas/source_type_ideal" + }, + "klarna": { + "$ref": "#/components/schemas/source_type_klarna" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "multibanco": { + "$ref": "#/components/schemas/source_type_multibanco" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["source"], + "type": "string" + }, + "owner": { + "anyOf": [ + { + "$ref": "#/components/schemas/source_owner" + } + ], + "description": "Information about the owner of the payment instrument that may be used or required by particular source types.", + "nullable": true + }, + "p24": { + "$ref": "#/components/schemas/source_type_p24" + }, + "receiver": { + "$ref": "#/components/schemas/source_receiver_flow" + }, + "redirect": { + "$ref": "#/components/schemas/source_redirect_flow" + }, + "sepa_debit": { + "$ref": "#/components/schemas/source_type_sepa_debit" + }, + "sofort": { + "$ref": "#/components/schemas/source_type_sofort" + }, + "source_order": { + "$ref": "#/components/schemas/source_order" + }, + "statement_descriptor": { + "description": "Extra information about a source. This will appear on your customer's statement every time you charge the source.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "status": { + "description": "The status of the source, one of `canceled`, `chargeable`, `consumed`, `failed`, or `pending`. Only `chargeable` sources can be used to create a charge.", + "maxLength": 5000, + "type": "string" + }, + "three_d_secure": { + "$ref": "#/components/schemas/source_type_three_d_secure" + }, + "type": { + "description": "The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used.", + "enum": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "alipay", + "au_becs_debit", + "bancontact", + "card", + "card_present", + "eps", + "giropay", + "ideal", + "klarna", + "multibanco", + "p24", + "sepa_debit", + "sofort", + "three_d_secure", + "wechat" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "usage": { + "description": "Either `reusable` or `single_use`. Whether this source should be reusable or not. Some source types may or may not be reusable by construction, while others may leave the option at creation. If an incompatible value is passed, an error will be returned.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "wechat": { + "$ref": "#/components/schemas/source_type_wechat" + } + }, + "required": [ + "client_secret", + "created", + "flow", + "id", + "livemode", + "object", + "status", + "type" + ], + "title": "Source", + "type": "object", + "x-expandableFields": [ + "code_verification", + "owner", + "receiver", + "redirect", + "source_order" + ], + "x-resourceId": "source" + }, + "source_code_verification_flow": { + "description": "", + "properties": { + "attempts_remaining": { + "description": "The number of attempts remaining to authenticate the source object with a verification code.", + "type": "integer" + }, + "status": { + "description": "The status of the code verification, either `pending` (awaiting verification, `attempts_remaining` should be greater than 0), `succeeded` (successful verification) or `failed` (failed verification, cannot be verified anymore as `attempts_remaining` should be 0).", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["attempts_remaining", "status"], + "title": "SourceCodeVerificationFlow", + "type": "object", + "x-expandableFields": [] + }, + "source_mandate_notification": { + "description": "Source mandate notifications should be created when a notification related to\na source mandate must be sent to the payer. They will trigger a webhook or\ndeliver an email to the customer.", + "properties": { + "acss_debit": { + "$ref": "#/components/schemas/source_mandate_notification_acss_debit_data" + }, + "amount": { + "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the amount associated with the mandate notification. The amount is expressed in the currency of the underlying source. Required if the notification type is `debit_initiated`.", + "nullable": true, + "type": "integer" + }, + "bacs_debit": { + "$ref": "#/components/schemas/source_mandate_notification_bacs_debit_data" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["source_mandate_notification"], + "type": "string" + }, + "reason": { + "description": "The reason of the mandate notification. Valid reasons are `mandate_confirmed` or `debit_initiated`.", + "maxLength": 5000, + "type": "string" + }, + "sepa_debit": { + "$ref": "#/components/schemas/source_mandate_notification_sepa_debit_data" + }, + "source": { + "$ref": "#/components/schemas/source" + }, + "status": { + "description": "The status of the mandate notification. Valid statuses are `pending` or `submitted`.", + "maxLength": 5000, + "type": "string" + }, + "type": { + "description": "The type of source this mandate notification is attached to. Should be the source type identifier code for the payment method, such as `three_d_secure`.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "created", + "id", + "livemode", + "object", + "reason", + "source", + "status", + "type" + ], + "title": "SourceMandateNotification", + "type": "object", + "x-expandableFields": [ + "acss_debit", + "bacs_debit", + "sepa_debit", + "source" + ], + "x-resourceId": "source_mandate_notification" + }, + "source_mandate_notification_acss_debit_data": { + "description": "", + "properties": { + "statement_descriptor": { + "description": "The statement descriptor associate with the debit.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "SourceMandateNotificationAcssDebitData", + "type": "object", + "x-expandableFields": [] + }, + "source_mandate_notification_bacs_debit_data": { + "description": "", + "properties": { + "last4": { + "description": "Last 4 digits of the account number associated with the debit.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "SourceMandateNotificationBacsDebitData", + "type": "object", + "x-expandableFields": [] + }, + "source_mandate_notification_sepa_debit_data": { + "description": "", + "properties": { + "creditor_identifier": { + "description": "SEPA creditor ID.", + "maxLength": 5000, + "type": "string" + }, + "last4": { + "description": "Last 4 digits of the account number associated with the debit.", + "maxLength": 5000, + "type": "string" + }, + "mandate_reference": { + "description": "Mandate reference associated with the debit.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "SourceMandateNotificationSepaDebitData", + "type": "object", + "x-expandableFields": [] + }, + "source_order": { + "description": "", + "properties": { + "amount": { + "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount for the order.", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "email": { + "description": "The email address of the customer placing the order.", + "maxLength": 5000, + "type": "string" + }, + "items": { + "description": "List of items constituting the order.", + "items": { + "$ref": "#/components/schemas/source_order_item" + }, + "nullable": true, + "type": "array" + }, + "shipping": { + "$ref": "#/components/schemas/shipping" + } + }, + "required": ["amount", "currency"], + "title": "SourceOrder", + "type": "object", + "x-expandableFields": ["items", "shipping"] + }, + "source_order_item": { + "description": "", + "properties": { + "amount": { + "description": "The amount (price) for this order item.", + "nullable": true, + "type": "integer" + }, + "currency": { + "description": "This currency of this order item. Required when `amount` is present.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "description": { + "description": "Human-readable description for this order item.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "parent": { + "description": "The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "quantity": { + "description": "The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.", + "type": "integer" + }, + "type": { + "description": "The type of this order item. Must be `sku`, `tax`, or `shipping`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "SourceOrderItem", + "type": "object", + "x-expandableFields": [] + }, + "source_owner": { + "description": "", + "properties": { + "address": { + "anyOf": [ + { + "$ref": "#/components/schemas/address" + } + ], + "description": "Owner's address.", + "nullable": true + }, + "email": { + "description": "Owner's email address.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "name": { + "description": "Owner's full name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "phone": { + "description": "Owner's phone number (including extension).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "verified_address": { + "anyOf": [ + { + "$ref": "#/components/schemas/address" + } + ], + "description": "Verified owner's address. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "nullable": true + }, + "verified_email": { + "description": "Verified owner's email address. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "verified_name": { + "description": "Verified owner's full name. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "verified_phone": { + "description": "Verified owner's phone number (including extension). Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "SourceOwner", + "type": "object", + "x-expandableFields": ["address", "verified_address"] + }, + "source_receiver_flow": { + "description": "", + "properties": { + "address": { + "description": "The address of the receiver source. This is the value that should be communicated to the customer to send their funds to.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "amount_charged": { + "description": "The total amount that was moved to your balance. This is almost always equal to the amount charged. In rare cases when customers deposit excess funds and we are unable to refund those, those funds get moved to your balance and show up in amount_charged as well. The amount charged is expressed in the source's currency.", + "type": "integer" + }, + "amount_received": { + "description": "The total amount received by the receiver source. `amount_received = amount_returned + amount_charged` should be true for consumed sources unless customers deposit excess funds. The amount received is expressed in the source's currency.", + "type": "integer" + }, + "amount_returned": { + "description": "The total amount that was returned to the customer. The amount returned is expressed in the source's currency.", + "type": "integer" + }, + "refund_attributes_method": { + "description": "Type of refund attribute method, one of `email`, `manual`, or `none`.", + "maxLength": 5000, + "type": "string" + }, + "refund_attributes_status": { + "description": "Type of refund attribute status, one of `missing`, `requested`, or `available`.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "amount_charged", + "amount_received", + "amount_returned", + "refund_attributes_method", + "refund_attributes_status" + ], + "title": "SourceReceiverFlow", + "type": "object", + "x-expandableFields": [] + }, + "source_redirect_flow": { + "description": "", + "properties": { + "failure_reason": { + "description": "The failure reason for the redirect, either `user_abort` (the customer aborted or dropped out of the redirect flow), `declined` (the authentication failed or the transaction was declined), or `processing_error` (the redirect failed due to a technical error). Present only if the redirect status is `failed`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "return_url": { + "description": "The URL you provide to redirect the customer to after they authenticated their payment.", + "maxLength": 5000, + "type": "string" + }, + "status": { + "description": "The status of the redirect, either `pending` (ready to be used by your customer to authenticate the transaction), `succeeded` (succesful authentication, cannot be reused) or `not_required` (redirect should not be used) or `failed` (failed authentication, cannot be reused).", + "maxLength": 5000, + "type": "string" + }, + "url": { + "description": "The URL provided to you to redirect a customer to as part of a `redirect` authentication flow.", + "maxLength": 2048, + "type": "string" + } + }, + "required": ["return_url", "status", "url"], + "title": "SourceRedirectFlow", + "type": "object", + "x-expandableFields": [] + }, + "source_transaction": { + "description": "Some payment methods have no required amount that a customer must send.\nCustomers can be instructed to send any amount, and it can be made up of\nmultiple transactions. As such, sources can have multiple associated\ntransactions.", + "properties": { + "ach_credit_transfer": { + "$ref": "#/components/schemas/source_transaction_ach_credit_transfer_data" + }, + "amount": { + "description": "A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the amount your customer has pushed to the receiver.", + "type": "integer" + }, + "chf_credit_transfer": { + "$ref": "#/components/schemas/source_transaction_chf_credit_transfer_data" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "gbp_credit_transfer": { + "$ref": "#/components/schemas/source_transaction_gbp_credit_transfer_data" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["source_transaction"], + "type": "string" + }, + "paper_check": { + "$ref": "#/components/schemas/source_transaction_paper_check_data" + }, + "sepa_credit_transfer": { + "$ref": "#/components/schemas/source_transaction_sepa_credit_transfer_data" + }, + "source": { + "description": "The ID of the source this transaction is attached to.", + "maxLength": 5000, + "type": "string" + }, + "status": { + "description": "The status of the transaction, one of `succeeded`, `pending`, or `failed`.", + "maxLength": 5000, + "type": "string" + }, + "type": { + "description": "The type of source this transaction is attached to.", + "enum": [ + "ach_credit_transfer", + "ach_debit", + "alipay", + "bancontact", + "card", + "card_present", + "eps", + "giropay", + "ideal", + "klarna", + "multibanco", + "p24", + "sepa_debit", + "sofort", + "three_d_secure", + "wechat" + ], + "type": "string" + } + }, + "required": [ + "amount", + "created", + "currency", + "id", + "livemode", + "object", + "source", + "status", + "type" + ], + "title": "SourceTransaction", + "type": "object", + "x-expandableFields": [ + "ach_credit_transfer", + "chf_credit_transfer", + "gbp_credit_transfer", + "paper_check", + "sepa_credit_transfer" + ], + "x-resourceId": "source_transaction" + }, + "source_transaction_ach_credit_transfer_data": { + "description": "", + "properties": { + "customer_data": { + "description": "Customer data associated with the transfer.", + "maxLength": 5000, + "type": "string" + }, + "fingerprint": { + "description": "Bank account fingerprint associated with the transfer.", + "maxLength": 5000, + "type": "string" + }, + "last4": { + "description": "Last 4 digits of the account number associated with the transfer.", + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "description": "Routing number associated with the transfer.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "SourceTransactionAchCreditTransferData", + "type": "object", + "x-expandableFields": [] + }, + "source_transaction_chf_credit_transfer_data": { + "description": "", + "properties": { + "reference": { + "description": "Reference associated with the transfer.", + "maxLength": 5000, + "type": "string" + }, + "sender_address_country": { + "description": "Sender's country address.", + "maxLength": 5000, + "type": "string" + }, + "sender_address_line1": { + "description": "Sender's line 1 address.", + "maxLength": 5000, + "type": "string" + }, + "sender_iban": { + "description": "Sender's bank account IBAN.", + "maxLength": 5000, + "type": "string" + }, + "sender_name": { + "description": "Sender's name.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "SourceTransactionChfCreditTransferData", + "type": "object", + "x-expandableFields": [] + }, + "source_transaction_gbp_credit_transfer_data": { + "description": "", + "properties": { + "fingerprint": { + "description": "Bank account fingerprint associated with the Stripe owned bank account receiving the transfer.", + "maxLength": 5000, + "type": "string" + }, + "funding_method": { + "description": "The credit transfer rails the sender used to push this transfer. The possible rails are: Faster Payments, BACS, CHAPS, and wire transfers. Currently only Faster Payments is supported.", + "maxLength": 5000, + "type": "string" + }, + "last4": { + "description": "Last 4 digits of sender account number associated with the transfer.", + "maxLength": 5000, + "type": "string" + }, + "reference": { + "description": "Sender entered arbitrary information about the transfer.", + "maxLength": 5000, + "type": "string" + }, + "sender_account_number": { + "description": "Sender account number associated with the transfer.", + "maxLength": 5000, + "type": "string" + }, + "sender_name": { + "description": "Sender name associated with the transfer.", + "maxLength": 5000, + "type": "string" + }, + "sender_sort_code": { + "description": "Sender sort code associated with the transfer.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "SourceTransactionGbpCreditTransferData", + "type": "object", + "x-expandableFields": [] + }, + "source_transaction_paper_check_data": { + "description": "", + "properties": { + "available_at": { + "description": "Time at which the deposited funds will be available for use. Measured in seconds since the Unix epoch.", + "maxLength": 5000, + "type": "string" + }, + "invoices": { + "description": "Comma-separated list of invoice IDs associated with the paper check.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "SourceTransactionPaperCheckData", + "type": "object", + "x-expandableFields": [] + }, + "source_transaction_sepa_credit_transfer_data": { + "description": "", + "properties": { + "reference": { + "description": "Reference associated with the transfer.", + "maxLength": 5000, + "type": "string" + }, + "sender_iban": { + "description": "Sender's bank account IBAN.", + "maxLength": 5000, + "type": "string" + }, + "sender_name": { + "description": "Sender's name.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "SourceTransactionSepaCreditTransferData", + "type": "object", + "x-expandableFields": [] + }, + "source_type_ach_credit_transfer": { + "properties": { + "account_number": { + "nullable": true, + "type": "string" + }, + "bank_name": { + "nullable": true, + "type": "string" + }, + "fingerprint": { + "nullable": true, + "type": "string" + }, + "refund_account_holder_name": { + "nullable": true, + "type": "string" + }, + "refund_account_holder_type": { + "nullable": true, + "type": "string" + }, + "refund_routing_number": { + "nullable": true, + "type": "string" + }, + "routing_number": { + "nullable": true, + "type": "string" + }, + "swift_code": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_ach_debit": { + "properties": { + "bank_name": { + "nullable": true, + "type": "string" + }, + "country": { + "nullable": true, + "type": "string" + }, + "fingerprint": { + "nullable": true, + "type": "string" + }, + "last4": { + "nullable": true, + "type": "string" + }, + "routing_number": { + "nullable": true, + "type": "string" + }, + "type": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_acss_debit": { + "properties": { + "bank_address_city": { + "nullable": true, + "type": "string" + }, + "bank_address_line_1": { + "nullable": true, + "type": "string" + }, + "bank_address_line_2": { + "nullable": true, + "type": "string" + }, + "bank_address_postal_code": { + "nullable": true, + "type": "string" + }, + "bank_name": { + "nullable": true, + "type": "string" + }, + "category": { + "nullable": true, + "type": "string" + }, + "country": { + "nullable": true, + "type": "string" + }, + "fingerprint": { + "nullable": true, + "type": "string" + }, + "last4": { + "nullable": true, + "type": "string" + }, + "routing_number": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_alipay": { + "properties": { + "data_string": { + "nullable": true, + "type": "string" + }, + "native_url": { + "nullable": true, + "type": "string" + }, + "statement_descriptor": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_au_becs_debit": { + "properties": { + "bsb_number": { + "nullable": true, + "type": "string" + }, + "fingerprint": { + "nullable": true, + "type": "string" + }, + "last4": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_bancontact": { + "properties": { + "bank_code": { + "nullable": true, + "type": "string" + }, + "bank_name": { + "nullable": true, + "type": "string" + }, + "bic": { + "nullable": true, + "type": "string" + }, + "iban_last4": { + "nullable": true, + "type": "string" + }, + "preferred_language": { + "nullable": true, + "type": "string" + }, + "statement_descriptor": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_card": { + "properties": { + "address_line1_check": { + "nullable": true, + "type": "string" + }, + "address_zip_check": { + "nullable": true, + "type": "string" + }, + "brand": { + "nullable": true, + "type": "string" + }, + "country": { + "nullable": true, + "type": "string" + }, + "cvc_check": { + "nullable": true, + "type": "string" + }, + "dynamic_last4": { + "nullable": true, + "type": "string" + }, + "exp_month": { + "nullable": true, + "type": "integer" + }, + "exp_year": { + "nullable": true, + "type": "integer" + }, + "fingerprint": { + "type": "string" + }, + "funding": { + "nullable": true, + "type": "string" + }, + "last4": { + "nullable": true, + "type": "string" + }, + "name": { + "nullable": true, + "type": "string" + }, + "three_d_secure": { + "type": "string" + }, + "tokenization_method": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_card_present": { + "properties": { + "application_cryptogram": { + "type": "string" + }, + "application_preferred_name": { + "type": "string" + }, + "authorization_code": { + "nullable": true, + "type": "string" + }, + "authorization_response_code": { + "type": "string" + }, + "brand": { + "nullable": true, + "type": "string" + }, + "country": { + "nullable": true, + "type": "string" + }, + "cvm_type": { + "type": "string" + }, + "data_type": { + "nullable": true, + "type": "string" + }, + "dedicated_file_name": { + "type": "string" + }, + "emv_auth_data": { + "type": "string" + }, + "evidence_customer_signature": { + "nullable": true, + "type": "string" + }, + "evidence_transaction_certificate": { + "nullable": true, + "type": "string" + }, + "exp_month": { + "nullable": true, + "type": "integer" + }, + "exp_year": { + "nullable": true, + "type": "integer" + }, + "fingerprint": { + "type": "string" + }, + "funding": { + "nullable": true, + "type": "string" + }, + "last4": { + "nullable": true, + "type": "string" + }, + "pos_device_id": { + "nullable": true, + "type": "string" + }, + "pos_entry_mode": { + "type": "string" + }, + "read_method": { + "nullable": true, + "type": "string" + }, + "reader": { + "nullable": true, + "type": "string" + }, + "terminal_verification_results": { + "type": "string" + }, + "transaction_status_information": { + "type": "string" + } + }, + "type": "object" + }, + "source_type_eps": { + "properties": { + "reference": { + "nullable": true, + "type": "string" + }, + "statement_descriptor": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_giropay": { + "properties": { + "bank_code": { + "nullable": true, + "type": "string" + }, + "bank_name": { + "nullable": true, + "type": "string" + }, + "bic": { + "nullable": true, + "type": "string" + }, + "statement_descriptor": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_ideal": { + "properties": { + "bank": { + "nullable": true, + "type": "string" + }, + "bic": { + "nullable": true, + "type": "string" + }, + "iban_last4": { + "nullable": true, + "type": "string" + }, + "statement_descriptor": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_klarna": { + "properties": { + "background_image_url": { + "type": "string" + }, + "client_token": { + "nullable": true, + "type": "string" + }, + "first_name": { + "type": "string" + }, + "last_name": { + "type": "string" + }, + "locale": { + "type": "string" + }, + "logo_url": { + "type": "string" + }, + "page_title": { + "type": "string" + }, + "pay_later_asset_urls_descriptive": { + "type": "string" + }, + "pay_later_asset_urls_standard": { + "type": "string" + }, + "pay_later_name": { + "type": "string" + }, + "pay_later_redirect_url": { + "type": "string" + }, + "pay_now_asset_urls_descriptive": { + "type": "string" + }, + "pay_now_asset_urls_standard": { + "type": "string" + }, + "pay_now_name": { + "type": "string" + }, + "pay_now_redirect_url": { + "type": "string" + }, + "pay_over_time_asset_urls_descriptive": { + "type": "string" + }, + "pay_over_time_asset_urls_standard": { + "type": "string" + }, + "pay_over_time_name": { + "type": "string" + }, + "pay_over_time_redirect_url": { + "type": "string" + }, + "payment_method_categories": { + "type": "string" + }, + "purchase_country": { + "type": "string" + }, + "purchase_type": { + "type": "string" + }, + "redirect_url": { + "type": "string" + }, + "shipping_delay": { + "type": "integer" + }, + "shipping_first_name": { + "type": "string" + }, + "shipping_last_name": { + "type": "string" + } + }, + "type": "object" + }, + "source_type_multibanco": { + "properties": { + "entity": { + "nullable": true, + "type": "string" + }, + "reference": { + "nullable": true, + "type": "string" + }, + "refund_account_holder_address_city": { + "nullable": true, + "type": "string" + }, + "refund_account_holder_address_country": { + "nullable": true, + "type": "string" + }, + "refund_account_holder_address_line1": { + "nullable": true, + "type": "string" + }, + "refund_account_holder_address_line2": { + "nullable": true, + "type": "string" + }, + "refund_account_holder_address_postal_code": { + "nullable": true, + "type": "string" + }, + "refund_account_holder_address_state": { + "nullable": true, + "type": "string" + }, + "refund_account_holder_name": { + "nullable": true, + "type": "string" + }, + "refund_iban": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_p24": { + "properties": { + "reference": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_sepa_debit": { + "properties": { + "bank_code": { + "nullable": true, + "type": "string" + }, + "branch_code": { + "nullable": true, + "type": "string" + }, + "country": { + "nullable": true, + "type": "string" + }, + "fingerprint": { + "nullable": true, + "type": "string" + }, + "last4": { + "nullable": true, + "type": "string" + }, + "mandate_reference": { + "nullable": true, + "type": "string" + }, + "mandate_url": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_sofort": { + "properties": { + "bank_code": { + "nullable": true, + "type": "string" + }, + "bank_name": { + "nullable": true, + "type": "string" + }, + "bic": { + "nullable": true, + "type": "string" + }, + "country": { + "nullable": true, + "type": "string" + }, + "iban_last4": { + "nullable": true, + "type": "string" + }, + "preferred_language": { + "nullable": true, + "type": "string" + }, + "statement_descriptor": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_three_d_secure": { + "properties": { + "address_line1_check": { + "nullable": true, + "type": "string" + }, + "address_zip_check": { + "nullable": true, + "type": "string" + }, + "authenticated": { + "nullable": true, + "type": "boolean" + }, + "brand": { + "nullable": true, + "type": "string" + }, + "card": { + "nullable": true, + "type": "string" + }, + "country": { + "nullable": true, + "type": "string" + }, + "customer": { + "nullable": true, + "type": "string" + }, + "cvc_check": { + "nullable": true, + "type": "string" + }, + "dynamic_last4": { + "nullable": true, + "type": "string" + }, + "exp_month": { + "nullable": true, + "type": "integer" + }, + "exp_year": { + "nullable": true, + "type": "integer" + }, + "fingerprint": { + "type": "string" + }, + "funding": { + "nullable": true, + "type": "string" + }, + "last4": { + "nullable": true, + "type": "string" + }, + "name": { + "nullable": true, + "type": "string" + }, + "three_d_secure": { + "type": "string" + }, + "tokenization_method": { + "nullable": true, + "type": "string" + } + }, + "type": "object" + }, + "source_type_wechat": { + "properties": { + "prepay_id": { + "type": "string" + }, + "qr_code_url": { + "nullable": true, + "type": "string" + }, + "statement_descriptor": { + "type": "string" + } + }, + "type": "object" + }, + "subscription": { + "description": "Subscriptions allow you to charge a customer on a recurring basis.\n\nRelated guide: [Creating subscriptions](https://stripe.com/docs/billing/subscriptions/creating)", + "properties": { + "application": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" + } + ], + "description": "ID of the Connect Application that created the subscription.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" + } + ] + } + }, + "application_fee_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account.", + "nullable": true, + "type": "number" + }, + "automatic_tax": { + "$ref": "#/components/schemas/subscription_automatic_tax" + }, + "billing_cycle_anchor": { + "description": "The reference point that aligns future [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle) dates. It sets the day of week for `week` intervals, the day of month for `month` and `year` intervals, and the month of year for `year` intervals. The timestamp is in UTC format.", + "format": "unix-time", + "type": "integer" + }, + "billing_cycle_anchor_config": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscriptions_resource_billing_cycle_anchor_config" + } + ], + "description": "The fixed values used to calculate the `billing_cycle_anchor`.", + "nullable": true + }, + "billing_thresholds": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_billing_thresholds" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period", + "nullable": true + }, + "cancel_at": { + "description": "A date in the future at which the subscription will automatically get canceled", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "cancel_at_period_end": { + "description": "Whether this subscription will (if `status=active`) or did (if `status=canceled`) cancel at the end of the current billing period.", + "type": "boolean" + }, + "canceled_at": { + "description": "If the subscription has been canceled, the date of that cancellation. If the subscription was canceled with `cancel_at_period_end`, `canceled_at` will reflect the time of the most recent update request, not the end of the subscription period when the subscription is automatically moved to a canceled state.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "cancellation_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/cancellation_details" + } + ], + "description": "Details about why this subscription was cancelled", + "nullable": true + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "current_period_end": { + "description": "End of the current period that the subscription has been invoiced for. At the end of this period, a new invoice will be created.", + "format": "unix-time", + "type": "integer" + }, + "current_period_start": { + "description": "Start of the current period that the subscription has been invoiced for.", + "format": "unix-time", + "type": "integer" + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ], + "description": "ID of the customer who owns the subscription.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ] + } + }, + "days_until_due": { + "description": "Number of days a customer has to pay invoices generated by this subscription. This value will be `null` for subscriptions where `collection_method=charge_automatically`.", + "nullable": true, + "type": "integer" + }, + "default_payment_method": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "default_source": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/source" + } + ], + "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/source" + } + ] + }, + "x-stripeBypassValidation": true + }, + "default_tax_rates": { + "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription.", + "items": { + "$ref": "#/components/schemas/tax_rate" + }, + "nullable": true, + "type": "array" + }, + "description": { + "description": "The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.", + "maxLength": 500, + "nullable": true, + "type": "string" + }, + "discount": { + "anyOf": [ + { + "$ref": "#/components/schemas/discount" + } + ], + "description": "Describes the current discount applied to this subscription, if there is one. When billing, a discount applied to a subscription overrides a discount applied on a customer-wide basis. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "nullable": true + }, + "discounts": { + "description": "The discounts applied to the subscription. Subscription item discounts are applied before subscription discounts. Use `expand[]=discounts` to expand each discount.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/discount" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/discount" + } + ] + } + }, + "type": "array" + }, + "ended_at": { + "description": "If the subscription has ended, the date the subscription ended.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "invoice_settings": { + "$ref": "#/components/schemas/subscriptions_resource_subscription_invoice_settings" + }, + "items": { + "description": "List of subscription items, each with an attached price.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/subscription_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SubscriptionItemList", + "type": "object", + "x-expandableFields": ["data"] + }, + "latest_invoice": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/invoice" + } + ], + "description": "The most recent invoice this subscription has generated.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/invoice" + } + ] + } + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "next_pending_invoice_item_invoice": { + "description": "Specifies the approximate timestamp on which any pending invoice items will be billed according to the schedule provided at `pending_invoice_item_interval`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["subscription"], + "type": "string" + }, + "on_behalf_of": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account (if any) the charge was made on behalf of for charges associated with this subscription. See the Connect documentation for details.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + }, + "pause_collection": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscriptions_resource_pause_collection" + } + ], + "description": "If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](/billing/subscriptions/pause-payment).", + "nullable": true + }, + "payment_settings": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscriptions_resource_payment_settings" + } + ], + "description": "Payment settings passed on to invoices created by the subscription.", + "nullable": true + }, + "pending_invoice_item_interval": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_pending_invoice_item_interval" + } + ], + "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.", + "nullable": true + }, + "pending_setup_intent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/setup_intent" + } + ], + "description": "You can use this [SetupIntent](https://stripe.com/docs/api/setup_intents) to collect user authentication when creating a subscription without immediate payment or updating a subscription's payment method, allowing you to optimize for off-session payments. Learn more in the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication#scenario-2).", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/setup_intent" + } + ] + } + }, + "pending_update": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscriptions_resource_pending_update" + } + ], + "description": "If specified, [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates) that will be applied to the subscription once the `latest_invoice` has been paid.", + "nullable": true + }, + "schedule": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/subscription_schedule" + } + ], + "description": "The schedule attached to the subscription", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/subscription_schedule" + } + ] + } + }, + "start_date": { + "description": "Date when the subscription was first created. The date might differ from the `created` date due to backdating.", + "format": "unix-time", + "type": "integer" + }, + "status": { + "description": "Possible values are `incomplete`, `incomplete_expired`, `trialing`, `active`, `past_due`, `canceled`, `unpaid`, or `paused`. \n\nFor `collection_method=charge_automatically` a subscription moves into `incomplete` if the initial payment attempt fails. A subscription in this status can only have metadata and default_source updated. Once the first invoice is paid, the subscription moves into an `active` status. If the first invoice is not paid within 23 hours, the subscription transitions to `incomplete_expired`. This is a terminal status, the open invoice will be voided and no further invoices will be generated. \n\nA subscription that is currently in a trial period is `trialing` and moves to `active` when the trial period is over. \n\nA subscription can only enter a `paused` status [when a trial ends without a payment method](/billing/subscriptions/trials#create-free-trials-without-payment). A `paused` subscription doesn't generate invoices and can be resumed after your customer adds their payment method. The `paused` status is different from [pausing collection](/billing/subscriptions/pause-payment), which still generates invoices and leaves the subscription's status unchanged. \n\nIf subscription `collection_method=charge_automatically`, it becomes `past_due` when payment is required but cannot be paid (due to failed payment or awaiting additional user actions). Once Stripe has exhausted all payment retry attempts, the subscription will become `canceled` or `unpaid` (depending on your subscriptions settings). \n\nIf subscription `collection_method=send_invoice` it becomes `past_due` when its invoice is not paid by the due date, and `canceled` or `unpaid` if it is still not paid by an additional deadline after that. Note that when a subscription has a status of `unpaid`, no subsequent invoices will be attempted (invoices will be created, but then immediately automatically closed). After receiving updated payment information from a customer, you may choose to reopen and pay their closed invoices.", + "enum": [ + "active", + "canceled", + "incomplete", + "incomplete_expired", + "past_due", + "paused", + "trialing", + "unpaid" + ], + "type": "string" + }, + "test_clock": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ], + "description": "ID of the test clock this subscription belongs to.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ] + } + }, + "transfer_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_transfer_data" + } + ], + "description": "The account (if any) the subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.", + "nullable": true + }, + "trial_end": { + "description": "If the subscription has a trial, the end of that trial.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "trial_settings": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscriptions_trials_resource_trial_settings" + } + ], + "description": "Settings related to subscription trials.", + "nullable": true + }, + "trial_start": { + "description": "If the subscription has a trial, the beginning of that trial.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "required": [ + "automatic_tax", + "billing_cycle_anchor", + "cancel_at_period_end", + "collection_method", + "created", + "currency", + "current_period_end", + "current_period_start", + "customer", + "discounts", + "id", + "invoice_settings", + "items", + "livemode", + "metadata", + "object", + "start_date", + "status" + ], + "title": "Subscription", + "type": "object", + "x-expandableFields": [ + "application", + "automatic_tax", + "billing_cycle_anchor_config", + "billing_thresholds", + "cancellation_details", + "customer", + "default_payment_method", + "default_source", + "default_tax_rates", + "discount", + "discounts", + "invoice_settings", + "items", + "latest_invoice", + "on_behalf_of", + "pause_collection", + "payment_settings", + "pending_invoice_item_interval", + "pending_setup_intent", + "pending_update", + "schedule", + "test_clock", + "transfer_data", + "trial_settings" + ], + "x-resourceId": "subscription" + }, + "subscription_automatic_tax": { + "description": "", + "properties": { + "enabled": { + "description": "Whether Stripe automatically computes tax on this subscription.", + "type": "boolean" + }, + "liability": { + "anyOf": [ + { + "$ref": "#/components/schemas/connect_account_reference" + } + ], + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "nullable": true + } + }, + "required": ["enabled"], + "title": "SubscriptionAutomaticTax", + "type": "object", + "x-expandableFields": ["liability"] + }, + "subscription_billing_thresholds": { + "description": "", + "properties": { + "amount_gte": { + "description": "Monetary threshold that triggers the subscription to create an invoice", + "nullable": true, + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "description": "Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged. This value may not be `true` if the subscription contains items with plans that have `aggregate_usage=last_ever`.", + "nullable": true, + "type": "boolean" + } + }, + "title": "SubscriptionBillingThresholds", + "type": "object", + "x-expandableFields": [] + }, + "subscription_details_data": { + "description": "", + "properties": { + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) defined as subscription metadata when an invoice is created. Becomes an immutable snapshot of the subscription metadata at the time of invoice finalization.\n *Note: This attribute is populated only for invoices created on or after June 29, 2023.*", + "nullable": true, + "type": "object" + } + }, + "title": "SubscriptionDetailsData", + "type": "object", + "x-expandableFields": [] + }, + "subscription_item": { + "description": "Subscription items allow you to create customer subscriptions with more than\none plan, making it easy to represent complex billing relationships.", + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_item_billing_thresholds" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the related subscription advanced to a new billing period", + "nullable": true + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "type": "integer" + }, + "discounts": { + "description": "The discounts applied to the subscription item. Subscription item discounts are applied before subscription discounts. Use `expand[]=discounts` to expand each discount.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/discount" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/discount" + } + ] + } + }, + "type": "array" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["subscription_item"], + "type": "string" + }, + "price": { + "$ref": "#/components/schemas/price" + }, + "quantity": { + "description": "The [quantity](https://stripe.com/docs/subscriptions/quantities) of the plan to which the customer should be subscribed.", + "type": "integer" + }, + "subscription": { + "description": "The `subscription` this `subscription_item` belongs to.", + "maxLength": 5000, + "type": "string" + }, + "tax_rates": { + "description": "The tax rates which apply to this `subscription_item`. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.", + "items": { + "$ref": "#/components/schemas/tax_rate" + }, + "nullable": true, + "type": "array" + } + }, + "required": [ + "created", + "discounts", + "id", + "metadata", + "object", + "price", + "subscription" + ], + "title": "SubscriptionItem", + "type": "object", + "x-expandableFields": [ + "billing_thresholds", + "discounts", + "price", + "tax_rates" + ], + "x-resourceId": "subscription_item" + }, + "subscription_item_billing_thresholds": { + "description": "", + "properties": { + "usage_gte": { + "description": "Usage threshold that triggers the subscription to create an invoice", + "nullable": true, + "type": "integer" + } + }, + "title": "SubscriptionItemBillingThresholds", + "type": "object", + "x-expandableFields": [] + }, + "subscription_payment_method_options_card": { + "description": "", + "properties": { + "mandate_options": { + "$ref": "#/components/schemas/invoice_mandate_options_card" + }, + "network": { + "description": "Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.", + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "nullable": true, + "type": "string" + }, + "request_three_d_secure": { + "description": "We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.", + "enum": ["any", "automatic", "challenge"], + "nullable": true, + "type": "string" + } + }, + "title": "subscription_payment_method_options_card", + "type": "object", + "x-expandableFields": ["mandate_options"] + }, + "subscription_pending_invoice_item_interval": { + "description": "", + "properties": { + "interval": { + "description": "Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.", + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).", + "type": "integer" + } + }, + "required": ["interval", "interval_count"], + "title": "SubscriptionPendingInvoiceItemInterval", + "type": "object", + "x-expandableFields": [] + }, + "subscription_schedule": { + "description": "A subscription schedule allows you to create and manage the lifecycle of a subscription by predefining expected changes.\n\nRelated guide: [Subscription schedules](https://stripe.com/docs/billing/subscriptions/subscription-schedules)", + "properties": { + "application": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" + } + ], + "description": "ID of the Connect Application that created the schedule.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application" + }, + { + "$ref": "#/components/schemas/deleted_application" + } + ] + } + }, + "canceled_at": { + "description": "Time at which the subscription schedule was canceled. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "completed_at": { + "description": "Time at which the subscription schedule was completed. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "current_phase": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_schedule_current_phase" + } + ], + "description": "Object representing the start and end dates for the current phase of the subscription schedule, if it is `active`.", + "nullable": true + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ], + "description": "ID of the customer who owns the subscription schedule.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ] + } + }, + "default_settings": { + "$ref": "#/components/schemas/subscription_schedules_resource_default_settings" + }, + "end_behavior": { + "description": "Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.", + "enum": ["cancel", "none", "release", "renew"], + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["subscription_schedule"], + "type": "string" + }, + "phases": { + "description": "Configuration for the subscription schedule's phases.", + "items": { + "$ref": "#/components/schemas/subscription_schedule_phase_configuration" + }, + "type": "array" + }, + "released_at": { + "description": "Time at which the subscription schedule was released. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "released_subscription": { + "description": "ID of the subscription once managed by the subscription schedule (if it is released).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "status": { + "description": "The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules).", + "enum": [ + "active", + "canceled", + "completed", + "not_started", + "released" + ], + "type": "string" + }, + "subscription": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/subscription" + } + ], + "description": "ID of the subscription managed by the subscription schedule.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/subscription" + } + ] + } + }, + "test_clock": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ], + "description": "ID of the test clock this subscription schedule belongs to.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + ] + } + } + }, + "required": [ + "created", + "customer", + "default_settings", + "end_behavior", + "id", + "livemode", + "object", + "phases", + "status" + ], + "title": "SubscriptionSchedule", + "type": "object", + "x-expandableFields": [ + "application", + "current_phase", + "customer", + "default_settings", + "phases", + "subscription", + "test_clock" + ], + "x-resourceId": "subscription_schedule" + }, + "subscription_schedule_add_invoice_item": { + "description": "An Add Invoice Item describes the prices and quantities that will be added as pending invoice items when entering a phase.", + "properties": { + "discounts": { + "description": "The stackable discounts that will be applied to the item.", + "items": { + "$ref": "#/components/schemas/discounts_resource_stackable_discount" + }, + "type": "array" + }, + "price": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/price" + }, + { + "$ref": "#/components/schemas/deleted_price" + } + ], + "description": "ID of the price used to generate the invoice item.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/price" + }, + { + "$ref": "#/components/schemas/deleted_price" + } + ] + } + }, + "quantity": { + "description": "The quantity of the invoice item.", + "nullable": true, + "type": "integer" + }, + "tax_rates": { + "description": "The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.", + "items": { + "$ref": "#/components/schemas/tax_rate" + }, + "nullable": true, + "type": "array" + } + }, + "required": ["discounts", "price"], + "title": "SubscriptionScheduleAddInvoiceItem", + "type": "object", + "x-expandableFields": ["discounts", "price", "tax_rates"] + }, + "subscription_schedule_configuration_item": { + "description": "A phase item describes the price and quantity of a phase.", + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_item_billing_thresholds" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the related subscription advanced to a new billing period", + "nullable": true + }, + "discounts": { + "description": "The discounts applied to the subscription item. Subscription item discounts are applied before subscription discounts. Use `expand[]=discounts` to expand each discount.", + "items": { + "$ref": "#/components/schemas/discounts_resource_stackable_discount" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an item. Metadata on this item will update the underlying subscription item's `metadata` when the phase is entered.", + "nullable": true, + "type": "object" + }, + "price": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/price" + }, + { + "$ref": "#/components/schemas/deleted_price" + } + ], + "description": "ID of the price to which the customer should be subscribed.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/price" + }, + { + "$ref": "#/components/schemas/deleted_price" + } + ] + } + }, + "quantity": { + "description": "Quantity of the plan to which the customer should be subscribed.", + "type": "integer" + }, + "tax_rates": { + "description": "The tax rates which apply to this `phase_item`. When set, the `default_tax_rates` on the phase do not apply to this `phase_item`.", + "items": { + "$ref": "#/components/schemas/tax_rate" + }, + "nullable": true, + "type": "array" + } + }, + "required": ["discounts", "price"], + "title": "SubscriptionScheduleConfigurationItem", + "type": "object", + "x-expandableFields": [ + "billing_thresholds", + "discounts", + "price", + "tax_rates" + ] + }, + "subscription_schedule_current_phase": { + "description": "", + "properties": { + "end_date": { + "description": "The end of this phase of the subscription schedule.", + "format": "unix-time", + "type": "integer" + }, + "start_date": { + "description": "The start of this phase of the subscription schedule.", + "format": "unix-time", + "type": "integer" + } + }, + "required": ["end_date", "start_date"], + "title": "SubscriptionScheduleCurrentPhase", + "type": "object", + "x-expandableFields": [] + }, + "subscription_schedule_phase_configuration": { + "description": "A phase describes the plans, coupon, and trialing status of a subscription for a predefined time period.", + "properties": { + "add_invoice_items": { + "description": "A list of prices and quantities that will generate invoice items appended to the next invoice for this phase.", + "items": { + "$ref": "#/components/schemas/subscription_schedule_add_invoice_item" + }, + "type": "array" + }, + "application_fee_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account during this phase of the schedule.", + "nullable": true, + "type": "number" + }, + "automatic_tax": { + "$ref": "#/components/schemas/schedules_phase_automatic_tax" + }, + "billing_cycle_anchor": { + "description": "Possible values are `phase_start` or `automatic`. If `phase_start` then billing cycle anchor of the subscription is set to the start of the phase when entering the phase. If `automatic` then the billing cycle anchor is automatically modified as needed when entering the phase. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", + "enum": ["automatic", "phase_start"], + "nullable": true, + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_billing_thresholds" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period", + "nullable": true + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.", + "enum": ["charge_automatically", "send_invoice"], + "nullable": true, + "type": "string" + }, + "coupon": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/coupon" + }, + { + "$ref": "#/components/schemas/deleted_coupon" + } + ], + "description": "ID of the coupon to use during this phase of the subscription schedule.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/coupon" + }, + { + "$ref": "#/components/schemas/deleted_coupon" + } + ] + } + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "default_payment_method": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "default_tax_rates": { + "description": "The default tax rates to apply to the subscription during this phase of the subscription schedule.", + "items": { + "$ref": "#/components/schemas/tax_rate" + }, + "nullable": true, + "type": "array" + }, + "description": { + "description": "Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "discounts": { + "description": "The stackable discounts that will be applied to the subscription on this phase. Subscription item discounts are applied before subscription discounts.", + "items": { + "$ref": "#/components/schemas/discounts_resource_stackable_discount" + }, + "type": "array" + }, + "end_date": { + "description": "The end of this phase of the subscription schedule.", + "format": "unix-time", + "type": "integer" + }, + "invoice_settings": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_setting_subscription_schedule_phase_setting" + } + ], + "description": "The invoice settings applicable during this phase.", + "nullable": true + }, + "items": { + "description": "Subscription items to configure the subscription to during this phase of the subscription schedule.", + "items": { + "$ref": "#/components/schemas/subscription_schedule_configuration_item" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered. Updating the underlying subscription's `metadata` directly will not affect the current phase's `metadata`.", + "nullable": true, + "type": "object" + }, + "on_behalf_of": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account (if any) the charge was made on behalf of for charges associated with the schedule's subscription. See the Connect documentation for details.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + }, + "proration_behavior": { + "description": "If the subscription schedule will prorate when transitioning to this phase. Possible values are `create_prorations` and `none`.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "start_date": { + "description": "The start of this phase of the subscription schedule.", + "format": "unix-time", + "type": "integer" + }, + "transfer_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_transfer_data" + } + ], + "description": "The account (if any) the associated subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.", + "nullable": true + }, + "trial_end": { + "description": "When the trial ends within the phase.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "required": [ + "add_invoice_items", + "currency", + "discounts", + "end_date", + "items", + "proration_behavior", + "start_date" + ], + "title": "SubscriptionSchedulePhaseConfiguration", + "type": "object", + "x-expandableFields": [ + "add_invoice_items", + "automatic_tax", + "billing_thresholds", + "coupon", + "default_payment_method", + "default_tax_rates", + "discounts", + "invoice_settings", + "items", + "on_behalf_of", + "transfer_data" + ] + }, + "subscription_schedules_resource_default_settings": { + "description": "", + "properties": { + "application_fee_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account during this phase of the schedule.", + "nullable": true, + "type": "number" + }, + "automatic_tax": { + "$ref": "#/components/schemas/subscription_schedules_resource_default_settings_automatic_tax" + }, + "billing_cycle_anchor": { + "description": "Possible values are `phase_start` or `automatic`. If `phase_start` then billing cycle anchor of the subscription is set to the start of the phase when entering the phase. If `automatic` then the billing cycle anchor is automatically modified as needed when entering the phase. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", + "enum": ["automatic", "phase_start"], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_billing_thresholds" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period", + "nullable": true + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.", + "enum": ["charge_automatically", "send_invoice"], + "nullable": true, + "type": "string" + }, + "default_payment_method": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_method" + } + ], + "description": "ID of the default payment method for the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_method" + } + ] + } + }, + "description": { + "description": "Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "invoice_settings": { + "$ref": "#/components/schemas/invoice_setting_subscription_schedule_setting" + }, + "on_behalf_of": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account (if any) the charge was made on behalf of for charges associated with the schedule's subscription. See the Connect documentation for details.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + }, + "transfer_data": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_transfer_data" + } + ], + "description": "The account (if any) the associated subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.", + "nullable": true + } + }, + "required": ["billing_cycle_anchor", "invoice_settings"], + "title": "SubscriptionSchedulesResourceDefaultSettings", + "type": "object", + "x-expandableFields": [ + "automatic_tax", + "billing_thresholds", + "default_payment_method", + "invoice_settings", + "on_behalf_of", + "transfer_data" + ] + }, + "subscription_schedules_resource_default_settings_automatic_tax": { + "description": "", + "properties": { + "enabled": { + "description": "Whether Stripe automatically computes tax on invoices created during this phase.", + "type": "boolean" + }, + "liability": { + "anyOf": [ + { + "$ref": "#/components/schemas/connect_account_reference" + } + ], + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "nullable": true + } + }, + "required": ["enabled"], + "title": "SubscriptionSchedulesResourceDefaultSettingsAutomaticTax", + "type": "object", + "x-expandableFields": ["liability"] + }, + "subscription_transfer_data": { + "description": "", + "properties": { + "amount_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.", + "nullable": true, + "type": "number" + }, + "destination": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account where funds from the payment will be transferred to upon payment success.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + } + }, + "required": ["destination"], + "title": "SubscriptionTransferData", + "type": "object", + "x-expandableFields": ["destination"] + }, + "subscriptions_resource_billing_cycle_anchor_config": { + "description": "", + "properties": { + "day_of_month": { + "description": "The day of the month of the billing_cycle_anchor.", + "type": "integer" + }, + "hour": { + "description": "The hour of the day of the billing_cycle_anchor.", + "nullable": true, + "type": "integer" + }, + "minute": { + "description": "The minute of the hour of the billing_cycle_anchor.", + "nullable": true, + "type": "integer" + }, + "month": { + "description": "The month to start full cycle billing periods.", + "nullable": true, + "type": "integer" + }, + "second": { + "description": "The second of the minute of the billing_cycle_anchor.", + "nullable": true, + "type": "integer" + } + }, + "required": ["day_of_month"], + "title": "SubscriptionsResourceBillingCycleAnchorConfig", + "type": "object", + "x-expandableFields": [] + }, + "subscriptions_resource_pause_collection": { + "description": "The Pause Collection settings determine how we will pause collection for this subscription and for how long the subscription\nshould be paused.", + "properties": { + "behavior": { + "description": "The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.", + "enum": ["keep_as_draft", "mark_uncollectible", "void"], + "type": "string" + }, + "resumes_at": { + "description": "The time after which the subscription will resume collecting payments.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "required": ["behavior"], + "title": "SubscriptionsResourcePauseCollection", + "type": "object", + "x-expandableFields": [] + }, + "subscriptions_resource_payment_method_options": { + "description": "", + "properties": { + "acss_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_acss_debit" + } + ], + "description": "This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to invoices created by the subscription.", + "nullable": true + }, + "bancontact": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_bancontact" + } + ], + "description": "This sub-hash contains details about the Bancontact payment method options to pass to invoices created by the subscription.", + "nullable": true + }, + "card": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscription_payment_method_options_card" + } + ], + "description": "This sub-hash contains details about the Card payment method options to pass to invoices created by the subscription.", + "nullable": true + }, + "customer_balance": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_customer_balance" + } + ], + "description": "This sub-hash contains details about the Bank transfer payment method options to pass to invoices created by the subscription.", + "nullable": true + }, + "konbini": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_konbini" + } + ], + "description": "This sub-hash contains details about the Konbini payment method options to pass to invoices created by the subscription.", + "nullable": true + }, + "sepa_debit": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_sepa_debit" + } + ], + "description": "This sub-hash contains details about the SEPA Direct Debit payment method options to pass to invoices created by the subscription.", + "nullable": true + }, + "us_bank_account": { + "anyOf": [ + { + "$ref": "#/components/schemas/invoice_payment_method_options_us_bank_account" + } + ], + "description": "This sub-hash contains details about the ACH direct debit payment method options to pass to invoices created by the subscription.", + "nullable": true + } + }, + "title": "SubscriptionsResourcePaymentMethodOptions", + "type": "object", + "x-expandableFields": [ + "acss_debit", + "bancontact", + "card", + "customer_balance", + "konbini", + "sepa_debit", + "us_bank_account" + ] + }, + "subscriptions_resource_payment_settings": { + "description": "", + "properties": { + "payment_method_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/subscriptions_resource_payment_method_options" + } + ], + "description": "Payment-method-specific configuration to provide to invoices created by the subscription.", + "nullable": true + }, + "payment_method_types": { + "description": "The list of payment method types to provide to every invoice created by the subscription. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).", + "items": { + "enum": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "konbini", + "link", + "multibanco", + "p24", + "paynow", + "paypal", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "us_bank_account", + "wechat_pay" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "nullable": true, + "type": "array" + }, + "save_default_payment_method": { + "description": "Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off`.", + "enum": ["off", "on_subscription"], + "nullable": true, + "type": "string" + } + }, + "title": "SubscriptionsResourcePaymentSettings", + "type": "object", + "x-expandableFields": ["payment_method_options"] + }, + "subscriptions_resource_pending_update": { + "description": "Pending Updates store the changes pending from a previous update that will be applied\nto the Subscription upon successful payment.", + "properties": { + "billing_cycle_anchor": { + "description": "If the update is applied, determines the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. The timestamp is in UTC format.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "expires_at": { + "description": "The point after which the changes reflected by this update will be discarded and no longer applied.", + "format": "unix-time", + "type": "integer" + }, + "subscription_items": { + "description": "List of subscription items, each with an attached plan, that will be set if the update is applied.", + "items": { + "$ref": "#/components/schemas/subscription_item" + }, + "nullable": true, + "type": "array" + }, + "trial_end": { + "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time, if the update is applied.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "trial_from_plan": { + "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.", + "nullable": true, + "type": "boolean" + } + }, + "required": ["expires_at"], + "title": "SubscriptionsResourcePendingUpdate", + "type": "object", + "x-expandableFields": ["subscription_items"] + }, + "subscriptions_resource_subscription_invoice_settings": { + "description": "", + "properties": { + "account_tax_ids": { + "description": "The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.", + "items": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ], + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/tax_id" + }, + { + "$ref": "#/components/schemas/deleted_tax_id" + } + ] + } + }, + "nullable": true, + "type": "array" + }, + "issuer": { + "$ref": "#/components/schemas/connect_account_reference" + } + }, + "required": ["issuer"], + "title": "SubscriptionsResourceSubscriptionInvoiceSettings", + "type": "object", + "x-expandableFields": ["account_tax_ids", "issuer"] + }, + "subscriptions_trials_resource_end_behavior": { + "description": "Defines how a subscription behaves when a free trial ends.", + "properties": { + "missing_payment_method": { + "description": "Indicates how the subscription should change when the trial ends if the user did not provide a payment method.", + "enum": ["cancel", "create_invoice", "pause"], + "type": "string" + } + }, + "required": ["missing_payment_method"], + "title": "SubscriptionsTrialsResourceEndBehavior", + "type": "object", + "x-expandableFields": [] + }, + "subscriptions_trials_resource_trial_settings": { + "description": "Configures how this subscription behaves during the trial period.", + "properties": { + "end_behavior": { + "$ref": "#/components/schemas/subscriptions_trials_resource_end_behavior" + } + }, + "required": ["end_behavior"], + "title": "SubscriptionsTrialsResourceTrialSettings", + "type": "object", + "x-expandableFields": ["end_behavior"] + }, + "tax.calculation": { + "description": "A Tax Calculation allows you to calculate the tax to collect from your customer.\n\nRelated guide: [Calculate tax in your custom payment flow](https://stripe.com/docs/tax/custom)", + "properties": { + "amount_total": { + "description": "Total amount after taxes in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "maxLength": 5000, + "type": "string" + }, + "customer": { + "description": "The ID of an existing [Customer](https://stripe.com/docs/api/customers/object) used for the resource.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "customer_details": { + "$ref": "#/components/schemas/tax_product_resource_customer_details" + }, + "expires_at": { + "description": "Timestamp of date at which the tax calculation will expire.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "id": { + "description": "Unique identifier for the calculation.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "line_items": { + "description": "The list of items the customer is purchasing.", + "nullable": true, + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/tax.calculation_line_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/tax/calculations/[^/]+/line_items", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TaxProductResourceTaxCalculationLineItemList", + "type": "object", + "x-expandableFields": ["data"] + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax.calculation"], + "type": "string" + }, + "ship_from_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_product_resource_ship_from_details" + } + ], + "description": "The details of the ship from location, such as the address.", + "nullable": true + }, + "shipping_cost": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_product_resource_tax_calculation_shipping_cost" + } + ], + "description": "The shipping cost details for the calculation.", + "nullable": true + }, + "tax_amount_exclusive": { + "description": "The amount of tax to be collected on top of the line item prices.", + "type": "integer" + }, + "tax_amount_inclusive": { + "description": "The amount of tax already included in the line item prices.", + "type": "integer" + }, + "tax_breakdown": { + "description": "Breakdown of individual tax amounts that add up to the total.", + "items": { + "$ref": "#/components/schemas/tax_product_resource_tax_breakdown" + }, + "type": "array" + }, + "tax_date": { + "description": "Timestamp of date at which the tax rules and rates in effect applies for the calculation.", + "format": "unix-time", + "type": "integer" + } + }, + "required": [ + "amount_total", + "currency", + "customer_details", + "livemode", + "object", + "tax_amount_exclusive", + "tax_amount_inclusive", + "tax_breakdown", + "tax_date" + ], + "title": "TaxProductResourceTaxCalculation", + "type": "object", + "x-expandableFields": [ + "customer_details", + "line_items", + "ship_from_details", + "shipping_cost", + "tax_breakdown" + ], + "x-resourceId": "tax.calculation" + }, + "tax.calculation_line_item": { + "description": "", + "properties": { + "amount": { + "description": "The line item amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.", + "type": "integer" + }, + "amount_tax": { + "description": "The amount of tax calculated for this line item, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax.calculation_line_item"], + "type": "string" + }, + "product": { + "description": "The ID of an existing [Product](https://stripe.com/docs/api/products/object).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "quantity": { + "description": "The number of units of the item being purchased. For reversals, this is the quantity reversed.", + "type": "integer" + }, + "reference": { + "description": "A custom identifier for this line item.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "tax_behavior": { + "description": "Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes.", + "enum": ["exclusive", "inclusive"], + "type": "string" + }, + "tax_breakdown": { + "description": "Detailed account of taxes relevant to this line item.", + "items": { + "$ref": "#/components/schemas/tax_product_resource_line_item_tax_breakdown" + }, + "nullable": true, + "type": "array" + }, + "tax_code": { + "description": "The [tax code](https://stripe.com/docs/tax/tax-categories) ID used for this resource.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "amount", + "amount_tax", + "id", + "livemode", + "object", + "quantity", + "tax_behavior", + "tax_code" + ], + "title": "TaxProductResourceTaxCalculationLineItem", + "type": "object", + "x-expandableFields": ["tax_breakdown"], + "x-resourceId": "tax.calculation_line_item" + }, + "tax.registration": { + "description": "A Tax `Registration` lets us know that your business is registered to collect tax on payments within a region, enabling you to [automatically collect tax](https://stripe.com/docs/tax).\n\nStripe doesn't register on your behalf with the relevant authorities when you create a Tax `Registration` object. For more information on how to register to collect tax, see [our guide](https://stripe.com/docs/tax/registering).\n\nRelated guide: [Using the Registrations API](https://stripe.com/docs/tax/registrations-api)", + "properties": { + "active_from": { + "description": "Time at which the registration becomes active. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "country_options": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "expires_at": { + "description": "If set, the registration stops being active at this time. If not set, the registration will be active indefinitely. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax.registration"], + "type": "string" + }, + "status": { + "description": "The status of the registration. This field is present for convenience and can be deduced from `active_from` and `expires_at`.", + "enum": ["active", "expired", "scheduled"], + "type": "string" + } + }, + "required": [ + "active_from", + "country", + "country_options", + "created", + "id", + "livemode", + "object", + "status" + ], + "title": "TaxProductRegistrationsResourceTaxRegistration", + "type": "object", + "x-expandableFields": ["country_options"], + "x-resourceId": "tax.registration" + }, + "tax.settings": { + "description": "You can use Tax `Settings` to manage configurations used by Stripe Tax calculations.\n\nRelated guide: [Using the Settings API](https://stripe.com/docs/tax/settings-api)", + "properties": { + "defaults": { + "$ref": "#/components/schemas/tax_product_resource_tax_settings_defaults" + }, + "head_office": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_product_resource_tax_settings_head_office" + } + ], + "description": "The place where your business is located.", + "nullable": true + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax.settings"], + "type": "string" + }, + "status": { + "description": "The `active` status indicates you have all required settings to calculate tax. A status can transition out of `active` when new required settings are introduced.", + "enum": ["active", "pending"], + "type": "string" + }, + "status_details": { + "$ref": "#/components/schemas/tax_product_resource_tax_settings_status_details" + } + }, + "required": [ + "defaults", + "livemode", + "object", + "status", + "status_details" + ], + "title": "TaxProductResourceTaxSettings", + "type": "object", + "x-expandableFields": ["defaults", "head_office", "status_details"], + "x-resourceId": "tax.settings" + }, + "tax.transaction": { + "description": "A Tax Transaction records the tax collected from or refunded to your customer.\n\nRelated guide: [Calculate tax in your custom payment flow](https://stripe.com/docs/tax/custom#tax-transaction)", + "properties": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "maxLength": 5000, + "type": "string" + }, + "customer": { + "description": "The ID of an existing [Customer](https://stripe.com/docs/api/customers/object) used for the resource.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "customer_details": { + "$ref": "#/components/schemas/tax_product_resource_customer_details" + }, + "id": { + "description": "Unique identifier for the transaction.", + "maxLength": 5000, + "type": "string" + }, + "line_items": { + "description": "The tax collected or refunded, by line item.", + "nullable": true, + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/tax.transaction_line_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/tax/transactions/[^/]+/line_items", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TaxProductResourceTaxTransactionLineItemList", + "type": "object", + "x-expandableFields": ["data"] + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax.transaction"], + "type": "string" + }, + "posted_at": { + "description": "The Unix timestamp representing when the tax liability is assumed or reduced.", + "format": "unix-time", + "type": "integer" + }, + "reference": { + "description": "A custom unique identifier, such as 'myOrder_123'.", + "maxLength": 5000, + "type": "string" + }, + "reversal": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_product_resource_tax_transaction_resource_reversal" + } + ], + "description": "If `type=reversal`, contains information about what was reversed.", + "nullable": true + }, + "ship_from_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_product_resource_ship_from_details" + } + ], + "description": "The details of the ship from location, such as the address.", + "nullable": true + }, + "shipping_cost": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_product_resource_tax_transaction_shipping_cost" + } + ], + "description": "The shipping cost details for the transaction.", + "nullable": true + }, + "tax_date": { + "description": "Timestamp of date at which the tax rules and rates in effect applies for the calculation.", + "format": "unix-time", + "type": "integer" + }, + "type": { + "description": "If `reversal`, this transaction reverses an earlier transaction.", + "enum": ["reversal", "transaction"], + "type": "string" + } + }, + "required": [ + "created", + "currency", + "customer_details", + "id", + "livemode", + "object", + "posted_at", + "reference", + "tax_date", + "type" + ], + "title": "TaxProductResourceTaxTransaction", + "type": "object", + "x-expandableFields": [ + "customer_details", + "line_items", + "reversal", + "ship_from_details", + "shipping_cost" + ], + "x-resourceId": "tax.transaction" + }, + "tax.transaction_line_item": { + "description": "", + "properties": { + "amount": { + "description": "The line item amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.", + "type": "integer" + }, + "amount_tax": { + "description": "The amount of tax calculated for this line item, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax.transaction_line_item"], + "type": "string" + }, + "product": { + "description": "The ID of an existing [Product](https://stripe.com/docs/api/products/object).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "quantity": { + "description": "The number of units of the item being purchased. For reversals, this is the quantity reversed.", + "type": "integer" + }, + "reference": { + "description": "A custom identifier for this line item in the transaction.", + "maxLength": 5000, + "type": "string" + }, + "reversal": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_product_resource_tax_transaction_line_item_resource_reversal" + } + ], + "description": "If `type=reversal`, contains information about what was reversed.", + "nullable": true + }, + "tax_behavior": { + "description": "Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes.", + "enum": ["exclusive", "inclusive"], + "type": "string" + }, + "tax_code": { + "description": "The [tax code](https://stripe.com/docs/tax/tax-categories) ID used for this resource.", + "maxLength": 5000, + "type": "string" + }, + "type": { + "description": "If `reversal`, this line item reverses an earlier transaction.", + "enum": ["reversal", "transaction"], + "type": "string" + } + }, + "required": [ + "amount", + "amount_tax", + "id", + "livemode", + "object", + "quantity", + "reference", + "tax_behavior", + "tax_code", + "type" + ], + "title": "TaxProductResourceTaxTransactionLineItem", + "type": "object", + "x-expandableFields": ["reversal"], + "x-resourceId": "tax.transaction_line_item" + }, + "tax_code": { + "description": "[Tax codes](https://stripe.com/docs/tax/tax-categories) classify goods and services for tax purposes.", + "properties": { + "description": { + "description": "A detailed description of which types of products the tax code represents.", + "maxLength": 5000, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "name": { + "description": "A short name for the tax code.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax_code"], + "type": "string" + } + }, + "required": ["description", "id", "name", "object"], + "title": "TaxProductResourceTaxCode", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "tax_code" + }, + "tax_deducted_at_source": { + "description": "", + "properties": { + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax_deducted_at_source"], + "type": "string" + }, + "period_end": { + "description": "The end of the invoicing period. This TDS applies to Stripe fees collected during this invoicing period.", + "format": "unix-time", + "type": "integer" + }, + "period_start": { + "description": "The start of the invoicing period. This TDS applies to Stripe fees collected during this invoicing period.", + "format": "unix-time", + "type": "integer" + }, + "tax_deduction_account_number": { + "description": "The TAN that was supplied to Stripe when TDS was assessed", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "id", + "object", + "period_end", + "period_start", + "tax_deduction_account_number" + ], + "title": "TaxDeductedAtSource", + "type": "object", + "x-expandableFields": [] + }, + "tax_i_ds_owner": { + "description": "", + "properties": { + "account": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account being referenced when `type` is `account`.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + }, + "application": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/application" + } + ], + "description": "The Connect Application being referenced when `type` is `application`.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/application" + } + ] + } + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + } + ], + "description": "The customer being referenced when `type` is `customer`.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + } + ] + } + }, + "type": { + "description": "Type of owner referenced.", + "enum": ["account", "application", "customer", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "TaxIDsOwner", + "type": "object", + "x-expandableFields": ["account", "application", "customer"] + }, + "tax_id": { + "description": "You can add one or multiple tax IDs to a [customer](https://stripe.com/docs/api/customers) or account.\nCustomer and account tax IDs get displayed on related invoices and credit notes.\n\nRelated guides: [Customer tax identification numbers](https://stripe.com/docs/billing/taxes/tax-ids), [Account tax IDs](https://stripe.com/docs/invoicing/connect#account-tax-ids)", + "properties": { + "country": { + "description": "Two-letter ISO code representing the country of the tax ID.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + } + ], + "description": "ID of the customer.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + } + ] + } + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax_id"], + "type": "string" + }, + "owner": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_i_ds_owner" + } + ], + "description": "The account or customer the tax ID belongs to.", + "nullable": true + }, + "type": { + "description": "Type of the tax ID, one of `ad_nrt`, `ae_trn`, `ar_cuit`, `au_abn`, `au_arn`, `bg_uic`, `bh_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `ch_uid`, `ch_vat`, `cl_tin`, `cn_tin`, `co_nit`, `cr_tin`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kr_brn`, `kz_bin`, `li_uid`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sv_nit`, `th_vat`, `tr_tin`, `tw_vat`, `ua_vat`, `us_ein`, `uy_ruc`, `ve_rif`, `vn_tin`, or `za_vat`. Note that some legacy tax IDs have type `unknown`", + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "unknown", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "type": "string" + }, + "value": { + "description": "Value of the tax ID.", + "maxLength": 5000, + "type": "string" + }, + "verification": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_id_verification" + } + ], + "description": "Tax ID verification information.", + "nullable": true + } + }, + "required": ["created", "id", "livemode", "object", "type", "value"], + "title": "tax_id", + "type": "object", + "x-expandableFields": ["customer", "owner", "verification"], + "x-resourceId": "tax_id" + }, + "tax_id_verification": { + "description": "", + "properties": { + "status": { + "description": "Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`.", + "enum": ["pending", "unavailable", "unverified", "verified"], + "type": "string" + }, + "verified_address": { + "description": "Verified address.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "verified_name": { + "description": "Verified name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["status"], + "title": "tax_id_verification", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_registrations_resource_country_options": { + "description": "", + "properties": { + "ae": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "at": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "au": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "be": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "bg": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "bh": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "ca": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_canada" + }, + "ch": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "cl": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "co": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "cy": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "cz": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "de": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "dk": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "ee": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "eg": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "es": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "fi": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "fr": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "gb": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "ge": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "gr": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "hr": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "hu": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "id": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "ie": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "is": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "it": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "jp": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "ke": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "kr": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "kz": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "lt": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "lu": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "lv": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "mt": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "mx": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "my": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "ng": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "nl": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "no": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "nz": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "om": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "pl": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "pt": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "ro": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "sa": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "se": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "sg": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + }, + "si": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "sk": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_europe" + }, + "th": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "tr": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "us": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_united_states" + }, + "vn": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_simplified" + }, + "za": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_default" + } + }, + "title": "TaxProductRegistrationsResourceCountryOptions", + "type": "object", + "x-expandableFields": [ + "ae", + "at", + "au", + "be", + "bg", + "bh", + "ca", + "ch", + "cl", + "co", + "cy", + "cz", + "de", + "dk", + "ee", + "eg", + "es", + "fi", + "fr", + "gb", + "ge", + "gr", + "hr", + "hu", + "id", + "ie", + "is", + "it", + "jp", + "ke", + "kr", + "kz", + "lt", + "lu", + "lv", + "mt", + "mx", + "my", + "ng", + "nl", + "no", + "nz", + "om", + "pl", + "pt", + "ro", + "sa", + "se", + "sg", + "si", + "sk", + "th", + "tr", + "us", + "vn", + "za" + ] + }, + "tax_product_registrations_resource_country_options_ca_province_standard": { + "description": "", + "properties": { + "province": { + "description": "Two-letter CA province code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["province"], + "title": "TaxProductRegistrationsResourceCountryOptionsCaProvinceStandard", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_registrations_resource_country_options_canada": { + "description": "", + "properties": { + "province_standard": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_ca_province_standard" + }, + "type": { + "description": "Type of registration in Canada.", + "enum": ["province_standard", "simplified", "standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "TaxProductRegistrationsResourceCountryOptionsCanada", + "type": "object", + "x-expandableFields": ["province_standard"] + }, + "tax_product_registrations_resource_country_options_default": { + "description": "", + "properties": { + "type": { + "description": "Type of registration in `country`.", + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "TaxProductRegistrationsResourceCountryOptionsDefault", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_registrations_resource_country_options_eu_standard": { + "description": "", + "properties": { + "place_of_supply_scheme": { + "description": "Place of supply scheme used in an EU standard registration.", + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "TaxProductRegistrationsResourceCountryOptionsEuStandard", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_registrations_resource_country_options_europe": { + "description": "", + "properties": { + "standard": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_eu_standard" + }, + "type": { + "description": "Type of registration in an EU country.", + "enum": ["ioss", "oss_non_union", "oss_union", "standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "TaxProductRegistrationsResourceCountryOptionsEurope", + "type": "object", + "x-expandableFields": ["standard"] + }, + "tax_product_registrations_resource_country_options_simplified": { + "description": "", + "properties": { + "type": { + "description": "Type of registration in `country`.", + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "TaxProductRegistrationsResourceCountryOptionsSimplified", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_registrations_resource_country_options_united_states": { + "description": "", + "properties": { + "local_amusement_tax": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_us_local_amusement_tax" + }, + "local_lease_tax": { + "$ref": "#/components/schemas/tax_product_registrations_resource_country_options_us_local_lease_tax" + }, + "state": { + "description": "Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).", + "maxLength": 5000, + "type": "string" + }, + "type": { + "description": "Type of registration in the US.", + "enum": [ + "local_amusement_tax", + "local_lease_tax", + "state_communications_tax", + "state_sales_tax" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["state", "type"], + "title": "TaxProductRegistrationsResourceCountryOptionsUnitedStates", + "type": "object", + "x-expandableFields": ["local_amusement_tax", "local_lease_tax"] + }, + "tax_product_registrations_resource_country_options_us_local_amusement_tax": { + "description": "", + "properties": { + "jurisdiction": { + "description": "A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["jurisdiction"], + "title": "TaxProductRegistrationsResourceCountryOptionsUsLocalAmusementTax", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_registrations_resource_country_options_us_local_lease_tax": { + "description": "", + "properties": { + "jurisdiction": { + "description": "A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["jurisdiction"], + "title": "TaxProductRegistrationsResourceCountryOptionsUsLocalLeaseTax", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_customer_details": { + "description": "", + "properties": { + "address": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_product_resource_postal_address" + } + ], + "description": "The customer's postal address (for example, home or business location).", + "nullable": true + }, + "address_source": { + "description": "The type of customer address provided.", + "enum": ["billing", "shipping"], + "nullable": true, + "type": "string" + }, + "ip_address": { + "description": "The customer's IP address (IPv4 or IPv6).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "tax_ids": { + "description": "The customer's tax IDs (for example, EU VAT numbers).", + "items": { + "$ref": "#/components/schemas/tax_product_resource_customer_details_resource_tax_id" + }, + "type": "array" + }, + "taxability_override": { + "description": "The taxability override used for taxation.", + "enum": ["customer_exempt", "none", "reverse_charge"], + "type": "string" + } + }, + "required": ["tax_ids", "taxability_override"], + "title": "TaxProductResourceCustomerDetails", + "type": "object", + "x-expandableFields": ["address", "tax_ids"] + }, + "tax_product_resource_customer_details_resource_tax_id": { + "description": "", + "properties": { + "type": { + "description": "The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, or `unknown`", + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "unknown", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "type": "string" + }, + "value": { + "description": "The value of the tax ID.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type", "value"], + "title": "TaxProductResourceCustomerDetailsResourceTaxId", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_jurisdiction": { + "description": "", + "properties": { + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "display_name": { + "description": "A human-readable name for the jurisdiction imposing the tax.", + "maxLength": 5000, + "type": "string" + }, + "level": { + "description": "Indicates the level of the jurisdiction imposing the tax.", + "enum": ["city", "country", "county", "district", "state"], + "type": "string" + }, + "state": { + "description": "[ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, \"NY\" for New York, United States.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["country", "display_name", "level"], + "title": "TaxProductResourceJurisdiction", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_line_item_tax_breakdown": { + "description": "", + "properties": { + "amount": { + "description": "The amount of tax, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "jurisdiction": { + "$ref": "#/components/schemas/tax_product_resource_jurisdiction" + }, + "sourcing": { + "description": "Indicates whether the jurisdiction was determined by the origin (merchant's address) or destination (customer's address).", + "enum": ["destination", "origin"], + "type": "string" + }, + "tax_rate_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/tax_product_resource_line_item_tax_rate_details" + } + ], + "description": "Details regarding the rate for this tax. This field will be `null` when the tax is not imposed, for example if the product is exempt from tax.", + "nullable": true + }, + "taxability_reason": { + "description": "The reasoning behind this tax, for example, if the product is tax exempt. The possible values for this field may be extended as new tax rules are supported.", + "enum": [ + "customer_exempt", + "not_collecting", + "not_subject_to_tax", + "not_supported", + "portion_product_exempt", + "portion_reduced_rated", + "portion_standard_rated", + "product_exempt", + "product_exempt_holiday", + "proportionally_rated", + "reduced_rated", + "reverse_charge", + "standard_rated", + "taxable_basis_reduced", + "zero_rated" + ], + "type": "string" + }, + "taxable_amount": { + "description": "The amount on which tax is calculated, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + } + }, + "required": [ + "amount", + "jurisdiction", + "sourcing", + "taxability_reason", + "taxable_amount" + ], + "title": "TaxProductResourceLineItemTaxBreakdown", + "type": "object", + "x-expandableFields": ["jurisdiction", "tax_rate_details"] + }, + "tax_product_resource_line_item_tax_rate_details": { + "description": "", + "properties": { + "display_name": { + "description": "A localized display name for tax type, intended to be human-readable. For example, \"Local Sales and Use Tax\", \"Value-added tax (VAT)\", or \"Umsatzsteuer (USt.)\".", + "maxLength": 5000, + "type": "string" + }, + "percentage_decimal": { + "description": "The tax rate percentage as a string. For example, 8.5% is represented as \"8.5\".", + "maxLength": 5000, + "type": "string" + }, + "tax_type": { + "description": "The tax type, such as `vat` or `sales_tax`.", + "enum": [ + "amusement_tax", + "communications_tax", + "gst", + "hst", + "igst", + "jct", + "lease_tax", + "pst", + "qst", + "rst", + "sales_tax", + "vat" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["display_name", "percentage_decimal", "tax_type"], + "title": "TaxProductResourceLineItemTaxRateDetails", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_postal_address": { + "description": "", + "properties": { + "city": { + "description": "City, district, suburb, town, or village.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "line1": { + "description": "Address line 1 (e.g., street, PO Box, or company name).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "line2": { + "description": "Address line 2 (e.g., apartment, suite, unit, or building).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "postal_code": { + "description": "ZIP or postal code.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "state": { + "description": "State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: \"NY\" or \"TX\".", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["country"], + "title": "TaxProductResourcePostalAddress", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_ship_from_details": { + "description": "", + "properties": { + "address": { + "$ref": "#/components/schemas/tax_product_resource_postal_address" + } + }, + "required": ["address"], + "title": "TaxProductResourceShipFromDetails", + "type": "object", + "x-expandableFields": ["address"] + }, + "tax_product_resource_tax_breakdown": { + "description": "", + "properties": { + "amount": { + "description": "The amount of tax, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "inclusive": { + "description": "Specifies whether the tax amount is included in the line item amount.", + "type": "boolean" + }, + "tax_rate_details": { + "$ref": "#/components/schemas/tax_product_resource_tax_rate_details" + }, + "taxability_reason": { + "description": "The reasoning behind this tax, for example, if the product is tax exempt. We might extend the possible values for this field to support new tax rules.", + "enum": [ + "customer_exempt", + "not_collecting", + "not_subject_to_tax", + "not_supported", + "portion_product_exempt", + "portion_reduced_rated", + "portion_standard_rated", + "product_exempt", + "product_exempt_holiday", + "proportionally_rated", + "reduced_rated", + "reverse_charge", + "standard_rated", + "taxable_basis_reduced", + "zero_rated" + ], + "type": "string" + }, + "taxable_amount": { + "description": "The amount on which tax is calculated, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + } + }, + "required": [ + "amount", + "inclusive", + "tax_rate_details", + "taxability_reason", + "taxable_amount" + ], + "title": "TaxProductResourceTaxBreakdown", + "type": "object", + "x-expandableFields": ["tax_rate_details"] + }, + "tax_product_resource_tax_calculation_shipping_cost": { + "description": "", + "properties": { + "amount": { + "description": "The shipping amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.", + "type": "integer" + }, + "amount_tax": { + "description": "The amount of tax calculated for shipping, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "shipping_rate": { + "description": "The ID of an existing [ShippingRate](https://stripe.com/docs/api/shipping_rates/object).", + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "description": "Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes.", + "enum": ["exclusive", "inclusive"], + "type": "string" + }, + "tax_breakdown": { + "description": "Detailed account of taxes relevant to shipping cost.", + "items": { + "$ref": "#/components/schemas/tax_product_resource_line_item_tax_breakdown" + }, + "type": "array" + }, + "tax_code": { + "description": "The [tax code](https://stripe.com/docs/tax/tax-categories) ID used for shipping.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["amount", "amount_tax", "tax_behavior", "tax_code"], + "title": "TaxProductResourceTaxCalculationShippingCost", + "type": "object", + "x-expandableFields": ["tax_breakdown"] + }, + "tax_product_resource_tax_rate_details": { + "description": "", + "properties": { + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "percentage_decimal": { + "description": "The tax rate percentage as a string. For example, 8.5% is represented as `\"8.5\"`.", + "maxLength": 5000, + "type": "string" + }, + "state": { + "description": "State, county, province, or region.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "tax_type": { + "description": "The tax type, such as `vat` or `sales_tax`.", + "enum": [ + "amusement_tax", + "communications_tax", + "gst", + "hst", + "igst", + "jct", + "lease_tax", + "pst", + "qst", + "rst", + "sales_tax", + "vat" + ], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["percentage_decimal"], + "title": "TaxProductResourceTaxRateDetails", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_tax_settings_defaults": { + "description": "", + "properties": { + "tax_behavior": { + "description": "Default [tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#tax-behavior) used to specify whether the price is considered inclusive of taxes or exclusive of taxes. If the item's price has a tax behavior set, it will take precedence over the default tax behavior.", + "enum": ["exclusive", "inclusive", "inferred_by_currency"], + "nullable": true, + "type": "string" + }, + "tax_code": { + "description": "Default [tax code](https://stripe.com/docs/tax/tax-categories) used to classify your products and prices.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "TaxProductResourceTaxSettingsDefaults", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_tax_settings_head_office": { + "description": "", + "properties": { + "address": { + "$ref": "#/components/schemas/address" + } + }, + "required": ["address"], + "title": "TaxProductResourceTaxSettingsHeadOffice", + "type": "object", + "x-expandableFields": ["address"] + }, + "tax_product_resource_tax_settings_status_details": { + "description": "", + "properties": { + "active": { + "$ref": "#/components/schemas/tax_product_resource_tax_settings_status_details_resource_active" + }, + "pending": { + "$ref": "#/components/schemas/tax_product_resource_tax_settings_status_details_resource_pending" + } + }, + "title": "TaxProductResourceTaxSettingsStatusDetails", + "type": "object", + "x-expandableFields": ["active", "pending"] + }, + "tax_product_resource_tax_settings_status_details_resource_active": { + "description": "", + "properties": {}, + "title": "TaxProductResourceTaxSettingsStatusDetailsResourceActive", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_tax_settings_status_details_resource_pending": { + "description": "", + "properties": { + "missing_fields": { + "description": "The list of missing fields that are required to perform calculations. It includes the entry `head_office` when the status is `pending`. It is recommended to set the optional values even if they aren't listed as required for calculating taxes. Calculations can fail if missing fields aren't explicitly provided on every call.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "nullable": true, + "type": "array" + } + }, + "title": "TaxProductResourceTaxSettingsStatusDetailsResourcePending", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_tax_transaction_line_item_resource_reversal": { + "description": "", + "properties": { + "original_line_item": { + "description": "The `id` of the line item to reverse in the original transaction.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["original_line_item"], + "title": "TaxProductResourceTaxTransactionLineItemResourceReversal", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_tax_transaction_resource_reversal": { + "description": "", + "properties": { + "original_transaction": { + "description": "The `id` of the reversed `Transaction` object.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "TaxProductResourceTaxTransactionResourceReversal", + "type": "object", + "x-expandableFields": [] + }, + "tax_product_resource_tax_transaction_shipping_cost": { + "description": "", + "properties": { + "amount": { + "description": "The shipping amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.", + "type": "integer" + }, + "amount_tax": { + "description": "The amount of tax calculated for shipping, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "shipping_rate": { + "description": "The ID of an existing [ShippingRate](https://stripe.com/docs/api/shipping_rates/object).", + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "description": "Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes.", + "enum": ["exclusive", "inclusive"], + "type": "string" + }, + "tax_code": { + "description": "The [tax code](https://stripe.com/docs/tax/tax-categories) ID used for shipping.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["amount", "amount_tax", "tax_behavior", "tax_code"], + "title": "TaxProductResourceTaxTransactionShippingCost", + "type": "object", + "x-expandableFields": [] + }, + "tax_rate": { + "description": "Tax rates can be applied to [invoices](https://stripe.com/docs/billing/invoices/tax-rates), [subscriptions](https://stripe.com/docs/billing/subscriptions/taxes) and [Checkout Sessions](https://stripe.com/docs/payments/checkout/set-up-a-subscription#tax-rates) to collect tax.\n\nRelated guide: [Tax rates](https://stripe.com/docs/billing/taxes/tax-rates)", + "properties": { + "active": { + "description": "Defaults to `true`. When set to `false`, this tax rate cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.", + "type": "boolean" + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "description": { + "description": "An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "display_name": { + "description": "The display name of the tax rates as it will appear to your customer on their receipt email, PDF, and the hosted invoice page.", + "maxLength": 5000, + "type": "string" + }, + "effective_percentage": { + "description": "Actual/effective tax rate percentage out of 100. For tax calculations with automatic_tax[enabled]=true,\nthis percentage reflects the rate actually used to calculate tax based on the product's taxability\nand whether the user is registered to collect taxes in the corresponding jurisdiction.", + "nullable": true, + "type": "number" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "inclusive": { + "description": "This specifies if the tax rate is inclusive or exclusive.", + "type": "boolean" + }, + "jurisdiction": { + "description": "The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "jurisdiction_level": { + "description": "The level of the jurisdiction that imposes this tax rate. Will be `null` for manually defined tax rates.", + "enum": [ + "city", + "country", + "county", + "district", + "multiple", + "state" + ], + "nullable": true, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["tax_rate"], + "type": "string" + }, + "percentage": { + "description": "Tax rate percentage out of 100. For tax calculations with automatic_tax[enabled]=true, this percentage includes the statutory tax rate of non-taxable jurisdictions.", + "type": "number" + }, + "state": { + "description": "[ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, \"NY\" for New York, United States.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "tax_type": { + "description": "The high-level tax type, such as `vat` or `sales_tax`.", + "enum": [ + "amusement_tax", + "communications_tax", + "gst", + "hst", + "igst", + "jct", + "lease_tax", + "pst", + "qst", + "rst", + "sales_tax", + "vat" + ], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "active", + "created", + "display_name", + "id", + "inclusive", + "livemode", + "object", + "percentage" + ], + "title": "TaxRate", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "tax_rate" + }, + "terminal.configuration": { + "description": "A Configurations object represents how features should be configured for terminal readers.", + "properties": { + "bbpos_wisepos_e": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_device_type_specific_config" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "is_account_default": { + "description": "Whether this Configuration is the default for your account", + "nullable": true, + "type": "boolean" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "name": { + "description": "String indicating the name of the Configuration object, set by the user", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["terminal.configuration"], + "type": "string" + }, + "offline": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_offline_config" + }, + "reboot_window": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_reboot_window" + }, + "stripe_s700": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_device_type_specific_config" + }, + "tipping": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_tipping" + }, + "verifone_p400": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_device_type_specific_config" + } + }, + "required": ["id", "livemode", "object"], + "title": "TerminalConfigurationConfiguration", + "type": "object", + "x-expandableFields": [ + "bbpos_wisepos_e", + "offline", + "reboot_window", + "stripe_s700", + "tipping", + "verifone_p400" + ], + "x-resourceId": "terminal.configuration" + }, + "terminal.connection_token": { + "description": "A Connection Token is used by the Stripe Terminal SDK to connect to a reader.\n\nRelated guide: [Fleet management](https://stripe.com/docs/terminal/fleet/locations)", + "properties": { + "location": { + "description": "The id of the location that this connection token is scoped to. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).", + "maxLength": 5000, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["terminal.connection_token"], + "type": "string" + }, + "secret": { + "description": "Your application should pass this token to the Stripe Terminal SDK.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["object", "secret"], + "title": "TerminalConnectionToken", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "terminal.connection_token" + }, + "terminal.location": { + "description": "A Location represents a grouping of readers.\n\nRelated guide: [Fleet management](https://stripe.com/docs/terminal/fleet/locations)", + "properties": { + "address": { + "$ref": "#/components/schemas/address" + }, + "configuration_overrides": { + "description": "The ID of a configuration that will be used to customize all readers in this location.", + "maxLength": 5000, + "type": "string" + }, + "display_name": { + "description": "The display name of the location.", + "maxLength": 5000, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["terminal.location"], + "type": "string" + } + }, + "required": [ + "address", + "display_name", + "id", + "livemode", + "metadata", + "object" + ], + "title": "TerminalLocationLocation", + "type": "object", + "x-expandableFields": ["address"], + "x-resourceId": "terminal.location" + }, + "terminal.reader": { + "description": "A Reader represents a physical device for accepting payment details.\n\nRelated guide: [Connecting to a reader](https://stripe.com/docs/terminal/payments/connect-reader)", + "properties": { + "action": { + "anyOf": [ + { + "$ref": "#/components/schemas/terminal_reader_reader_resource_reader_action" + } + ], + "description": "The most recent action performed by the reader.", + "nullable": true + }, + "device_sw_version": { + "description": "The current software version of the reader.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "device_type": { + "description": "Type of reader, one of `bbpos_wisepad3`, `stripe_m2`, `stripe_s700`, `bbpos_chipper2x`, `bbpos_wisepos_e`, `verifone_P400`, `simulated_wisepos_e`, or `mobile_phone_reader`.", + "enum": [ + "bbpos_chipper2x", + "bbpos_wisepad3", + "bbpos_wisepos_e", + "mobile_phone_reader", + "simulated_wisepos_e", + "stripe_m2", + "stripe_s700", + "verifone_P400" + ], + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "ip_address": { + "description": "The local IP address of the reader.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "label": { + "description": "Custom label given to the reader for easier identification.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "location": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/terminal.location" + } + ], + "description": "The location identifier of the reader.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/terminal.location" + } + ] + } + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["terminal.reader"], + "type": "string" + }, + "serial_number": { + "description": "Serial number of the reader.", + "maxLength": 5000, + "type": "string" + }, + "status": { + "description": "The networking status of the reader. We do not recommend using this field in flows that may block taking payments.", + "enum": ["offline", "online"], + "nullable": true, + "type": "string" + } + }, + "required": [ + "device_type", + "id", + "label", + "livemode", + "metadata", + "object", + "serial_number" + ], + "title": "TerminalReaderReader", + "type": "object", + "x-expandableFields": ["action", "location"], + "x-resourceId": "terminal.reader" + }, + "terminal_configuration_configuration_resource_currency_specific_config": { + "description": "", + "properties": { + "fixed_amounts": { + "description": "Fixed amounts displayed when collecting a tip", + "items": { + "type": "integer" + }, + "nullable": true, + "type": "array" + }, + "percentages": { + "description": "Percentages displayed when collecting a tip", + "items": { + "type": "integer" + }, + "nullable": true, + "type": "array" + }, + "smart_tip_threshold": { + "description": "Below this amount, fixed amounts will be displayed; above it, percentages will be displayed", + "type": "integer" + } + }, + "title": "TerminalConfigurationConfigurationResourceCurrencySpecificConfig", + "type": "object", + "x-expandableFields": [] + }, + "terminal_configuration_configuration_resource_device_type_specific_config": { + "description": "", + "properties": { + "splashscreen": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/file" + } + ], + "description": "A File ID representing an image you would like displayed on the reader.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/file" + } + ] + } + } + }, + "title": "TerminalConfigurationConfigurationResourceDeviceTypeSpecificConfig", + "type": "object", + "x-expandableFields": ["splashscreen"] + }, + "terminal_configuration_configuration_resource_offline_config": { + "description": "", + "properties": { + "enabled": { + "description": "Determines whether to allow transactions to be collected while reader is offline. Defaults to false.", + "nullable": true, + "type": "boolean" + } + }, + "title": "TerminalConfigurationConfigurationResourceOfflineConfig", + "type": "object", + "x-expandableFields": [] + }, + "terminal_configuration_configuration_resource_reboot_window": { + "description": "", + "properties": { + "end_hour": { + "description": "Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.", + "type": "integer" + }, + "start_hour": { + "description": "Integer between 0 to 23 that represents the start hour of the reboot time window.", + "type": "integer" + } + }, + "required": ["end_hour", "start_hour"], + "title": "TerminalConfigurationConfigurationResourceRebootWindow", + "type": "object", + "x-expandableFields": [] + }, + "terminal_configuration_configuration_resource_tipping": { + "description": "", + "properties": { + "aud": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "cad": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "chf": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "czk": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "dkk": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "eur": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "gbp": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "hkd": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "myr": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "nok": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "nzd": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "sek": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "sgd": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + }, + "usd": { + "$ref": "#/components/schemas/terminal_configuration_configuration_resource_currency_specific_config" + } + }, + "title": "TerminalConfigurationConfigurationResourceTipping", + "type": "object", + "x-expandableFields": [ + "aud", + "cad", + "chf", + "czk", + "dkk", + "eur", + "gbp", + "hkd", + "myr", + "nok", + "nzd", + "sek", + "sgd", + "usd" + ] + }, + "terminal_reader_reader_resource_cart": { + "description": "Represents a cart to be displayed on the reader", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "line_items": { + "description": "List of line items in the cart.", + "items": { + "$ref": "#/components/schemas/terminal_reader_reader_resource_line_item" + }, + "type": "array" + }, + "tax": { + "description": "Tax amount for the entire cart. A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "nullable": true, + "type": "integer" + }, + "total": { + "description": "Total amount for the entire cart, including tax. A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + } + }, + "required": ["currency", "line_items", "total"], + "title": "TerminalReaderReaderResourceCart", + "type": "object", + "x-expandableFields": ["line_items"] + }, + "terminal_reader_reader_resource_line_item": { + "description": "Represents a line item to be displayed on the reader", + "properties": { + "amount": { + "description": "The amount of the line item. A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "description": { + "description": "Description of the line item.", + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "description": "The quantity of the line item.", + "type": "integer" + } + }, + "required": ["amount", "description", "quantity"], + "title": "TerminalReaderReaderResourceLineItem", + "type": "object", + "x-expandableFields": [] + }, + "terminal_reader_reader_resource_process_config": { + "description": "Represents a per-transaction override of a reader configuration", + "properties": { + "enable_customer_cancellation": { + "description": "Enable customer initiated cancellation when processing this payment.", + "type": "boolean" + }, + "skip_tipping": { + "description": "Override showing a tipping selection screen on this transaction.", + "type": "boolean" + }, + "tipping": { + "$ref": "#/components/schemas/terminal_reader_reader_resource_tipping_config" + } + }, + "title": "TerminalReaderReaderResourceProcessConfig", + "type": "object", + "x-expandableFields": ["tipping"] + }, + "terminal_reader_reader_resource_process_payment_intent_action": { + "description": "Represents a reader action to process a payment intent", + "properties": { + "payment_intent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_intent" + } + ], + "description": "Most recent PaymentIntent processed by the reader.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_intent" + } + ] + } + }, + "process_config": { + "$ref": "#/components/schemas/terminal_reader_reader_resource_process_config" + } + }, + "required": ["payment_intent"], + "title": "TerminalReaderReaderResourceProcessPaymentIntentAction", + "type": "object", + "x-expandableFields": ["payment_intent", "process_config"] + }, + "terminal_reader_reader_resource_process_setup_config": { + "description": "Represents a per-setup override of a reader configuration", + "properties": { + "enable_customer_cancellation": { + "description": "Enable customer initiated cancellation when processing this SetupIntent.", + "type": "boolean" + } + }, + "title": "TerminalReaderReaderResourceProcessSetupConfig", + "type": "object", + "x-expandableFields": [] + }, + "terminal_reader_reader_resource_process_setup_intent_action": { + "description": "Represents a reader action to process a setup intent", + "properties": { + "generated_card": { + "description": "ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.", + "maxLength": 5000, + "type": "string" + }, + "process_config": { + "$ref": "#/components/schemas/terminal_reader_reader_resource_process_setup_config" + }, + "setup_intent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/setup_intent" + } + ], + "description": "Most recent SetupIntent processed by the reader.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/setup_intent" + } + ] + } + } + }, + "required": ["setup_intent"], + "title": "TerminalReaderReaderResourceProcessSetupIntentAction", + "type": "object", + "x-expandableFields": ["process_config", "setup_intent"] + }, + "terminal_reader_reader_resource_reader_action": { + "description": "Represents an action performed by the reader", + "properties": { + "failure_code": { + "description": "Failure code, only set if status is `failed`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "failure_message": { + "description": "Detailed failure message, only set if status is `failed`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "process_payment_intent": { + "$ref": "#/components/schemas/terminal_reader_reader_resource_process_payment_intent_action" + }, + "process_setup_intent": { + "$ref": "#/components/schemas/terminal_reader_reader_resource_process_setup_intent_action" + }, + "refund_payment": { + "$ref": "#/components/schemas/terminal_reader_reader_resource_refund_payment_action" + }, + "set_reader_display": { + "$ref": "#/components/schemas/terminal_reader_reader_resource_set_reader_display_action" + }, + "status": { + "description": "Status of the action performed by the reader.", + "enum": ["failed", "in_progress", "succeeded"], + "type": "string" + }, + "type": { + "description": "Type of action performed by the reader.", + "enum": [ + "process_payment_intent", + "process_setup_intent", + "refund_payment", + "set_reader_display" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["status", "type"], + "title": "TerminalReaderReaderResourceReaderAction", + "type": "object", + "x-expandableFields": [ + "process_payment_intent", + "process_setup_intent", + "refund_payment", + "set_reader_display" + ] + }, + "terminal_reader_reader_resource_refund_payment_action": { + "description": "Represents a reader action to refund a payment", + "properties": { + "amount": { + "description": "The amount being refunded.", + "type": "integer" + }, + "charge": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/charge" + } + ], + "description": "Charge that is being refunded.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/charge" + } + ] + } + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "payment_intent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/payment_intent" + } + ], + "description": "Payment intent that is being refunded.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/payment_intent" + } + ] + } + }, + "reason": { + "description": "The reason for the refund.", + "enum": ["duplicate", "fraudulent", "requested_by_customer"], + "type": "string" + }, + "refund": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/refund" + } + ], + "description": "Unique identifier for the refund object.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/refund" + } + ] + } + }, + "refund_application_fee": { + "description": "Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.", + "type": "boolean" + }, + "refund_payment_config": { + "$ref": "#/components/schemas/terminal_reader_reader_resource_refund_payment_config" + }, + "reverse_transfer": { + "description": "Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount). A transfer can be reversed only by the application that created the charge.", + "type": "boolean" + } + }, + "title": "TerminalReaderReaderResourceRefundPaymentAction", + "type": "object", + "x-expandableFields": [ + "charge", + "payment_intent", + "refund", + "refund_payment_config" + ] + }, + "terminal_reader_reader_resource_refund_payment_config": { + "description": "Represents a per-transaction override of a reader configuration", + "properties": { + "enable_customer_cancellation": { + "description": "Enable customer initiated cancellation when refunding this payment.", + "type": "boolean" + } + }, + "title": "TerminalReaderReaderResourceRefundPaymentConfig", + "type": "object", + "x-expandableFields": [] + }, + "terminal_reader_reader_resource_set_reader_display_action": { + "description": "Represents a reader action to set the reader display", + "properties": { + "cart": { + "anyOf": [ + { + "$ref": "#/components/schemas/terminal_reader_reader_resource_cart" + } + ], + "description": "Cart object to be displayed by the reader.", + "nullable": true + }, + "type": { + "description": "Type of information to be displayed by the reader.", + "enum": ["cart"], + "type": "string" + } + }, + "required": ["type"], + "title": "TerminalReaderReaderResourceSetReaderDisplayAction", + "type": "object", + "x-expandableFields": ["cart"] + }, + "terminal_reader_reader_resource_tipping_config": { + "description": "Represents a per-transaction tipping configuration", + "properties": { + "amount_eligible": { + "description": "Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).", + "type": "integer" + } + }, + "title": "TerminalReaderReaderResourceTippingConfig", + "type": "object", + "x-expandableFields": [] + }, + "test_helpers.test_clock": { + "description": "A test clock enables deterministic control over objects in testmode. With a test clock, you can create\nobjects at a frozen time in the past or future, and advance to a specific future time to observe webhooks and state changes. After the clock advances,\nyou can either validate the current state of your scenario (and test your assumptions), change the current state of your scenario (and test more complex scenarios), or keep advancing forward in time.", + "properties": { + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "deletes_after": { + "description": "Time at which this clock is scheduled to auto delete.", + "format": "unix-time", + "type": "integer" + }, + "frozen_time": { + "description": "Time at which all objects belonging to this clock are frozen.", + "format": "unix-time", + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "name": { + "description": "The custom name supplied at creation.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["test_helpers.test_clock"], + "type": "string" + }, + "status": { + "description": "The status of the Test Clock.", + "enum": ["advancing", "internal_failure", "ready"], + "type": "string" + }, + "status_details": { + "$ref": "#/components/schemas/billing_clocks_resource_status_details_status_details" + } + }, + "required": [ + "created", + "deletes_after", + "frozen_time", + "id", + "livemode", + "object", + "status" + ], + "title": "TestClock", + "type": "object", + "x-expandableFields": ["status_details"], + "x-resourceId": "test_helpers.test_clock" + }, + "three_d_secure_details": { + "description": "", + "properties": { + "authentication_flow": { + "description": "For authenticated transactions: how the customer was authenticated by\nthe issuing bank.", + "enum": ["challenge", "frictionless"], + "nullable": true, + "type": "string" + }, + "electronic_commerce_indicator": { + "description": "The Electronic Commerce Indicator (ECI). A protocol-level field\nindicating what degree of authentication was performed.", + "enum": ["01", "02", "05", "06", "07"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "result": { + "description": "Indicates the outcome of 3D Secure authentication.", + "enum": [ + "attempt_acknowledged", + "authenticated", + "exempted", + "failed", + "not_supported", + "processing_error" + ], + "nullable": true, + "type": "string" + }, + "result_reason": { + "description": "Additional information about why 3D Secure succeeded or failed based\non the `result`.", + "enum": [ + "abandoned", + "bypassed", + "canceled", + "card_not_enrolled", + "network_not_supported", + "protocol_error", + "rejected" + ], + "nullable": true, + "type": "string" + }, + "transaction_id": { + "description": "The 3D Secure 1 XID or 3D Secure 2 Directory Server Transaction ID\n(dsTransId) for this payment.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "version": { + "description": "The version of 3D Secure that was used.", + "enum": ["1.0.2", "2.1.0", "2.2.0"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "three_d_secure_details", + "type": "object", + "x-expandableFields": [] + }, + "three_d_secure_details_charge": { + "description": "", + "properties": { + "authentication_flow": { + "description": "For authenticated transactions: how the customer was authenticated by\nthe issuing bank.", + "enum": ["challenge", "frictionless"], + "nullable": true, + "type": "string" + }, + "electronic_commerce_indicator": { + "description": "The Electronic Commerce Indicator (ECI). A protocol-level field\nindicating what degree of authentication was performed.", + "enum": ["01", "02", "05", "06", "07"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "exemption_indicator": { + "description": "The exemption requested via 3DS and accepted by the issuer at authentication time.", + "enum": ["low_risk", "none"], + "nullable": true, + "type": "string" + }, + "exemption_indicator_applied": { + "description": "Whether Stripe requested the value of `exemption_indicator` in the transaction. This will depend on\nthe outcome of Stripe's internal risk assessment.", + "type": "boolean" + }, + "result": { + "description": "Indicates the outcome of 3D Secure authentication.", + "enum": [ + "attempt_acknowledged", + "authenticated", + "exempted", + "failed", + "not_supported", + "processing_error" + ], + "nullable": true, + "type": "string" + }, + "result_reason": { + "description": "Additional information about why 3D Secure succeeded or failed based\non the `result`.", + "enum": [ + "abandoned", + "bypassed", + "canceled", + "card_not_enrolled", + "network_not_supported", + "protocol_error", + "rejected" + ], + "nullable": true, + "type": "string" + }, + "transaction_id": { + "description": "The 3D Secure 1 XID or 3D Secure 2 Directory Server Transaction ID\n(dsTransId) for this payment.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "version": { + "description": "The version of 3D Secure that was used.", + "enum": ["1.0.2", "2.1.0", "2.2.0"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "three_d_secure_details_charge", + "type": "object", + "x-expandableFields": [] + }, + "three_d_secure_usage": { + "description": "", + "properties": { + "supported": { + "description": "Whether 3D Secure is supported on this card.", + "type": "boolean" + } + }, + "required": ["supported"], + "title": "three_d_secure_usage", + "type": "object", + "x-expandableFields": [] + }, + "thresholds_resource_alert_filter": { + "description": "", + "properties": { + "customer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/customer" + } + ], + "description": "Limit the scope of the alert to this customer ID", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/customer" + } + ] + } + } + }, + "title": "ThresholdsResourceAlertFilter", + "type": "object", + "x-expandableFields": ["customer"] + }, + "thresholds_resource_usage_threshold_config": { + "description": "The usage threshold alert configuration enables setting up alerts for when a certain usage threshold on a specific meter is crossed.", + "properties": { + "gte": { + "description": "The value at which this alert will trigger.", + "type": "integer" + }, + "meter": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/billing.meter" + } + ], + "description": "The [Billing Meter](/api/billing/meter) ID whose usage is monitored.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/billing.meter" + } + ] + } + }, + "recurrence": { + "description": "Defines how the alert will behave.", + "enum": ["one_time"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["gte", "meter", "recurrence"], + "title": "ThresholdsResourceUsageThresholdConfig", + "type": "object", + "x-expandableFields": ["meter"] + }, + "token": { + "description": "Tokenization is the process Stripe uses to collect sensitive card or bank\naccount details, or personally identifiable information (PII), directly from\nyour customers in a secure manner. A token representing this information is\nreturned to your server to use. Use our\n[recommended payments integrations](https://stripe.com/docs/payments) to perform this process\non the client-side. This guarantees that no sensitive card data touches your server,\nand allows your integration to operate in a PCI-compliant way.\n\nIf you can't use client-side tokenization, you can also create tokens using\nthe API with either your publishable or secret API key. If\nyour integration uses this method, you're responsible for any PCI compliance\nthat it might require, and you must keep your secret API key safe. Unlike with\nclient-side tokenization, your customer's information isn't sent directly to\nStripe, so we can't determine how it's handled or stored.\n\nYou can't store or use tokens more than once. To store card or bank account\ninformation for later use, create [Customer](https://stripe.com/docs/api#customers)\nobjects or [External accounts](/api#external_accounts).\n[Radar](https://stripe.com/docs/radar), our integrated solution for automatic fraud protection,\nperforms best with integrations that use client-side tokenization.", + "properties": { + "bank_account": { + "$ref": "#/components/schemas/bank_account" + }, + "card": { + "$ref": "#/components/schemas/card" + }, + "client_ip": { + "description": "IP address of the client that generates the token.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["token"], + "type": "string" + }, + "type": { + "description": "Type of the token: `account`, `bank_account`, `card`, or `pii`.", + "maxLength": 5000, + "type": "string" + }, + "used": { + "description": "Determines if you have already used this token (you can only use tokens once).", + "type": "boolean" + } + }, + "required": ["created", "id", "livemode", "object", "type", "used"], + "title": "Token", + "type": "object", + "x-expandableFields": ["bank_account", "card"], + "x-resourceId": "token" + }, + "token_card_networks": { + "description": "", + "properties": { + "preferred": { + "description": "The preferred network for co-branded cards. Can be `cartes_bancaires`, `mastercard`, `visa` or `invalid_preference` if requested network is not valid for the card.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "token_card_networks", + "type": "object", + "x-expandableFields": [] + }, + "topup": { + "description": "To top up your Stripe balance, you create a top-up object. You can retrieve\nindividual top-ups, as well as list all top-ups. Top-ups are identified by a\nunique, random ID.\n\nRelated guide: [Topping up your platform account](https://stripe.com/docs/connect/top-ups)", + "properties": { + "amount": { + "description": "Amount transferred.", + "type": "integer" + }, + "balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "ID of the balance transaction that describes the impact of this top-up on your account balance. May not be specified depending on status of top-up.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "expected_availability_date": { + "description": "Date the funds are expected to arrive in your Stripe account for payouts. This factors in delays like weekends or bank holidays. May not be specified depending on status of top-up.", + "nullable": true, + "type": "integer" + }, + "failure_code": { + "description": "Error code explaining reason for top-up failure if available (see [the errors section](https://stripe.com/docs/api#errors) for a list of codes).", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "failure_message": { + "description": "Message to user further explaining reason for top-up failure if available.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["topup"], + "type": "string" + }, + "source": { + "anyOf": [ + { + "$ref": "#/components/schemas/source" + } + ], + "description": "The source field is deprecated. It might not always be present in the API response.", + "nullable": true + }, + "statement_descriptor": { + "description": "Extra information about a top-up. This will appear on your source's bank statement. It must contain at least one letter.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "status": { + "description": "The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`.", + "enum": ["canceled", "failed", "pending", "reversed", "succeeded"], + "type": "string" + }, + "transfer_group": { + "description": "A string that identifies this top-up as part of a group.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": [ + "amount", + "created", + "currency", + "id", + "livemode", + "metadata", + "object", + "status" + ], + "title": "Topup", + "type": "object", + "x-expandableFields": ["balance_transaction", "source"], + "x-resourceId": "topup" + }, + "transfer": { + "description": "A `Transfer` object is created when you move funds between Stripe accounts as\npart of Connect.\n\nBefore April 6, 2017, transfers also represented movement of funds from a\nStripe account to a card or bank account. This behavior has since been split\nout into a [Payout](https://stripe.com/docs/api#payout_object) object, with corresponding payout endpoints. For more\ninformation, read about the\n[transfer/payout split](https://stripe.com/docs/transfer-payout-split).\n\nRelated guide: [Creating separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers)", + "properties": { + "amount": { + "description": "Amount in cents (or local equivalent) to be transferred.", + "type": "integer" + }, + "amount_reversed": { + "description": "Amount in cents (or local equivalent) reversed (can be less than the amount attribute on the transfer if a partial reversal was issued).", + "type": "integer" + }, + "balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "Balance transaction that describes the impact of this transfer on your account balance.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } + }, + "created": { + "description": "Time that this record of the transfer was first created.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "destination": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "ID of the Stripe account the transfer was sent to.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + }, + "destination_payment": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/charge" + } + ], + "description": "If the destination is a Stripe account, this will be the ID of the payment that the destination account received for the transfer.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/charge" + } + ] + } + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["transfer"], + "type": "string" + }, + "reversals": { + "description": "A list of reversals that have been applied to the transfer.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/transfer_reversal" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TransferReversalList", + "type": "object", + "x-expandableFields": ["data"] + }, + "reversed": { + "description": "Whether the transfer has been fully reversed. If the transfer is only partially reversed, this attribute will still be false.", + "type": "boolean" + }, + "source_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/charge" + } + ], + "description": "ID of the charge or payment that was used to fund the transfer. If null, the transfer was funded from the available balance.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/charge" + } + ] + } + }, + "source_type": { + "description": "The source balance this transfer came from. One of `card`, `fpx`, or `bank_account`.", + "maxLength": 5000, + "type": "string" + }, + "transfer_group": { + "description": "A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": [ + "amount", + "amount_reversed", + "created", + "currency", + "id", + "livemode", + "metadata", + "object", + "reversals", + "reversed" + ], + "title": "Transfer", + "type": "object", + "x-expandableFields": [ + "balance_transaction", + "destination", + "destination_payment", + "reversals", + "source_transaction" + ], + "x-resourceId": "transfer" + }, + "transfer_data": { + "description": "", + "properties": { + "amount": { + "description": "Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", + "type": "integer" + }, + "destination": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/account" + } + ], + "description": "The account (if any) that the payment is attributed to for tax\nreporting, and where funds from the payment are transferred to after\npayment success.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/account" + } + ] + } + } + }, + "required": ["destination"], + "title": "transfer_data", + "type": "object", + "x-expandableFields": ["destination"] + }, + "transfer_reversal": { + "description": "[Stripe Connect](https://stripe.com/docs/connect) platforms can reverse transfers made to a\nconnected account, either entirely or partially, and can also specify whether\nto refund any related application fees. Transfer reversals add to the\nplatform's balance and subtract from the destination account's balance.\n\nReversing a transfer that was made for a [destination\ncharge](/docs/connect/destination-charges) is allowed only up to the amount of\nthe charge. It is possible to reverse a\n[transfer_group](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options)\ntransfer only if the destination account has enough balance to cover the\nreversal.\n\nRelated guide: [Reverse transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#reverse-transfers)", + "properties": { + "amount": { + "description": "Amount, in cents (or local equivalent).", + "type": "integer" + }, + "balance_transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/balance_transaction" + } + ], + "description": "Balance transaction that describes the impact on your account balance.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/balance_transaction" + } + ] + } + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "destination_payment_refund": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/refund" + } + ], + "description": "Linked payment refund for the transfer reversal.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/refund" + } + ] + } + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["transfer_reversal"], + "type": "string" + }, + "source_refund": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/refund" + } + ], + "description": "ID of the refund responsible for the transfer reversal.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/refund" + } + ] + } + }, + "transfer": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/transfer" + } + ], + "description": "ID of the transfer that was reversed.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/transfer" + } + ] + } + } + }, + "required": [ + "amount", + "created", + "currency", + "id", + "object", + "transfer" + ], + "title": "TransferReversal", + "type": "object", + "x-expandableFields": [ + "balance_transaction", + "destination_payment_refund", + "source_refund", + "transfer" + ], + "x-resourceId": "transfer_reversal" + }, + "transfer_schedule": { + "description": "", + "properties": { + "delay_days": { + "description": "The number of days charges for the account will be held before being paid out.", + "type": "integer" + }, + "interval": { + "description": "How frequently funds will be paid out. One of `manual` (payouts only created via API call), `daily`, `weekly`, or `monthly`.", + "maxLength": 5000, + "type": "string" + }, + "monthly_anchor": { + "description": "The day of the month funds will be paid out. Only shown if `interval` is monthly. Payouts scheduled between the 29th and 31st of the month are sent on the last day of shorter months.", + "type": "integer" + }, + "weekly_anchor": { + "description": "The day of the week funds will be paid out, of the style 'monday', 'tuesday', etc. Only shown if `interval` is weekly.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["delay_days", "interval"], + "title": "TransferSchedule", + "type": "object", + "x-expandableFields": [] + }, + "transform_quantity": { + "description": "", + "properties": { + "divide_by": { + "description": "Divide usage by this number.", + "type": "integer" + }, + "round": { + "description": "After division, either round the result `up` or `down`.", + "enum": ["down", "up"], + "type": "string" + } + }, + "required": ["divide_by", "round"], + "title": "TransformQuantity", + "type": "object", + "x-expandableFields": [] + }, + "transform_usage": { + "description": "", + "properties": { + "divide_by": { + "description": "Divide usage by this number.", + "type": "integer" + }, + "round": { + "description": "After division, either round the result `up` or `down`.", + "enum": ["down", "up"], + "type": "string" + } + }, + "required": ["divide_by", "round"], + "title": "TransformUsage", + "type": "object", + "x-expandableFields": [] + }, + "treasury.credit_reversal": { + "description": "You can reverse some [ReceivedCredits](https://stripe.com/docs/api#received_credits) depending on their network and source flow. Reversing a ReceivedCredit leads to the creation of a new object known as a CreditReversal.", + "properties": { + "amount": { + "description": "Amount (in cents) transferred.", + "type": "integer" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "financial_account": { + "description": "The FinancialAccount to reverse funds from.", + "maxLength": 5000, + "type": "string" + }, + "hosted_regulatory_receipt_url": { + "description": "A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "network": { + "description": "The rails used to reverse the funds.", + "enum": ["ach", "stripe"], + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.credit_reversal"], + "type": "string" + }, + "received_credit": { + "description": "The ReceivedCredit being reversed.", + "maxLength": 5000, + "type": "string" + }, + "status": { + "description": "Status of the CreditReversal", + "enum": ["canceled", "posted", "processing"], + "type": "string" + }, + "status_transitions": { + "$ref": "#/components/schemas/treasury_received_credits_resource_status_transitions" + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + } + }, + "required": [ + "amount", + "created", + "currency", + "financial_account", + "id", + "livemode", + "metadata", + "network", + "object", + "received_credit", + "status", + "status_transitions" + ], + "title": "TreasuryReceivedCreditsResourceCreditReversal", + "type": "object", + "x-expandableFields": ["status_transitions", "transaction"], + "x-resourceId": "treasury.credit_reversal" + }, + "treasury.debit_reversal": { + "description": "You can reverse some [ReceivedDebits](https://stripe.com/docs/api#received_debits) depending on their network and source flow. Reversing a ReceivedDebit leads to the creation of a new object known as a DebitReversal.", + "properties": { + "amount": { + "description": "Amount (in cents) transferred.", + "type": "integer" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "financial_account": { + "description": "The FinancialAccount to reverse funds from.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "hosted_regulatory_receipt_url": { + "description": "A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "linked_flows": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_received_debits_resource_debit_reversal_linked_flows" + } + ], + "description": "Other flows linked to a DebitReversal.", + "nullable": true + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "network": { + "description": "The rails used to reverse the funds.", + "enum": ["ach", "card"], + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.debit_reversal"], + "type": "string" + }, + "received_debit": { + "description": "The ReceivedDebit being reversed.", + "maxLength": 5000, + "type": "string" + }, + "status": { + "description": "Status of the DebitReversal", + "enum": ["failed", "processing", "succeeded"], + "type": "string" + }, + "status_transitions": { + "$ref": "#/components/schemas/treasury_received_debits_resource_status_transitions" + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + } + }, + "required": [ + "amount", + "created", + "currency", + "id", + "livemode", + "metadata", + "network", + "object", + "received_debit", + "status", + "status_transitions" + ], + "title": "TreasuryReceivedDebitsResourceDebitReversal", + "type": "object", + "x-expandableFields": [ + "linked_flows", + "status_transitions", + "transaction" + ], + "x-resourceId": "treasury.debit_reversal" + }, + "treasury.financial_account": { + "description": "Stripe Treasury provides users with a container for money called a FinancialAccount that is separate from their Payments balance.\nFinancialAccounts serve as the source and destination of Treasury’s money movement APIs.", + "properties": { + "active_features": { + "description": "The array of paths to active Features in the Features hash.", + "items": { + "enum": [ + "card_issuing", + "deposit_insurance", + "financial_addresses.aba", + "financial_addresses.aba.forwarding", + "inbound_transfers.ach", + "intra_stripe_flows", + "outbound_payments.ach", + "outbound_payments.us_domestic_wire", + "outbound_transfers.ach", + "outbound_transfers.us_domestic_wire", + "remote_deposit_capture" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "balance": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_balance" + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "features": { + "$ref": "#/components/schemas/treasury.financial_account_features" + }, + "financial_addresses": { + "description": "The set of credentials that resolve to a FinancialAccount.", + "items": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_financial_address" + }, + "type": "array" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "nullable": true, + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.financial_account"], + "type": "string" + }, + "pending_features": { + "description": "The array of paths to pending Features in the Features hash.", + "items": { + "enum": [ + "card_issuing", + "deposit_insurance", + "financial_addresses.aba", + "financial_addresses.aba.forwarding", + "inbound_transfers.ach", + "intra_stripe_flows", + "outbound_payments.ach", + "outbound_payments.us_domestic_wire", + "outbound_transfers.ach", + "outbound_transfers.us_domestic_wire", + "remote_deposit_capture" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "platform_restrictions": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_platform_restrictions" + } + ], + "description": "The set of functionalities that the platform can restrict on the FinancialAccount.", + "nullable": true + }, + "restricted_features": { + "description": "The array of paths to restricted Features in the Features hash.", + "items": { + "enum": [ + "card_issuing", + "deposit_insurance", + "financial_addresses.aba", + "financial_addresses.aba.forwarding", + "inbound_transfers.ach", + "intra_stripe_flows", + "outbound_payments.ach", + "outbound_payments.us_domestic_wire", + "outbound_transfers.ach", + "outbound_transfers.us_domestic_wire", + "remote_deposit_capture" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "status": { + "description": "The enum specifying what state the account is in.", + "enum": ["closed", "open"], + "type": "string", + "x-stripeBypassValidation": true + }, + "status_details": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_status_details" + }, + "supported_currencies": { + "description": "The currencies the FinancialAccount can hold a balance in. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "balance", + "country", + "created", + "financial_addresses", + "id", + "livemode", + "object", + "status", + "status_details", + "supported_currencies" + ], + "title": "TreasuryFinancialAccountsResourceFinancialAccount", + "type": "object", + "x-expandableFields": [ + "balance", + "features", + "financial_addresses", + "platform_restrictions", + "status_details" + ], + "x-resourceId": "treasury.financial_account" + }, + "treasury.financial_account_features": { + "description": "Encodes whether a FinancialAccount has access to a particular Feature, with a `status` enum and associated `status_details`.\nStripe or the platform can control Features via the requested field.", + "properties": { + "card_issuing": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_toggle_settings" + }, + "deposit_insurance": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_toggle_settings" + }, + "financial_addresses": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_financial_addresses_features" + }, + "inbound_transfers": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_inbound_transfers" + }, + "intra_stripe_flows": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_toggle_settings" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.financial_account_features"], + "type": "string" + }, + "outbound_payments": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_outbound_payments" + }, + "outbound_transfers": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_outbound_transfers" + } + }, + "required": ["object"], + "title": "TreasuryFinancialAccountsResourceFinancialAccountFeatures", + "type": "object", + "x-expandableFields": [ + "card_issuing", + "deposit_insurance", + "financial_addresses", + "inbound_transfers", + "intra_stripe_flows", + "outbound_payments", + "outbound_transfers" + ], + "x-resourceId": "treasury.financial_account_features" + }, + "treasury.inbound_transfer": { + "description": "Use [InboundTransfers](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers) to add funds to your [FinancialAccount](https://stripe.com/docs/api#financial_accounts) via a PaymentMethod that is owned by you. The funds will be transferred via an ACH debit.\n\nRelated guide: [Moving money with Treasury using InboundTransfer objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers)", + "properties": { + "amount": { + "description": "Amount (in cents) transferred.", + "type": "integer" + }, + "cancelable": { + "description": "Returns `true` if the InboundTransfer is able to be canceled.", + "type": "boolean" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "failure_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_inbound_transfers_resource_failure_details" + } + ], + "description": "Details about this InboundTransfer's failure. Only set when status is `failed`.", + "nullable": true + }, + "financial_account": { + "description": "The FinancialAccount that received the funds.", + "maxLength": 5000, + "type": "string" + }, + "hosted_regulatory_receipt_url": { + "description": "A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "linked_flows": { + "$ref": "#/components/schemas/treasury_inbound_transfers_resource_inbound_transfer_resource_linked_flows" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.inbound_transfer"], + "type": "string" + }, + "origin_payment_method": { + "description": "The origin payment method to be debited for an InboundTransfer.", + "maxLength": 5000, + "type": "string" + }, + "origin_payment_method_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/inbound_transfers" + } + ], + "description": "Details about the PaymentMethod for an InboundTransfer.", + "nullable": true + }, + "returned": { + "description": "Returns `true` if the funds for an InboundTransfer were returned after the InboundTransfer went to the `succeeded` state.", + "nullable": true, + "type": "boolean" + }, + "statement_descriptor": { + "description": "Statement descriptor shown when funds are debited from the source. Not all payment networks support `statement_descriptor`.", + "maxLength": 5000, + "type": "string" + }, + "status": { + "description": "Status of the InboundTransfer: `processing`, `succeeded`, `failed`, and `canceled`. An InboundTransfer is `processing` if it is created and pending. The status changes to `succeeded` once the funds have been \"confirmed\" and a `transaction` is created and posted. The status changes to `failed` if the transfer fails.", + "enum": ["canceled", "failed", "processing", "succeeded"], + "type": "string" + }, + "status_transitions": { + "$ref": "#/components/schemas/treasury_inbound_transfers_resource_inbound_transfer_resource_status_transitions" + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + } + }, + "required": [ + "amount", + "cancelable", + "created", + "currency", + "financial_account", + "id", + "linked_flows", + "livemode", + "metadata", + "object", + "origin_payment_method", + "statement_descriptor", + "status", + "status_transitions" + ], + "title": "TreasuryInboundTransfersResourceInboundTransfer", + "type": "object", + "x-expandableFields": [ + "failure_details", + "linked_flows", + "origin_payment_method_details", + "status_transitions", + "transaction" + ], + "x-resourceId": "treasury.inbound_transfer" + }, + "treasury.outbound_payment": { + "description": "Use [OutboundPayments](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments) to send funds to another party's external bank account or [FinancialAccount](https://stripe.com/docs/api#financial_accounts). To send money to an account belonging to the same user, use an [OutboundTransfer](https://stripe.com/docs/api#outbound_transfers).\n\nSimulate OutboundPayment state changes with the `/v1/test_helpers/treasury/outbound_payments` endpoints. These methods can only be called on test mode objects.\n\nRelated guide: [Moving money with Treasury using OutboundPayment objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments)", + "properties": { + "amount": { + "description": "Amount (in cents) transferred.", + "type": "integer" + }, + "cancelable": { + "description": "Returns `true` if the object can be canceled, and `false` otherwise.", + "type": "boolean" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "ID of the [customer](https://stripe.com/docs/api/customers) to whom an OutboundPayment is sent.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "destination_payment_method": { + "description": "The PaymentMethod via which an OutboundPayment is sent. This field can be empty if the OutboundPayment was created using `destination_payment_method_data`.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "destination_payment_method_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/outbound_payments_payment_method_details" + } + ], + "description": "Details about the PaymentMethod for an OutboundPayment.", + "nullable": true + }, + "end_user_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_outbound_payments_resource_outbound_payment_resource_end_user_details" + } + ], + "description": "Details about the end user.", + "nullable": true + }, + "expected_arrival_date": { + "description": "The date when funds are expected to arrive in the destination account.", + "format": "unix-time", + "type": "integer" + }, + "financial_account": { + "description": "The FinancialAccount that funds were pulled from.", + "maxLength": 5000, + "type": "string" + }, + "hosted_regulatory_receipt_url": { + "description": "A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.outbound_payment"], + "type": "string" + }, + "returned_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_outbound_payments_resource_returned_status" + } + ], + "description": "Details about a returned OutboundPayment. Only set when the status is `returned`.", + "nullable": true + }, + "statement_descriptor": { + "description": "The description that appears on the receiving end for an OutboundPayment (for example, bank statement for external bank transfer).", + "maxLength": 5000, + "type": "string" + }, + "status": { + "description": "Current status of the OutboundPayment: `processing`, `failed`, `posted`, `returned`, `canceled`. An OutboundPayment is `processing` if it has been created and is pending. The status changes to `posted` once the OutboundPayment has been \"confirmed\" and funds have left the account, or to `failed` or `canceled`. If an OutboundPayment fails to arrive at its destination, its status will change to `returned`.", + "enum": ["canceled", "failed", "posted", "processing", "returned"], + "type": "string" + }, + "status_transitions": { + "$ref": "#/components/schemas/treasury_outbound_payments_resource_outbound_payment_resource_status_transitions" + }, + "tracking_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_outbound_payments_resource_outbound_payment_resource_tracking_details" + } + ], + "description": "Details about network-specific tracking information if available.", + "nullable": true + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + } + }, + "required": [ + "amount", + "cancelable", + "created", + "currency", + "expected_arrival_date", + "financial_account", + "id", + "livemode", + "metadata", + "object", + "statement_descriptor", + "status", + "status_transitions", + "transaction" + ], + "title": "TreasuryOutboundPaymentsResourceOutboundPayment", + "type": "object", + "x-expandableFields": [ + "destination_payment_method_details", + "end_user_details", + "returned_details", + "status_transitions", + "tracking_details", + "transaction" + ], + "x-resourceId": "treasury.outbound_payment" + }, + "treasury.outbound_transfer": { + "description": "Use [OutboundTransfers](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers) to transfer funds from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) to a PaymentMethod belonging to the same entity. To send funds to a different party, use [OutboundPayments](https://stripe.com/docs/api#outbound_payments) instead. You can send funds over ACH rails or through a domestic wire transfer to a user's own external bank account.\n\nSimulate OutboundTransfer state changes with the `/v1/test_helpers/treasury/outbound_transfers` endpoints. These methods can only be called on test mode objects.\n\nRelated guide: [Moving money with Treasury using OutboundTransfer objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers)", + "properties": { + "amount": { + "description": "Amount (in cents) transferred.", + "type": "integer" + }, + "cancelable": { + "description": "Returns `true` if the object can be canceled, and `false` otherwise.", + "type": "boolean" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "destination_payment_method": { + "description": "The PaymentMethod used as the payment instrument for an OutboundTransfer.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "destination_payment_method_details": { + "$ref": "#/components/schemas/outbound_transfers_payment_method_details" + }, + "expected_arrival_date": { + "description": "The date when funds are expected to arrive in the destination account.", + "format": "unix-time", + "type": "integer" + }, + "financial_account": { + "description": "The FinancialAccount that funds were pulled from.", + "maxLength": 5000, + "type": "string" + }, + "hosted_regulatory_receipt_url": { + "description": "A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.outbound_transfer"], + "type": "string" + }, + "returned_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_outbound_transfers_resource_returned_details" + } + ], + "description": "Details about a returned OutboundTransfer. Only set when the status is `returned`.", + "nullable": true + }, + "statement_descriptor": { + "description": "Information about the OutboundTransfer to be sent to the recipient account.", + "maxLength": 5000, + "type": "string" + }, + "status": { + "description": "Current status of the OutboundTransfer: `processing`, `failed`, `canceled`, `posted`, `returned`. An OutboundTransfer is `processing` if it has been created and is pending. The status changes to `posted` once the OutboundTransfer has been \"confirmed\" and funds have left the account, or to `failed` or `canceled`. If an OutboundTransfer fails to arrive at its destination, its status will change to `returned`.", + "enum": ["canceled", "failed", "posted", "processing", "returned"], + "type": "string" + }, + "status_transitions": { + "$ref": "#/components/schemas/treasury_outbound_transfers_resource_status_transitions" + }, + "tracking_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_outbound_transfers_resource_outbound_transfer_resource_tracking_details" + } + ], + "description": "Details about network-specific tracking information if available.", + "nullable": true + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + } + }, + "required": [ + "amount", + "cancelable", + "created", + "currency", + "destination_payment_method_details", + "expected_arrival_date", + "financial_account", + "id", + "livemode", + "metadata", + "object", + "statement_descriptor", + "status", + "status_transitions", + "transaction" + ], + "title": "TreasuryOutboundTransfersResourceOutboundTransfer", + "type": "object", + "x-expandableFields": [ + "destination_payment_method_details", + "returned_details", + "status_transitions", + "tracking_details", + "transaction" + ], + "x-resourceId": "treasury.outbound_transfer" + }, + "treasury.received_credit": { + "description": "ReceivedCredits represent funds sent to a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) (for example, via ACH or wire). These money movements are not initiated from the FinancialAccount.", + "properties": { + "amount": { + "description": "Amount (in cents) transferred.", + "type": "integer" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "type": "string" + }, + "failure_code": { + "description": "Reason for the failure. A ReceivedCredit might fail because the receiving FinancialAccount is closed or frozen.", + "enum": ["account_closed", "account_frozen", "other"], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "financial_account": { + "description": "The FinancialAccount that received the funds.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "hosted_regulatory_receipt_url": { + "description": "A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "initiating_payment_method_details": { + "$ref": "#/components/schemas/treasury_shared_resource_initiating_payment_method_details_initiating_payment_method_details" + }, + "linked_flows": { + "$ref": "#/components/schemas/treasury_received_credits_resource_linked_flows" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "network": { + "description": "The rails used to send the funds.", + "enum": ["ach", "card", "stripe", "us_domestic_wire"], + "type": "string", + "x-stripeBypassValidation": true + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.received_credit"], + "type": "string" + }, + "reversal_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_received_credits_resource_reversal_details" + } + ], + "description": "Details describing when a ReceivedCredit may be reversed.", + "nullable": true + }, + "status": { + "description": "Status of the ReceivedCredit. ReceivedCredits are created either `succeeded` (approved) or `failed` (declined). If a ReceivedCredit is declined, the failure reason can be found in the `failure_code` field.", + "enum": ["failed", "succeeded"], + "type": "string", + "x-stripeBypassValidation": true + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + } + }, + "required": [ + "amount", + "created", + "currency", + "description", + "id", + "initiating_payment_method_details", + "linked_flows", + "livemode", + "network", + "object", + "status" + ], + "title": "TreasuryReceivedCreditsResourceReceivedCredit", + "type": "object", + "x-expandableFields": [ + "initiating_payment_method_details", + "linked_flows", + "reversal_details", + "transaction" + ], + "x-resourceId": "treasury.received_credit" + }, + "treasury.received_debit": { + "description": "ReceivedDebits represent funds pulled from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts). These are not initiated from the FinancialAccount.", + "properties": { + "amount": { + "description": "Amount (in cents) transferred.", + "type": "integer" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "type": "string" + }, + "failure_code": { + "description": "Reason for the failure. A ReceivedDebit might fail because the FinancialAccount doesn't have sufficient funds, is closed, or is frozen.", + "enum": [ + "account_closed", + "account_frozen", + "insufficient_funds", + "other" + ], + "nullable": true, + "type": "string" + }, + "financial_account": { + "description": "The FinancialAccount that funds were pulled from.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "hosted_regulatory_receipt_url": { + "description": "A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "initiating_payment_method_details": { + "$ref": "#/components/schemas/treasury_shared_resource_initiating_payment_method_details_initiating_payment_method_details" + }, + "linked_flows": { + "$ref": "#/components/schemas/treasury_received_debits_resource_linked_flows" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "network": { + "description": "The network used for the ReceivedDebit.", + "enum": ["ach", "card", "stripe"], + "type": "string", + "x-stripeBypassValidation": true + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.received_debit"], + "type": "string" + }, + "reversal_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_received_debits_resource_reversal_details" + } + ], + "description": "Details describing when a ReceivedDebit might be reversed.", + "nullable": true + }, + "status": { + "description": "Status of the ReceivedDebit. ReceivedDebits are created with a status of either `succeeded` (approved) or `failed` (declined). The failure reason can be found under the `failure_code`.", + "enum": ["failed", "succeeded"], + "type": "string", + "x-stripeBypassValidation": true + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "nullable": true, + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + } + }, + "required": [ + "amount", + "created", + "currency", + "description", + "id", + "linked_flows", + "livemode", + "network", + "object", + "status" + ], + "title": "TreasuryReceivedDebitsResourceReceivedDebit", + "type": "object", + "x-expandableFields": [ + "initiating_payment_method_details", + "linked_flows", + "reversal_details", + "transaction" + ], + "x-resourceId": "treasury.received_debit" + }, + "treasury.transaction": { + "description": "Transactions represent changes to a [FinancialAccount's](https://stripe.com/docs/api#financial_accounts) balance.", + "properties": { + "amount": { + "description": "Amount (in cents) transferred.", + "type": "integer" + }, + "balance_impact": { + "$ref": "#/components/schemas/treasury_transactions_resource_balance_impact" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "type": "string" + }, + "entries": { + "description": "A list of TransactionEntries that are part of this Transaction. This cannot be expanded in any list endpoints.", + "nullable": true, + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/treasury.transaction_entry" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/treasury/transaction_entries", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TreasuryTransactionsResourceTransactionEntryList", + "type": "object", + "x-expandableFields": ["data"] + }, + "financial_account": { + "description": "The FinancialAccount associated with this object.", + "maxLength": 5000, + "type": "string" + }, + "flow": { + "description": "ID of the flow that created the Transaction.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "flow_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_transactions_resource_flow_details" + } + ], + "description": "Details of the flow that created the Transaction.", + "nullable": true + }, + "flow_type": { + "description": "Type of the flow that created the Transaction.", + "enum": [ + "credit_reversal", + "debit_reversal", + "inbound_transfer", + "issuing_authorization", + "other", + "outbound_payment", + "outbound_transfer", + "received_credit", + "received_debit" + ], + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.transaction"], + "type": "string" + }, + "status": { + "description": "Status of the Transaction.", + "enum": ["open", "posted", "void"], + "type": "string" + }, + "status_transitions": { + "$ref": "#/components/schemas/treasury_transactions_resource_abstract_transaction_resource_status_transitions" + } + }, + "required": [ + "amount", + "balance_impact", + "created", + "currency", + "description", + "financial_account", + "flow_type", + "id", + "livemode", + "object", + "status", + "status_transitions" + ], + "title": "TreasuryTransactionsResourceTransaction", + "type": "object", + "x-expandableFields": [ + "balance_impact", + "entries", + "flow_details", + "status_transitions" + ], + "x-resourceId": "treasury.transaction" + }, + "treasury.transaction_entry": { + "description": "TransactionEntries represent individual units of money movements within a single [Transaction](https://stripe.com/docs/api#transactions).", + "properties": { + "balance_impact": { + "$ref": "#/components/schemas/treasury_transactions_resource_balance_impact" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "effective_at": { + "description": "When the TransactionEntry will impact the FinancialAccount's balance.", + "format": "unix-time", + "type": "integer" + }, + "financial_account": { + "description": "The FinancialAccount associated with this object.", + "maxLength": 5000, + "type": "string" + }, + "flow": { + "description": "Token of the flow associated with the TransactionEntry.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "flow_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_transactions_resource_flow_details" + } + ], + "description": "Details of the flow associated with the TransactionEntry.", + "nullable": true + }, + "flow_type": { + "description": "Type of the flow associated with the TransactionEntry.", + "enum": [ + "credit_reversal", + "debit_reversal", + "inbound_transfer", + "issuing_authorization", + "other", + "outbound_payment", + "outbound_transfer", + "received_credit", + "received_debit" + ], + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["treasury.transaction_entry"], + "type": "string" + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + }, + "type": { + "description": "The specific money movement that generated the TransactionEntry.", + "enum": [ + "credit_reversal", + "credit_reversal_posting", + "debit_reversal", + "inbound_transfer", + "inbound_transfer_return", + "issuing_authorization_hold", + "issuing_authorization_release", + "other", + "outbound_payment", + "outbound_payment_cancellation", + "outbound_payment_failure", + "outbound_payment_posting", + "outbound_payment_return", + "outbound_transfer", + "outbound_transfer_cancellation", + "outbound_transfer_failure", + "outbound_transfer_posting", + "outbound_transfer_return", + "received_credit", + "received_debit" + ], + "type": "string" + } + }, + "required": [ + "balance_impact", + "created", + "currency", + "effective_at", + "financial_account", + "flow_type", + "id", + "livemode", + "object", + "transaction", + "type" + ], + "title": "TreasuryTransactionsResourceTransactionEntry", + "type": "object", + "x-expandableFields": ["balance_impact", "flow_details", "transaction"], + "x-resourceId": "treasury.transaction_entry" + }, + "treasury_financial_accounts_resource_aba_record": { + "description": "ABA Records contain U.S. bank account details per the ABA format.", + "properties": { + "account_holder_name": { + "description": "The name of the person or business that owns the bank account.", + "maxLength": 5000, + "type": "string" + }, + "account_number": { + "description": "The account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "account_number_last4": { + "description": "The last four characters of the account number.", + "maxLength": 5000, + "type": "string" + }, + "bank_name": { + "description": "Name of the bank.", + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "description": "Routing number for the account.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "account_holder_name", + "account_number_last4", + "bank_name", + "routing_number" + ], + "title": "TreasuryFinancialAccountsResourceABARecord", + "type": "object", + "x-expandableFields": [] + }, + "treasury_financial_accounts_resource_aba_toggle_settings": { + "description": "Toggle settings for enabling/disabling the ABA address feature", + "properties": { + "requested": { + "description": "Whether the FinancialAccount should have the Feature.", + "type": "boolean" + }, + "status": { + "description": "Whether the Feature is operational.", + "enum": ["active", "pending", "restricted"], + "type": "string" + }, + "status_details": { + "description": "Additional details; includes at least one entry when the status is not `active`.", + "items": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_toggles_setting_status_details" + }, + "type": "array" + } + }, + "required": ["requested", "status", "status_details"], + "title": "TreasuryFinancialAccountsResourceAbaToggleSettings", + "type": "object", + "x-expandableFields": ["status_details"] + }, + "treasury_financial_accounts_resource_ach_toggle_settings": { + "description": "Toggle settings for enabling/disabling an ACH specific feature", + "properties": { + "requested": { + "description": "Whether the FinancialAccount should have the Feature.", + "type": "boolean" + }, + "status": { + "description": "Whether the Feature is operational.", + "enum": ["active", "pending", "restricted"], + "type": "string" + }, + "status_details": { + "description": "Additional details; includes at least one entry when the status is not `active`.", + "items": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_toggles_setting_status_details" + }, + "type": "array" + } + }, + "required": ["requested", "status", "status_details"], + "title": "TreasuryFinancialAccountsResourceAchToggleSettings", + "type": "object", + "x-expandableFields": ["status_details"] + }, + "treasury_financial_accounts_resource_balance": { + "description": "Balance information for the FinancialAccount", + "properties": { + "cash": { + "additionalProperties": { + "type": "integer" + }, + "description": "Funds the user can spend right now.", + "type": "object" + }, + "inbound_pending": { + "additionalProperties": { + "type": "integer" + }, + "description": "Funds not spendable yet, but will become available at a later time.", + "type": "object" + }, + "outbound_pending": { + "additionalProperties": { + "type": "integer" + }, + "description": "Funds in the account, but not spendable because they are being held for pending outbound flows.", + "type": "object" + } + }, + "required": ["cash", "inbound_pending", "outbound_pending"], + "title": "TreasuryFinancialAccountsResourceBalance", + "type": "object", + "x-expandableFields": [] + }, + "treasury_financial_accounts_resource_closed_status_details": { + "description": "", + "properties": { + "reasons": { + "description": "The array that contains reasons for a FinancialAccount closure.", + "items": { + "enum": ["account_rejected", "closed_by_platform", "other"], + "type": "string" + }, + "type": "array" + } + }, + "required": ["reasons"], + "title": "TreasuryFinancialAccountsResourceClosedStatusDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_financial_accounts_resource_financial_address": { + "description": "FinancialAddresses contain identifying information that resolves to a FinancialAccount.", + "properties": { + "aba": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_aba_record" + }, + "supported_networks": { + "description": "The list of networks that the address supports", + "items": { + "enum": ["ach", "us_domestic_wire"], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "type": { + "description": "The type of financial address", + "enum": ["aba"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "TreasuryFinancialAccountsResourceFinancialAddress", + "type": "object", + "x-expandableFields": ["aba"] + }, + "treasury_financial_accounts_resource_financial_addresses_features": { + "description": "Settings related to Financial Addresses features on a Financial Account", + "properties": { + "aba": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_aba_toggle_settings" + } + }, + "title": "TreasuryFinancialAccountsResourceFinancialAddressesFeatures", + "type": "object", + "x-expandableFields": ["aba"] + }, + "treasury_financial_accounts_resource_inbound_transfers": { + "description": "InboundTransfers contains inbound transfers features for a FinancialAccount.", + "properties": { + "ach": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_ach_toggle_settings" + } + }, + "title": "TreasuryFinancialAccountsResourceInboundTransfers", + "type": "object", + "x-expandableFields": ["ach"] + }, + "treasury_financial_accounts_resource_outbound_payments": { + "description": "Settings related to Outbound Payments features on a Financial Account", + "properties": { + "ach": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_ach_toggle_settings" + }, + "us_domestic_wire": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_toggle_settings" + } + }, + "title": "TreasuryFinancialAccountsResourceOutboundPayments", + "type": "object", + "x-expandableFields": ["ach", "us_domestic_wire"] + }, + "treasury_financial_accounts_resource_outbound_transfers": { + "description": "OutboundTransfers contains outbound transfers features for a FinancialAccount.", + "properties": { + "ach": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_ach_toggle_settings" + }, + "us_domestic_wire": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_toggle_settings" + } + }, + "title": "TreasuryFinancialAccountsResourceOutboundTransfers", + "type": "object", + "x-expandableFields": ["ach", "us_domestic_wire"] + }, + "treasury_financial_accounts_resource_platform_restrictions": { + "description": "Restrictions that a Connect Platform has placed on this FinancialAccount.", + "properties": { + "inbound_flows": { + "description": "Restricts all inbound money movement.", + "enum": ["restricted", "unrestricted"], + "nullable": true, + "type": "string" + }, + "outbound_flows": { + "description": "Restricts all outbound money movement.", + "enum": ["restricted", "unrestricted"], + "nullable": true, + "type": "string" + } + }, + "title": "TreasuryFinancialAccountsResourcePlatformRestrictions", + "type": "object", + "x-expandableFields": [] + }, + "treasury_financial_accounts_resource_status_details": { + "description": "", + "properties": { + "closed": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_closed_status_details" + } + ], + "description": "Details related to the closure of this FinancialAccount", + "nullable": true + } + }, + "title": "TreasuryFinancialAccountsResourceStatusDetails", + "type": "object", + "x-expandableFields": ["closed"] + }, + "treasury_financial_accounts_resource_toggle_settings": { + "description": "Toggle settings for enabling/disabling a feature", + "properties": { + "requested": { + "description": "Whether the FinancialAccount should have the Feature.", + "type": "boolean" + }, + "status": { + "description": "Whether the Feature is operational.", + "enum": ["active", "pending", "restricted"], + "type": "string" + }, + "status_details": { + "description": "Additional details; includes at least one entry when the status is not `active`.", + "items": { + "$ref": "#/components/schemas/treasury_financial_accounts_resource_toggles_setting_status_details" + }, + "type": "array" + } + }, + "required": ["requested", "status", "status_details"], + "title": "TreasuryFinancialAccountsResourceToggleSettings", + "type": "object", + "x-expandableFields": ["status_details"] + }, + "treasury_financial_accounts_resource_toggles_setting_status_details": { + "description": "Additional details on the FinancialAccount Features information.", + "properties": { + "code": { + "description": "Represents the reason why the status is `pending` or `restricted`.", + "enum": [ + "activating", + "capability_not_requested", + "financial_account_closed", + "rejected_other", + "rejected_unsupported_business", + "requirements_past_due", + "requirements_pending_verification", + "restricted_by_platform", + "restricted_other" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "resolution": { + "description": "Represents what the user should do, if anything, to activate the Feature.", + "enum": [ + "contact_stripe", + "provide_information", + "remove_restriction" + ], + "nullable": true, + "type": "string", + "x-stripeBypassValidation": true + }, + "restriction": { + "description": "The `platform_restrictions` that are restricting this Feature.", + "enum": ["inbound_flows", "outbound_flows"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["code"], + "title": "TreasuryFinancialAccountsResourceTogglesSettingStatusDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_inbound_transfers_resource_failure_details": { + "description": "", + "properties": { + "code": { + "description": "Reason for the failure.", + "enum": [ + "account_closed", + "account_frozen", + "bank_account_restricted", + "bank_ownership_changed", + "debit_not_authorized", + "incorrect_account_holder_address", + "incorrect_account_holder_name", + "incorrect_account_holder_tax_id", + "insufficient_funds", + "invalid_account_number", + "invalid_currency", + "no_account", + "other" + ], + "type": "string" + } + }, + "required": ["code"], + "title": "TreasuryInboundTransfersResourceFailureDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_inbound_transfers_resource_inbound_transfer_resource_linked_flows": { + "description": "", + "properties": { + "received_debit": { + "description": "If funds for this flow were returned after the flow went to the `succeeded` state, this field contains a reference to the ReceivedDebit return.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "TreasuryInboundTransfersResourceInboundTransferResourceLinkedFlows", + "type": "object", + "x-expandableFields": [] + }, + "treasury_inbound_transfers_resource_inbound_transfer_resource_status_transitions": { + "description": "", + "properties": { + "canceled_at": { + "description": "Timestamp describing when an InboundTransfer changed status to `canceled`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "failed_at": { + "description": "Timestamp describing when an InboundTransfer changed status to `failed`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "succeeded_at": { + "description": "Timestamp describing when an InboundTransfer changed status to `succeeded`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "title": "TreasuryInboundTransfersResourceInboundTransferResourceStatusTransitions", + "type": "object", + "x-expandableFields": [] + }, + "treasury_outbound_payments_resource_ach_tracking_details": { + "description": "", + "properties": { + "trace_id": { + "description": "ACH trace ID of the OutboundPayment for payments sent over the `ach` network.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["trace_id"], + "title": "TreasuryOutboundPaymentsResourceACHTrackingDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_outbound_payments_resource_outbound_payment_resource_end_user_details": { + "description": "", + "properties": { + "ip_address": { + "description": "IP address of the user initiating the OutboundPayment. Set if `present` is set to `true`. IP address collection is required for risk and compliance reasons. This will be used to help determine if the OutboundPayment is authorized or should be blocked.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "present": { + "description": "`true` if the OutboundPayment creation request is being made on behalf of an end user by a platform. Otherwise, `false`.", + "type": "boolean" + } + }, + "required": ["present"], + "title": "TreasuryOutboundPaymentsResourceOutboundPaymentResourceEndUserDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_outbound_payments_resource_outbound_payment_resource_status_transitions": { + "description": "", + "properties": { + "canceled_at": { + "description": "Timestamp describing when an OutboundPayment changed status to `canceled`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "failed_at": { + "description": "Timestamp describing when an OutboundPayment changed status to `failed`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "posted_at": { + "description": "Timestamp describing when an OutboundPayment changed status to `posted`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "returned_at": { + "description": "Timestamp describing when an OutboundPayment changed status to `returned`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "title": "TreasuryOutboundPaymentsResourceOutboundPaymentResourceStatusTransitions", + "type": "object", + "x-expandableFields": [] + }, + "treasury_outbound_payments_resource_outbound_payment_resource_tracking_details": { + "description": "", + "properties": { + "ach": { + "$ref": "#/components/schemas/treasury_outbound_payments_resource_ach_tracking_details" + }, + "type": { + "description": "The US bank account network used to send funds.", + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "us_domestic_wire": { + "$ref": "#/components/schemas/treasury_outbound_payments_resource_us_domestic_wire_tracking_details" + } + }, + "required": ["type"], + "title": "TreasuryOutboundPaymentsResourceOutboundPaymentResourceTrackingDetails", + "type": "object", + "x-expandableFields": ["ach", "us_domestic_wire"] + }, + "treasury_outbound_payments_resource_returned_status": { + "description": "", + "properties": { + "code": { + "description": "Reason for the return.", + "enum": [ + "account_closed", + "account_frozen", + "bank_account_restricted", + "bank_ownership_changed", + "declined", + "incorrect_account_holder_name", + "invalid_account_number", + "invalid_currency", + "no_account", + "other" + ], + "type": "string" + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + } + }, + "required": ["code", "transaction"], + "title": "TreasuryOutboundPaymentsResourceReturnedStatus", + "type": "object", + "x-expandableFields": ["transaction"] + }, + "treasury_outbound_payments_resource_us_domestic_wire_tracking_details": { + "description": "", + "properties": { + "chips": { + "description": "CHIPS System Sequence Number (SSN) of the OutboundPayment for payments sent over the `us_domestic_wire` network.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "imad": { + "description": "IMAD of the OutboundPayment for payments sent over the `us_domestic_wire` network.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "omad": { + "description": "OMAD of the OutboundPayment for payments sent over the `us_domestic_wire` network.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "TreasuryOutboundPaymentsResourceUSDomesticWireTrackingDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_outbound_transfers_resource_ach_tracking_details": { + "description": "", + "properties": { + "trace_id": { + "description": "ACH trace ID of the OutboundTransfer for transfers sent over the `ach` network.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["trace_id"], + "title": "TreasuryOutboundTransfersResourceACHTrackingDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_outbound_transfers_resource_outbound_transfer_resource_tracking_details": { + "description": "", + "properties": { + "ach": { + "$ref": "#/components/schemas/treasury_outbound_transfers_resource_ach_tracking_details" + }, + "type": { + "description": "The US bank account network used to send funds.", + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "us_domestic_wire": { + "$ref": "#/components/schemas/treasury_outbound_transfers_resource_us_domestic_wire_tracking_details" + } + }, + "required": ["type"], + "title": "TreasuryOutboundTransfersResourceOutboundTransferResourceTrackingDetails", + "type": "object", + "x-expandableFields": ["ach", "us_domestic_wire"] + }, + "treasury_outbound_transfers_resource_returned_details": { + "description": "", + "properties": { + "code": { + "description": "Reason for the return.", + "enum": [ + "account_closed", + "account_frozen", + "bank_account_restricted", + "bank_ownership_changed", + "declined", + "incorrect_account_holder_name", + "invalid_account_number", + "invalid_currency", + "no_account", + "other" + ], + "type": "string" + }, + "transaction": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "$ref": "#/components/schemas/treasury.transaction" + } + ], + "description": "The Transaction associated with this object.", + "x-expansionResources": { + "oneOf": [ + { + "$ref": "#/components/schemas/treasury.transaction" + } + ] + } + } + }, + "required": ["code", "transaction"], + "title": "TreasuryOutboundTransfersResourceReturnedDetails", + "type": "object", + "x-expandableFields": ["transaction"] + }, + "treasury_outbound_transfers_resource_status_transitions": { + "description": "", + "properties": { + "canceled_at": { + "description": "Timestamp describing when an OutboundTransfer changed status to `canceled`", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "failed_at": { + "description": "Timestamp describing when an OutboundTransfer changed status to `failed`", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "posted_at": { + "description": "Timestamp describing when an OutboundTransfer changed status to `posted`", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "returned_at": { + "description": "Timestamp describing when an OutboundTransfer changed status to `returned`", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "title": "TreasuryOutboundTransfersResourceStatusTransitions", + "type": "object", + "x-expandableFields": [] + }, + "treasury_outbound_transfers_resource_us_domestic_wire_tracking_details": { + "description": "", + "properties": { + "chips": { + "description": "CHIPS System Sequence Number (SSN) of the OutboundTransfer for transfers sent over the `us_domestic_wire` network.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "imad": { + "description": "IMAD of the OutboundTransfer for transfers sent over the `us_domestic_wire` network.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "omad": { + "description": "OMAD of the OutboundTransfer for transfers sent over the `us_domestic_wire` network.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "TreasuryOutboundTransfersResourceUSDomesticWireTrackingDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_received_credits_resource_linked_flows": { + "description": "", + "properties": { + "credit_reversal": { + "description": "The CreditReversal created as a result of this ReceivedCredit being reversed.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "issuing_authorization": { + "description": "Set if the ReceivedCredit was created due to an [Issuing Authorization](https://stripe.com/docs/api#issuing_authorizations) object.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "issuing_transaction": { + "description": "Set if the ReceivedCredit is also viewable as an [Issuing transaction](https://stripe.com/docs/api#issuing_transactions) object.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "source_flow": { + "description": "ID of the source flow. Set if `network` is `stripe` and the source flow is visible to the user. Examples of source flows include OutboundPayments, payouts, or CreditReversals.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "source_flow_details": { + "anyOf": [ + { + "$ref": "#/components/schemas/treasury_received_credits_resource_source_flows_details" + } + ], + "description": "The expandable object of the source flow.", + "nullable": true + }, + "source_flow_type": { + "description": "The type of flow that originated the ReceivedCredit (for example, `outbound_payment`).", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "TreasuryReceivedCreditsResourceLinkedFlows", + "type": "object", + "x-expandableFields": ["source_flow_details"] + }, + "treasury_received_credits_resource_reversal_details": { + "description": "", + "properties": { + "deadline": { + "description": "Time before which a ReceivedCredit can be reversed.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "restricted_reason": { + "description": "Set if a ReceivedCredit cannot be reversed.", + "enum": [ + "already_reversed", + "deadline_passed", + "network_restricted", + "other", + "source_flow_restricted" + ], + "nullable": true, + "type": "string" + } + }, + "title": "TreasuryReceivedCreditsResourceReversalDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_received_credits_resource_source_flows_details": { + "description": "", + "properties": { + "credit_reversal": { + "$ref": "#/components/schemas/treasury.credit_reversal" + }, + "outbound_payment": { + "$ref": "#/components/schemas/treasury.outbound_payment" + }, + "payout": { + "$ref": "#/components/schemas/payout" + }, + "type": { + "description": "The type of the source flow that originated the ReceivedCredit.", + "enum": ["credit_reversal", "other", "outbound_payment", "payout"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "TreasuryReceivedCreditsResourceSourceFlowsDetails", + "type": "object", + "x-expandableFields": ["credit_reversal", "outbound_payment", "payout"] + }, + "treasury_received_credits_resource_status_transitions": { + "description": "", + "properties": { + "posted_at": { + "description": "Timestamp describing when the CreditReversal changed status to `posted`", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "title": "TreasuryReceivedCreditsResourceStatusTransitions", + "type": "object", + "x-expandableFields": [] + }, + "treasury_received_debits_resource_debit_reversal_linked_flows": { + "description": "", + "properties": { + "issuing_dispute": { + "description": "Set if there is an Issuing dispute associated with the DebitReversal.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "TreasuryReceivedDebitsResourceDebitReversalLinkedFlows", + "type": "object", + "x-expandableFields": [] + }, + "treasury_received_debits_resource_linked_flows": { + "description": "", + "properties": { + "debit_reversal": { + "description": "The DebitReversal created as a result of this ReceivedDebit being reversed.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "inbound_transfer": { + "description": "Set if the ReceivedDebit is associated with an InboundTransfer's return of funds.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "issuing_authorization": { + "description": "Set if the ReceivedDebit was created due to an [Issuing Authorization](https://stripe.com/docs/api#issuing_authorizations) object.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "issuing_transaction": { + "description": "Set if the ReceivedDebit is also viewable as an [Issuing Dispute](https://stripe.com/docs/api#issuing_disputes) object.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "payout": { + "description": "Set if the ReceivedDebit was created due to a [Payout](https://stripe.com/docs/api#payouts) object.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "TreasuryReceivedDebitsResourceLinkedFlows", + "type": "object", + "x-expandableFields": [] + }, + "treasury_received_debits_resource_reversal_details": { + "description": "", + "properties": { + "deadline": { + "description": "Time before which a ReceivedDebit can be reversed.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "restricted_reason": { + "description": "Set if a ReceivedDebit can't be reversed.", + "enum": [ + "already_reversed", + "deadline_passed", + "network_restricted", + "other", + "source_flow_restricted" + ], + "nullable": true, + "type": "string" + } + }, + "title": "TreasuryReceivedDebitsResourceReversalDetails", + "type": "object", + "x-expandableFields": [] + }, + "treasury_received_debits_resource_status_transitions": { + "description": "", + "properties": { + "completed_at": { + "description": "Timestamp describing when the DebitReversal changed status to `completed`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "title": "TreasuryReceivedDebitsResourceStatusTransitions", + "type": "object", + "x-expandableFields": [] + }, + "treasury_shared_resource_billing_details": { + "description": "", + "properties": { + "address": { + "$ref": "#/components/schemas/address" + }, + "email": { + "description": "Email address.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "name": { + "description": "Full name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": ["address"], + "title": "TreasurySharedResourceBillingDetails", + "type": "object", + "x-expandableFields": ["address"] + }, + "treasury_shared_resource_initiating_payment_method_details_initiating_payment_method_details": { + "description": "", + "properties": { + "balance": { + "description": "Set when `type` is `balance`.", + "enum": ["payments"], + "type": "string" + }, + "billing_details": { + "$ref": "#/components/schemas/treasury_shared_resource_billing_details" + }, + "financial_account": { + "$ref": "#/components/schemas/received_payment_method_details_financial_account" + }, + "issuing_card": { + "description": "Set when `type` is `issuing_card`. This is an [Issuing Card](https://stripe.com/docs/api#issuing_cards) ID.", + "maxLength": 5000, + "type": "string" + }, + "type": { + "description": "Polymorphic type matching the originating money movement's source. This can be an external account, a Stripe balance, or a FinancialAccount.", + "enum": [ + "balance", + "financial_account", + "issuing_card", + "stripe", + "us_bank_account" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "$ref": "#/components/schemas/treasury_shared_resource_initiating_payment_method_details_us_bank_account" + } + }, + "required": ["billing_details", "type"], + "title": "TreasurySharedResourceInitiatingPaymentMethodDetailsInitiatingPaymentMethodDetails", + "type": "object", + "x-expandableFields": [ + "billing_details", + "financial_account", + "us_bank_account" + ] + }, + "treasury_shared_resource_initiating_payment_method_details_us_bank_account": { + "description": "", + "properties": { + "bank_name": { + "description": "Bank name.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "last4": { + "description": "The last four digits of the bank account number.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "routing_number": { + "description": "The routing number for the bank account.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "title": "TreasurySharedResourceInitiatingPaymentMethodDetailsUSBankAccount", + "type": "object", + "x-expandableFields": [] + }, + "treasury_transactions_resource_abstract_transaction_resource_status_transitions": { + "description": "", + "properties": { + "posted_at": { + "description": "Timestamp describing when the Transaction changed status to `posted`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, + "void_at": { + "description": "Timestamp describing when the Transaction changed status to `void`.", + "format": "unix-time", + "nullable": true, + "type": "integer" + } + }, + "title": "TreasuryTransactionsResourceAbstractTransactionResourceStatusTransitions", + "type": "object", + "x-expandableFields": [] + }, + "treasury_transactions_resource_balance_impact": { + "description": "Change to a FinancialAccount's balance", + "properties": { + "cash": { + "description": "The change made to funds the user can spend right now.", + "type": "integer" + }, + "inbound_pending": { + "description": "The change made to funds that are not spendable yet, but will become available at a later time.", + "type": "integer" + }, + "outbound_pending": { + "description": "The change made to funds in the account, but not spendable because they are being held for pending outbound flows.", + "type": "integer" + } + }, + "required": ["cash", "inbound_pending", "outbound_pending"], + "title": "TreasuryTransactionsResourceBalanceImpact", + "type": "object", + "x-expandableFields": [] + }, + "treasury_transactions_resource_flow_details": { + "description": "", + "properties": { + "credit_reversal": { + "$ref": "#/components/schemas/treasury.credit_reversal" + }, + "debit_reversal": { + "$ref": "#/components/schemas/treasury.debit_reversal" + }, + "inbound_transfer": { + "$ref": "#/components/schemas/treasury.inbound_transfer" + }, + "issuing_authorization": { + "$ref": "#/components/schemas/issuing.authorization" + }, + "outbound_payment": { + "$ref": "#/components/schemas/treasury.outbound_payment" + }, + "outbound_transfer": { + "$ref": "#/components/schemas/treasury.outbound_transfer" + }, + "received_credit": { + "$ref": "#/components/schemas/treasury.received_credit" + }, + "received_debit": { + "$ref": "#/components/schemas/treasury.received_debit" + }, + "type": { + "description": "Type of the flow that created the Transaction. Set to the same value as `flow_type`.", + "enum": [ + "credit_reversal", + "debit_reversal", + "inbound_transfer", + "issuing_authorization", + "other", + "outbound_payment", + "outbound_transfer", + "received_credit", + "received_debit" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "TreasuryTransactionsResourceFlowDetails", + "type": "object", + "x-expandableFields": [ + "credit_reversal", + "debit_reversal", + "inbound_transfer", + "issuing_authorization", + "outbound_payment", + "outbound_transfer", + "received_credit", + "received_debit" + ] + }, + "us_bank_account_networks": { + "description": "", + "properties": { + "preferred": { + "description": "The preferred network.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "supported": { + "description": "All supported networks.", + "items": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "type": "array" + } + }, + "required": ["supported"], + "title": "us_bank_account_networks", + "type": "object", + "x-expandableFields": [] + }, + "usage_record": { + "description": "Usage records allow you to report customer usage and metrics to Stripe for\nmetered billing of subscription prices.\n\nRelated guide: [Metered billing](https://stripe.com/docs/billing/subscriptions/metered-billing)\n\nThis is our legacy usage-based billing API. See the [updated usage-based billing docs](https://docs.stripe.com/billing/subscriptions/usage-based).", + "properties": { + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["usage_record"], + "type": "string" + }, + "quantity": { + "description": "The usage quantity for the specified date.", + "type": "integer" + }, + "subscription_item": { + "description": "The ID of the subscription item this usage record contains data for.", + "maxLength": 5000, + "type": "string" + }, + "timestamp": { + "description": "The timestamp when this usage occurred.", + "format": "unix-time", + "type": "integer" + } + }, + "required": [ + "id", + "livemode", + "object", + "quantity", + "subscription_item", + "timestamp" + ], + "title": "UsageRecord", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "usage_record" + }, + "usage_record_summary": { + "description": "", + "properties": { + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "invoice": { + "description": "The invoice in which this usage period has been billed for.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["usage_record_summary"], + "type": "string" + }, + "period": { + "$ref": "#/components/schemas/period" + }, + "subscription_item": { + "description": "The ID of the subscription item this summary is describing.", + "maxLength": 5000, + "type": "string" + }, + "total_usage": { + "description": "The total usage within this usage period.", + "type": "integer" + } + }, + "required": [ + "id", + "livemode", + "object", + "period", + "subscription_item", + "total_usage" + ], + "title": "UsageRecordSummary", + "type": "object", + "x-expandableFields": ["period"], + "x-resourceId": "usage_record_summary" + }, + "verification_session_redaction": { + "description": "", + "properties": { + "status": { + "description": "Indicates whether this object and its related objects have been redacted or not.", + "enum": ["processing", "redacted"], + "type": "string" + } + }, + "required": ["status"], + "title": "verification_session_redaction", + "type": "object", + "x-expandableFields": [] + }, + "webhook_endpoint": { + "description": "You can configure [webhook endpoints](https://docs.stripe.com/webhooks/) via the API to be\nnotified about events that happen in your Stripe account or connected\naccounts.\n\nMost users configure webhooks from [the dashboard](https://dashboard.stripe.com/webhooks), which provides a user interface for registering and testing your webhook endpoints.\n\nRelated guide: [Setting up webhooks](https://docs.stripe.com/webhooks/configure)", + "properties": { + "api_version": { + "description": "The API version events are rendered as for this webhook endpoint.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "application": { + "description": "The ID of the associated Connect application.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "created": { + "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "description": { + "description": "An optional description of what the webhook is used for.", + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "enabled_events": { + "description": "The list of events to enable for this endpoint. `['*']` indicates that all events are enabled, except those that require explicit selection.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "id": { + "description": "Unique identifier for the object.", + "maxLength": 5000, + "type": "string" + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "metadata": { + "additionalProperties": { + "maxLength": 500, + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["webhook_endpoint"], + "type": "string" + }, + "secret": { + "description": "The endpoint's secret, used to generate [webhook signatures](https://docs.stripe.com/webhooks/signatures). Only returned at creation.", + "maxLength": 5000, + "type": "string" + }, + "status": { + "description": "The status of the webhook. It can be `enabled` or `disabled`.", + "maxLength": 5000, + "type": "string" + }, + "url": { + "description": "The URL of the webhook endpoint.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "created", + "enabled_events", + "id", + "livemode", + "metadata", + "object", + "status", + "url" + ], + "title": "NotificationWebhookEndpoint", + "type": "object", + "x-expandableFields": [], + "x-resourceId": "webhook_endpoint" + } + }, + "securitySchemes": { + "basicAuth": { + "description": "Basic HTTP authentication. Allowed headers-- Authorization: Basic | Authorization: Basic ", + "scheme": "basic", + "type": "http" + }, + "bearerAuth": { + "bearerFormat": "auth-scheme", + "description": "Bearer HTTP authentication. Allowed headers-- Authorization: Bearer ", + "scheme": "bearer", + "type": "http" + } + } + }, + "info": { + "contact": { + "email": "dev-platform@stripe.com", + "name": "Stripe Dev Platform Team", + "url": "https://stripe.com" + }, + "description": "The Stripe REST API. Please see https://stripe.com/docs/api for more details.", + "termsOfService": "https://stripe.com/us/terms/", + "title": "Stripe API", + "version": "2024-06-20", + "x-stripeSpecFilename": "spec3" + }, + "openapi": "3.0.0", + "paths": { + "/v1/account": { + "get": { + "description": "

Retrieves the details of an account.

", + "operationId": "GetAccount", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/account_links": { + "post": { + "description": "

Creates an AccountLink object that includes a single-use Stripe URL that the platform can redirect their user to in order to take them through the Connect Onboarding flow.

", + "operationId": "PostAccountLinks", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "collection_options": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account": { + "description": "The identifier of the account to create an account link for.", + "maxLength": 5000, + "type": "string" + }, + "collect": { + "description": "The collect parameter is deprecated. Use `collection_options` instead.", + "enum": ["currently_due", "eventually_due"], + "type": "string" + }, + "collection_options": { + "description": "Specifies the requirements that Stripe collects from connected accounts in the Connect Onboarding flow.", + "properties": { + "fields": { + "enum": ["currently_due", "eventually_due"], + "type": "string" + }, + "future_requirements": { + "enum": ["include", "omit"], + "type": "string" + } + }, + "title": "collection_options_params", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "refresh_url": { + "description": "The URL the user will be redirected to if the account link is expired, has been previously-visited, or is otherwise invalid. The URL you specify should attempt to generate a new account link with the same parameters used to create the original account link, then redirect the user to the new account link's URL so they can continue with Connect Onboarding. If a new account link cannot be generated or the redirect fails you should display a useful error to the user.", + "type": "string" + }, + "return_url": { + "description": "The URL that the user will be redirected to upon leaving or completing the linked flow.", + "type": "string" + }, + "type": { + "description": "The type of account link the user is requesting. Possible values are `account_onboarding` or `account_update`.", + "enum": ["account_onboarding", "account_update"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["account", "type"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/account_link" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/account_sessions": { + "post": { + "description": "

Creates a AccountSession object that includes a single-use token that the platform can use on their front-end to grant client-side API access.

", + "operationId": "PostAccountSessions", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "components": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account": { + "description": "The identifier of the account to create an Account Session for.", + "type": "string" + }, + "components": { + "description": "Each key of the dictionary represents an embedded component, and each embedded component maps to its configuration (e.g. whether it has been enabled or not).", + "properties": { + "account_management": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": { + "external_account_collection": { + "type": "boolean" + } + }, + "title": "account_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "account_config_param", + "type": "object" + }, + "account_onboarding": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": { + "external_account_collection": { + "type": "boolean" + } + }, + "title": "account_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "account_config_param", + "type": "object" + }, + "balances": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": { + "edit_payout_schedule": { + "type": "boolean" + }, + "external_account_collection": { + "type": "boolean" + }, + "instant_payouts": { + "type": "boolean" + }, + "standard_payouts": { + "type": "boolean" + } + }, + "title": "payouts_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "payouts_config_param", + "type": "object" + }, + "documents": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": {}, + "title": "base_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "base_config_param", + "type": "object" + }, + "notification_banner": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": { + "external_account_collection": { + "type": "boolean" + } + }, + "title": "account_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "account_config_param", + "type": "object" + }, + "payment_details": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": { + "capture_payments": { + "type": "boolean" + }, + "destination_on_behalf_of_charge_management": { + "type": "boolean" + }, + "dispute_management": { + "type": "boolean" + }, + "refund_management": { + "type": "boolean" + } + }, + "title": "payments_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "payments_config_param", + "type": "object" + }, + "payments": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": { + "capture_payments": { + "type": "boolean" + }, + "destination_on_behalf_of_charge_management": { + "type": "boolean" + }, + "dispute_management": { + "type": "boolean" + }, + "refund_management": { + "type": "boolean" + } + }, + "title": "payments_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "payments_config_param", + "type": "object" + }, + "payouts": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": { + "edit_payout_schedule": { + "type": "boolean" + }, + "external_account_collection": { + "type": "boolean" + }, + "instant_payouts": { + "type": "boolean" + }, + "standard_payouts": { + "type": "boolean" + } + }, + "title": "payouts_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "payouts_config_param", + "type": "object" + }, + "payouts_list": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": {}, + "title": "base_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "base_config_param", + "type": "object" + }, + "tax_registrations": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": {}, + "title": "base_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "base_config_param", + "type": "object" + }, + "tax_settings": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": {}, + "title": "base_features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "base_config_param", + "type": "object" + } + }, + "title": "account_session_create_components_param", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "required": ["account", "components"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/account_session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts": { + "get": { + "description": "

Returns a list of accounts connected to your platform via Connect. If you’re not a platform, the list is empty.

", + "operationId": "GetAccounts", + "parameters": [ + { + "description": "Only return connected accounts that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/account" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/accounts", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "AccountList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

With Connect, you can create Stripe accounts for your users.\nTo do this, you’ll first need to register your platform.

\n\n

If you’ve already collected information for your connected accounts, you can prefill that information when\ncreating the account. Connect Onboarding won’t ask for the prefilled information during account onboarding.\nYou can prefill any information on the account.

", + "operationId": "PostAccounts", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "bank_account": { + "explode": true, + "style": "deepObject" + }, + "business_profile": { + "explode": true, + "style": "deepObject" + }, + "capabilities": { + "explode": true, + "style": "deepObject" + }, + "company": { + "explode": true, + "style": "deepObject" + }, + "controller": { + "explode": true, + "style": "deepObject" + }, + "documents": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "individual": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "settings": { + "explode": true, + "style": "deepObject" + }, + "tos_acceptance": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account_token": { + "description": "An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.", + "maxLength": 5000, + "type": "string" + }, + "bank_account": { + "anyOf": [ + { + "properties": { + "account_holder_name": { + "maxLength": 5000, + "type": "string" + }, + "account_holder_type": { + "enum": ["company", "individual"], + "maxLength": 5000, + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "futsu", "savings", "toza"], + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "currency": { + "type": "string" + }, + "documents": { + "properties": { + "bank_account_ownership_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "external_account_documents_param", + "type": "object" + }, + "object": { + "enum": ["bank_account"], + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "country"], + "title": "external_account_payout_bank_account", + "type": "object" + }, + { + "maxLength": 5000, + "type": "string" + } + ], + "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/js), or a dictionary containing a user's bank account details." + }, + "business_profile": { + "description": "Business information about the account.", + "properties": { + "annual_revenue": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + }, + "fiscal_year_end": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["amount", "currency", "fiscal_year_end"], + "title": "annual_revenue_specs", + "type": "object" + }, + "estimated_worker_count": { + "type": "integer" + }, + "mcc": { + "maxLength": 4, + "type": "string" + }, + "monthly_estimated_revenue": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + } + }, + "required": ["amount", "currency"], + "title": "monthly_estimated_revenue_specs", + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "product_description": { + "maxLength": 40000, + "type": "string" + }, + "support_address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "support_email": { + "type": "string" + }, + "support_phone": { + "maxLength": 5000, + "type": "string" + }, + "support_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "url": { + "type": "string" + } + }, + "title": "business_profile_specs", + "type": "object" + }, + "business_type": { + "description": "The business type. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "enum": [ + "company", + "government_entity", + "individual", + "non_profit" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "capabilities": { + "description": "Each key of the dictionary represents a capability, and each capability\nmaps to its settings (for example, whether it has been requested or not). Each\ncapability is inactive until you have provided its specific\nrequirements and Stripe has verified them. An account might have some\nof its requested capabilities be active and some be inactive.\n\nRequired when [account.controller.stripe_dashboard.type](/api/accounts/create#create_account-controller-dashboard-type)\nis `none`, which includes Custom accounts.", + "properties": { + "acss_debit_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "affirm_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "afterpay_clearpay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "amazon_pay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "au_becs_debit_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "bacs_debit_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "bancontact_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "blik_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "boleto_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "card_issuing": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "card_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "cartes_bancaires_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "cashapp_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "eps_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "fpx_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "gb_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "giropay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "grabpay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "ideal_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "india_international_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "jcb_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "jp_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "klarna_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "konbini_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "legacy_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "link_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "mobilepay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "multibanco_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "mx_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "oxxo_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "p24_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "paynow_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "promptpay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "revolut_pay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "sepa_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "sepa_debit_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "sofort_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "swish_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "tax_reporting_us_1099_k": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "tax_reporting_us_1099_misc": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "transfers": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "treasury": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "twint_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "us_bank_account_ach_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "us_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "zip_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + } + }, + "title": "capabilities_param", + "type": "object" + }, + "company": { + "description": "Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "legal_entity_and_kyc_address_specs", + "type": "object" + }, + "address_kana": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "directors_provided": { + "type": "boolean" + }, + "executives_provided": { + "type": "boolean" + }, + "export_license_id": { + "maxLength": 5000, + "type": "string" + }, + "export_purpose_code": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 100, + "type": "string" + }, + "name_kana": { + "maxLength": 100, + "type": "string" + }, + "name_kanji": { + "maxLength": 100, + "type": "string" + }, + "owners_provided": { + "type": "boolean" + }, + "ownership_declaration": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "company_ownership_declaration", + "type": "object" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "registration_number": { + "maxLength": 5000, + "type": "string" + }, + "structure": { + "enum": [ + "", + "free_zone_establishment", + "free_zone_llc", + "government_instrumentality", + "governmental_unit", + "incorporated_non_profit", + "incorporated_partnership", + "limited_liability_partnership", + "llc", + "multi_member_llc", + "private_company", + "private_corporation", + "private_partnership", + "public_company", + "public_corporation", + "public_partnership", + "registered_charity", + "single_member_llc", + "sole_establishment", + "sole_proprietorship", + "tax_exempt_government_instrumentality", + "unincorporated_association", + "unincorporated_non_profit", + "unincorporated_partnership" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "tax_id": { + "maxLength": 5000, + "type": "string" + }, + "tax_id_registrar": { + "maxLength": 5000, + "type": "string" + }, + "vat_id": { + "maxLength": 5000, + "type": "string" + }, + "verification": { + "properties": { + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "verification_document_specs", + "type": "object" + } + }, + "title": "verification_specs", + "type": "object" + } + }, + "title": "company_specs", + "type": "object" + }, + "controller": { + "description": "A hash of configuration describing the account controller's attributes.", + "properties": { + "fees": { + "properties": { + "payer": { + "enum": ["account", "application"], + "type": "string" + } + }, + "title": "controller_fees_specs", + "type": "object" + }, + "losses": { + "properties": { + "payments": { + "enum": ["application", "stripe"], + "type": "string" + } + }, + "title": "controller_losses_specs", + "type": "object" + }, + "requirement_collection": { + "enum": ["application", "stripe"], + "type": "string" + }, + "stripe_dashboard": { + "properties": { + "type": { + "enum": ["express", "full", "none"], + "type": "string" + } + }, + "title": "controller_dashboard_specs", + "type": "object" + } + }, + "title": "controller_specs", + "type": "object" + }, + "country": { + "description": "The country in which the account holder resides, or in which the business is legally established. This should be an ISO 3166-1 alpha-2 country code. For example, if you are in the United States and the business for which you're creating an account is legally represented in Canada, you would use `CA` as the country for the account being created. Available countries include [Stripe's global markets](https://stripe.com/global) as well as countries where [cross-border payouts](https://stripe.com/docs/connect/cross-border-payouts) are supported.", + "maxLength": 5000, + "type": "string" + }, + "default_currency": { + "description": "Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).", + "type": "string" + }, + "documents": { + "description": "Documents that may be submitted to satisfy various informational requests.", + "properties": { + "bank_account_ownership_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_license": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_memorandum_of_association": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_ministerial_decree": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_registration_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_tax_id_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "proof_of_registration": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "documents_specs", + "type": "object" + }, + "email": { + "description": "The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "external_account": { + "description": "A card or bank account to attach to the account for receiving [payouts](/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](/js), or a dictionary, as documented in the `external_account` parameter for [bank account](/api#account_create_bank_account) creation.

By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](/api#account_create_bank_account) or [card creation](/api#account_create_card) APIs. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "individual": { + "description": "Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "address_kana": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "dob": { + "anyOf": [ + { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "type": "string" + }, + "first_name": { + "maxLength": 100, + "type": "string" + }, + "first_name_kana": { + "maxLength": 5000, + "type": "string" + }, + "first_name_kanji": { + "maxLength": 5000, + "type": "string" + }, + "full_name_aliases": { + "anyOf": [ + { + "items": { + "maxLength": 300, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "gender": { + "type": "string" + }, + "id_number": { + "maxLength": 5000, + "type": "string" + }, + "id_number_secondary": { + "maxLength": 5000, + "type": "string" + }, + "last_name": { + "maxLength": 100, + "type": "string" + }, + "last_name_kana": { + "maxLength": 5000, + "type": "string" + }, + "last_name_kanji": { + "maxLength": 5000, + "type": "string" + }, + "maiden_name": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "type": "string" + }, + "political_exposure": { + "enum": ["existing", "none"], + "type": "string" + }, + "registered_address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "relationship": { + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "percent_ownership": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "title": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "individual_relationship_specs", + "type": "object" + }, + "ssn_last_4": { + "maxLength": 5000, + "type": "string" + }, + "verification": { + "properties": { + "additional_document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + }, + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + } + }, + "title": "person_verification_specs", + "type": "object" + } + }, + "title": "individual_specs", + "type": "object" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "settings": { + "description": "Options for customizing how the account functions within Stripe.", + "properties": { + "bacs_debit_payments": { + "properties": { + "display_name": { + "type": "string" + } + }, + "title": "bacs_debit_payments_specs", + "type": "object" + }, + "branding": { + "properties": { + "icon": { + "maxLength": 5000, + "type": "string" + }, + "logo": { + "maxLength": 5000, + "type": "string" + }, + "primary_color": { + "maxLength": 5000, + "type": "string" + }, + "secondary_color": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "branding_settings_specs", + "type": "object" + }, + "card_issuing": { + "properties": { + "tos_acceptance": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "settings_terms_of_service_specs", + "type": "object" + } + }, + "title": "card_issuing_settings_specs", + "type": "object" + }, + "card_payments": { + "properties": { + "decline_on": { + "properties": { + "avs_failure": { + "type": "boolean" + }, + "cvc_failure": { + "type": "boolean" + } + }, + "title": "decline_charge_on_specs", + "type": "object" + }, + "statement_descriptor_prefix": { + "maxLength": 10, + "type": "string" + }, + "statement_descriptor_prefix_kana": { + "anyOf": [ + { + "maxLength": 10, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "statement_descriptor_prefix_kanji": { + "anyOf": [ + { + "maxLength": 10, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "card_payments_settings_specs", + "type": "object" + }, + "payments": { + "properties": { + "statement_descriptor": { + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_kana": { + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_kanji": { + "maxLength": 22, + "type": "string" + } + }, + "title": "payments_settings_specs", + "type": "object" + }, + "payouts": { + "properties": { + "debit_negative_balances": { + "type": "boolean" + }, + "schedule": { + "properties": { + "delay_days": { + "anyOf": [ + { + "enum": ["minimum"], + "maxLength": 5000, + "type": "string" + }, + { + "type": "integer" + } + ] + }, + "interval": { + "enum": [ + "daily", + "manual", + "monthly", + "weekly" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "monthly_anchor": { + "type": "integer" + }, + "weekly_anchor": { + "enum": [ + "friday", + "monday", + "saturday", + "sunday", + "thursday", + "tuesday", + "wednesday" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "transfer_schedule_specs", + "type": "object" + }, + "statement_descriptor": { + "maxLength": 22, + "type": "string" + } + }, + "title": "payout_settings_specs", + "type": "object" + }, + "treasury": { + "properties": { + "tos_acceptance": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "settings_terms_of_service_specs", + "type": "object" + } + }, + "title": "treasury_settings_specs", + "type": "object" + } + }, + "title": "settings_specs", + "type": "object" + }, + "tos_acceptance": { + "description": "Details on the account's acceptance of the [Stripe Services Agreement](/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.", + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "service_agreement": { + "maxLength": 5000, + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "tos_acceptance_specs", + "type": "object" + }, + "type": { + "description": "The type of Stripe account to create. May be one of `custom`, `express` or `standard`.", + "enum": ["custom", "express", "standard"], + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}": { + "delete": { + "description": "

With Connect, you can delete accounts you manage.

\n\n

Test-mode accounts can be deleted at any time.

\n\n

Live-mode accounts where Stripe is responsible for negative account balances cannot be deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be deleted when all balances are zero.

\n\n

If you want to delete your own account, use the account information tab in your account settings instead.

", + "operationId": "DeleteAccountsAccount", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves the details of an account.

", + "operationId": "GetAccountsAccount", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates a connected account by setting the values of the parameters passed. Any parameters not provided are\nleft unchanged.

\n\n

For accounts where controller.requirement_collection\nis application, which includes Custom accounts, you can update any information on the account.

\n\n

For accounts where controller.requirement_collection\nis stripe, which includes Standard and Express accounts, you can update all information until you create\nan Account Link or Account Session to start Connect onboarding,\nafter which some properties can no longer be updated.

\n\n

To update your own account, use the Dashboard. Refer to our\nConnect documentation to learn more about updating accounts.

", + "operationId": "PostAccountsAccount", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "business_profile": { + "explode": true, + "style": "deepObject" + }, + "capabilities": { + "explode": true, + "style": "deepObject" + }, + "company": { + "explode": true, + "style": "deepObject" + }, + "documents": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "individual": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "settings": { + "explode": true, + "style": "deepObject" + }, + "tos_acceptance": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account_token": { + "description": "An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.", + "maxLength": 5000, + "type": "string" + }, + "business_profile": { + "description": "Business information about the account.", + "properties": { + "annual_revenue": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + }, + "fiscal_year_end": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["amount", "currency", "fiscal_year_end"], + "title": "annual_revenue_specs", + "type": "object" + }, + "estimated_worker_count": { + "type": "integer" + }, + "mcc": { + "maxLength": 4, + "type": "string" + }, + "monthly_estimated_revenue": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + } + }, + "required": ["amount", "currency"], + "title": "monthly_estimated_revenue_specs", + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "product_description": { + "maxLength": 40000, + "type": "string" + }, + "support_address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "support_email": { + "type": "string" + }, + "support_phone": { + "maxLength": 5000, + "type": "string" + }, + "support_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "url": { + "type": "string" + } + }, + "title": "business_profile_specs", + "type": "object" + }, + "business_type": { + "description": "The business type. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "enum": [ + "company", + "government_entity", + "individual", + "non_profit" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "capabilities": { + "description": "Each key of the dictionary represents a capability, and each capability\nmaps to its settings (for example, whether it has been requested or not). Each\ncapability is inactive until you have provided its specific\nrequirements and Stripe has verified them. An account might have some\nof its requested capabilities be active and some be inactive.\n\nRequired when [account.controller.stripe_dashboard.type](/api/accounts/create#create_account-controller-dashboard-type)\nis `none`, which includes Custom accounts.", + "properties": { + "acss_debit_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "affirm_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "afterpay_clearpay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "amazon_pay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "au_becs_debit_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "bacs_debit_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "bancontact_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "blik_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "boleto_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "card_issuing": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "card_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "cartes_bancaires_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "cashapp_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "eps_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "fpx_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "gb_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "giropay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "grabpay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "ideal_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "india_international_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "jcb_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "jp_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "klarna_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "konbini_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "legacy_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "link_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "mobilepay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "multibanco_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "mx_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "oxxo_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "p24_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "paynow_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "promptpay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "revolut_pay_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "sepa_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "sepa_debit_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "sofort_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "swish_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "tax_reporting_us_1099_k": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "tax_reporting_us_1099_misc": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "transfers": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "treasury": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "twint_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "us_bank_account_ach_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "us_bank_transfer_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + }, + "zip_payments": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "title": "capability_param", + "type": "object" + } + }, + "title": "capabilities_param", + "type": "object" + }, + "company": { + "description": "Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "legal_entity_and_kyc_address_specs", + "type": "object" + }, + "address_kana": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "directors_provided": { + "type": "boolean" + }, + "executives_provided": { + "type": "boolean" + }, + "export_license_id": { + "maxLength": 5000, + "type": "string" + }, + "export_purpose_code": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 100, + "type": "string" + }, + "name_kana": { + "maxLength": 100, + "type": "string" + }, + "name_kanji": { + "maxLength": 100, + "type": "string" + }, + "owners_provided": { + "type": "boolean" + }, + "ownership_declaration": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "company_ownership_declaration", + "type": "object" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "registration_number": { + "maxLength": 5000, + "type": "string" + }, + "structure": { + "enum": [ + "", + "free_zone_establishment", + "free_zone_llc", + "government_instrumentality", + "governmental_unit", + "incorporated_non_profit", + "incorporated_partnership", + "limited_liability_partnership", + "llc", + "multi_member_llc", + "private_company", + "private_corporation", + "private_partnership", + "public_company", + "public_corporation", + "public_partnership", + "registered_charity", + "single_member_llc", + "sole_establishment", + "sole_proprietorship", + "tax_exempt_government_instrumentality", + "unincorporated_association", + "unincorporated_non_profit", + "unincorporated_partnership" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "tax_id": { + "maxLength": 5000, + "type": "string" + }, + "tax_id_registrar": { + "maxLength": 5000, + "type": "string" + }, + "vat_id": { + "maxLength": 5000, + "type": "string" + }, + "verification": { + "properties": { + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "verification_document_specs", + "type": "object" + } + }, + "title": "verification_specs", + "type": "object" + } + }, + "title": "company_specs", + "type": "object" + }, + "default_currency": { + "description": "Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).", + "type": "string" + }, + "documents": { + "description": "Documents that may be submitted to satisfy various informational requests.", + "properties": { + "bank_account_ownership_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_license": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_memorandum_of_association": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_ministerial_decree": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_registration_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "company_tax_id_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "proof_of_registration": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "documents_specs", + "type": "object" + }, + "email": { + "description": "The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "external_account": { + "description": "A card or bank account to attach to the account for receiving [payouts](/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](/js), or a dictionary, as documented in the `external_account` parameter for [bank account](/api#account_create_bank_account) creation.

By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](/api#account_create_bank_account) or [card creation](/api#account_create_card) APIs. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "individual": { + "description": "Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "address_kana": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "dob": { + "anyOf": [ + { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "type": "string" + }, + "first_name": { + "maxLength": 100, + "type": "string" + }, + "first_name_kana": { + "maxLength": 5000, + "type": "string" + }, + "first_name_kanji": { + "maxLength": 5000, + "type": "string" + }, + "full_name_aliases": { + "anyOf": [ + { + "items": { + "maxLength": 300, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "gender": { + "type": "string" + }, + "id_number": { + "maxLength": 5000, + "type": "string" + }, + "id_number_secondary": { + "maxLength": 5000, + "type": "string" + }, + "last_name": { + "maxLength": 100, + "type": "string" + }, + "last_name_kana": { + "maxLength": 5000, + "type": "string" + }, + "last_name_kanji": { + "maxLength": 5000, + "type": "string" + }, + "maiden_name": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "type": "string" + }, + "political_exposure": { + "enum": ["existing", "none"], + "type": "string" + }, + "registered_address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "relationship": { + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "percent_ownership": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "title": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "individual_relationship_specs", + "type": "object" + }, + "ssn_last_4": { + "maxLength": 5000, + "type": "string" + }, + "verification": { + "properties": { + "additional_document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + }, + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + } + }, + "title": "person_verification_specs", + "type": "object" + } + }, + "title": "individual_specs", + "type": "object" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "settings": { + "description": "Options for customizing how the account functions within Stripe.", + "properties": { + "bacs_debit_payments": { + "properties": { + "display_name": { + "type": "string" + } + }, + "title": "bacs_debit_payments_specs", + "type": "object" + }, + "branding": { + "properties": { + "icon": { + "maxLength": 5000, + "type": "string" + }, + "logo": { + "maxLength": 5000, + "type": "string" + }, + "primary_color": { + "maxLength": 5000, + "type": "string" + }, + "secondary_color": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "branding_settings_specs", + "type": "object" + }, + "card_issuing": { + "properties": { + "tos_acceptance": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "settings_terms_of_service_specs", + "type": "object" + } + }, + "title": "card_issuing_settings_specs", + "type": "object" + }, + "card_payments": { + "properties": { + "decline_on": { + "properties": { + "avs_failure": { + "type": "boolean" + }, + "cvc_failure": { + "type": "boolean" + } + }, + "title": "decline_charge_on_specs", + "type": "object" + }, + "statement_descriptor_prefix": { + "maxLength": 10, + "type": "string" + }, + "statement_descriptor_prefix_kana": { + "anyOf": [ + { + "maxLength": 10, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "statement_descriptor_prefix_kanji": { + "anyOf": [ + { + "maxLength": 10, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "card_payments_settings_specs", + "type": "object" + }, + "invoices": { + "properties": { + "default_account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "invoices_settings_specs", + "type": "object" + }, + "payments": { + "properties": { + "statement_descriptor": { + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_kana": { + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_kanji": { + "maxLength": 22, + "type": "string" + } + }, + "title": "payments_settings_specs", + "type": "object" + }, + "payouts": { + "properties": { + "debit_negative_balances": { + "type": "boolean" + }, + "schedule": { + "properties": { + "delay_days": { + "anyOf": [ + { + "enum": ["minimum"], + "maxLength": 5000, + "type": "string" + }, + { + "type": "integer" + } + ] + }, + "interval": { + "enum": [ + "daily", + "manual", + "monthly", + "weekly" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "monthly_anchor": { + "type": "integer" + }, + "weekly_anchor": { + "enum": [ + "friday", + "monday", + "saturday", + "sunday", + "thursday", + "tuesday", + "wednesday" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "transfer_schedule_specs", + "type": "object" + }, + "statement_descriptor": { + "maxLength": 22, + "type": "string" + } + }, + "title": "payout_settings_specs", + "type": "object" + }, + "treasury": { + "properties": { + "tos_acceptance": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "settings_terms_of_service_specs", + "type": "object" + } + }, + "title": "treasury_settings_specs", + "type": "object" + } + }, + "title": "settings_specs_update", + "type": "object" + }, + "tos_acceptance": { + "description": "Details on the account's acceptance of the [Stripe Services Agreement](/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.", + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "service_agreement": { + "maxLength": 5000, + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "tos_acceptance_specs", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/bank_accounts": { + "post": { + "description": "

Create an external account for a given account.

", + "operationId": "PostAccountsAccountBankAccounts", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "bank_account": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "bank_account": { + "anyOf": [ + { + "properties": { + "account_holder_name": { + "maxLength": 5000, + "type": "string" + }, + "account_holder_type": { + "enum": ["company", "individual"], + "maxLength": 5000, + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "futsu", "savings", "toza"], + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "currency": { + "type": "string" + }, + "documents": { + "properties": { + "bank_account_ownership_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "external_account_documents_param", + "type": "object" + }, + "object": { + "enum": ["bank_account"], + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "country"], + "title": "external_account_payout_bank_account", + "type": "object" + }, + { + "maxLength": 5000, + "type": "string" + } + ], + "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/js), or a dictionary containing a user's bank account details." + }, + "default_for_currency": { + "description": "When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.", + "type": "boolean" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "external_account": { + "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/external_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/bank_accounts/{id}": { + "delete": { + "description": "

Delete a specified external account for a given account.

", + "operationId": "DeleteAccountsAccountBankAccountsId", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_external_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieve a specified external account for a given account.

", + "operationId": "GetAccountsAccountBankAccountsId", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/external_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the metadata, account holder name, account holder type of a bank account belonging to\na connected account and optionally sets it as the default for its currency. Other bank account\ndetails are not editable by design.

\n\n

You can only update bank accounts when account.controller.requirement_collection is application, which includes Custom accounts.

\n\n

You can re-enable a disabled bank account by performing an update call without providing any\narguments or changes.

", + "operationId": "PostAccountsAccountBankAccountsId", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "documents": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account_holder_name": { + "description": "The name of the person or business that owns the bank account.", + "maxLength": 5000, + "type": "string" + }, + "account_holder_type": { + "description": "The type of entity that holds the account. This can be either `individual` or `company`.", + "enum": ["", "company", "individual"], + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "description": "The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.", + "enum": ["checking", "futsu", "savings", "toza"], + "maxLength": 5000, + "type": "string" + }, + "address_city": { + "description": "City/District/Suburb/Town/Village.", + "maxLength": 5000, + "type": "string" + }, + "address_country": { + "description": "Billing address country, if provided when creating card.", + "maxLength": 5000, + "type": "string" + }, + "address_line1": { + "description": "Address line 1 (Street address/PO Box/Company name).", + "maxLength": 5000, + "type": "string" + }, + "address_line2": { + "description": "Address line 2 (Apartment/Suite/Unit/Building).", + "maxLength": 5000, + "type": "string" + }, + "address_state": { + "description": "State/County/Province/Region.", + "maxLength": 5000, + "type": "string" + }, + "address_zip": { + "description": "ZIP or postal code.", + "maxLength": 5000, + "type": "string" + }, + "default_for_currency": { + "description": "When set to true, this becomes the default external account for its currency.", + "type": "boolean" + }, + "documents": { + "description": "Documents that may be submitted to satisfy various informational requests.", + "properties": { + "bank_account_ownership_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "external_account_documents_param", + "type": "object" + }, + "exp_month": { + "description": "Two digit number representing the card’s expiration month.", + "maxLength": 5000, + "type": "string" + }, + "exp_year": { + "description": "Four digit number representing the card’s expiration year.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "name": { + "description": "Cardholder name.", + "maxLength": 5000, + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/external_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/capabilities": { + "get": { + "description": "

Returns a list of capabilities associated with the account. The capabilities are returned sorted by creation date, with the most recent capability appearing first.

", + "operationId": "GetAccountsAccountCapabilities", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/capability" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ListAccountCapability", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/capabilities/{capability}": { + "get": { + "description": "

Retrieves information about the specified Account Capability.

", + "operationId": "GetAccountsAccountCapabilitiesCapability", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "capability", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/capability" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates an existing Account Capability. Request or remove a capability by updating its requested parameter.

", + "operationId": "PostAccountsAccountCapabilitiesCapability", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "capability", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "requested": { + "description": "To request a new capability for an account, pass true. There can be a delay before the requested capability becomes active. If the capability has any activation requirements, the response includes them in the `requirements` arrays.\n\nIf a capability isn't permanent, you can remove it from the account by passing false. Some capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/capability" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/external_accounts": { + "get": { + "description": "

List external accounts for an account.

", + "operationId": "GetAccountsAccountExternalAccounts", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Filter external accounts according to a particular object type.", + "in": "query", + "name": "object", + "required": false, + "schema": { + "enum": ["bank_account", "card"], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "The list contains all external accounts that have been attached to the Stripe account. These may be bank accounts or cards.", + "items": { + "anyOf": [ + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/card" + } + ], + "title": "Polymorphic", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ExternalAccountList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Create an external account for a given account.

", + "operationId": "PostAccountsAccountExternalAccounts", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "bank_account": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "bank_account": { + "anyOf": [ + { + "properties": { + "account_holder_name": { + "maxLength": 5000, + "type": "string" + }, + "account_holder_type": { + "enum": ["company", "individual"], + "maxLength": 5000, + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "futsu", "savings", "toza"], + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "currency": { + "type": "string" + }, + "documents": { + "properties": { + "bank_account_ownership_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "external_account_documents_param", + "type": "object" + }, + "object": { + "enum": ["bank_account"], + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "country"], + "title": "external_account_payout_bank_account", + "type": "object" + }, + { + "maxLength": 5000, + "type": "string" + } + ], + "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/js), or a dictionary containing a user's bank account details." + }, + "default_for_currency": { + "description": "When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.", + "type": "boolean" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "external_account": { + "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/external_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/external_accounts/{id}": { + "delete": { + "description": "

Delete a specified external account for a given account.

", + "operationId": "DeleteAccountsAccountExternalAccountsId", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_external_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieve a specified external account for a given account.

", + "operationId": "GetAccountsAccountExternalAccountsId", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/external_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the metadata, account holder name, account holder type of a bank account belonging to\na connected account and optionally sets it as the default for its currency. Other bank account\ndetails are not editable by design.

\n\n

You can only update bank accounts when account.controller.requirement_collection is application, which includes Custom accounts.

\n\n

You can re-enable a disabled bank account by performing an update call without providing any\narguments or changes.

", + "operationId": "PostAccountsAccountExternalAccountsId", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "documents": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account_holder_name": { + "description": "The name of the person or business that owns the bank account.", + "maxLength": 5000, + "type": "string" + }, + "account_holder_type": { + "description": "The type of entity that holds the account. This can be either `individual` or `company`.", + "enum": ["", "company", "individual"], + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "description": "The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.", + "enum": ["checking", "futsu", "savings", "toza"], + "maxLength": 5000, + "type": "string" + }, + "address_city": { + "description": "City/District/Suburb/Town/Village.", + "maxLength": 5000, + "type": "string" + }, + "address_country": { + "description": "Billing address country, if provided when creating card.", + "maxLength": 5000, + "type": "string" + }, + "address_line1": { + "description": "Address line 1 (Street address/PO Box/Company name).", + "maxLength": 5000, + "type": "string" + }, + "address_line2": { + "description": "Address line 2 (Apartment/Suite/Unit/Building).", + "maxLength": 5000, + "type": "string" + }, + "address_state": { + "description": "State/County/Province/Region.", + "maxLength": 5000, + "type": "string" + }, + "address_zip": { + "description": "ZIP or postal code.", + "maxLength": 5000, + "type": "string" + }, + "default_for_currency": { + "description": "When set to true, this becomes the default external account for its currency.", + "type": "boolean" + }, + "documents": { + "description": "Documents that may be submitted to satisfy various informational requests.", + "properties": { + "bank_account_ownership_verification": { + "properties": { + "files": { + "items": { + "maxLength": 500, + "type": "string" + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "external_account_documents_param", + "type": "object" + }, + "exp_month": { + "description": "Two digit number representing the card’s expiration month.", + "maxLength": 5000, + "type": "string" + }, + "exp_year": { + "description": "Four digit number representing the card’s expiration year.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "name": { + "description": "Cardholder name.", + "maxLength": 5000, + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/external_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/login_links": { + "post": { + "description": "

Creates a single-use login link for a connected account to access the Express Dashboard.

\n\n

You can only create login links for accounts that use the Express Dashboard and are connected to your platform.

", + "operationId": "PostAccountsAccountLoginLinks", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/login_link" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/people": { + "get": { + "description": "

Returns a list of people associated with the account’s legal entity. The people are returned sorted by creation date, with the most recent people appearing first.

", + "operationId": "GetAccountsAccountPeople", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Filters on the list of people returned based on the person's relationship to the account's company.", + "explode": true, + "in": "query", + "name": "relationship", + "required": false, + "schema": { + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "legal_guardian": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "representative": { + "type": "boolean" + } + }, + "title": "all_people_relationship_specs", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/person" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PersonList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new person.

", + "operationId": "PostAccountsAccountPeople", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "additional_tos_acceptances": { + "explode": true, + "style": "deepObject" + }, + "address": { + "explode": true, + "style": "deepObject" + }, + "address_kana": { + "explode": true, + "style": "deepObject" + }, + "address_kanji": { + "explode": true, + "style": "deepObject" + }, + "dob": { + "explode": true, + "style": "deepObject" + }, + "documents": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "full_name_aliases": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "registered_address": { + "explode": true, + "style": "deepObject" + }, + "relationship": { + "explode": true, + "style": "deepObject" + }, + "verification": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "additional_tos_acceptances": { + "description": "Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.", + "properties": { + "account": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "settings_terms_of_service_specs", + "type": "object" + } + }, + "title": "person_additional_tos_acceptances_specs", + "type": "object" + }, + "address": { + "description": "The person's address.", + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "legal_entity_and_kyc_address_specs", + "type": "object" + }, + "address_kana": { + "description": "The Kana variation of the person's address (Japan only).", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "description": "The Kanji variation of the person's address (Japan only).", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "dob": { + "anyOf": [ + { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The person's date of birth." + }, + "documents": { + "description": "Documents that may be submitted to satisfy various informational requests.", + "properties": { + "company_authorization": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "passport": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "visa": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "person_documents_specs", + "type": "object" + }, + "email": { + "description": "The person's email address.", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "first_name": { + "description": "The person's first name.", + "maxLength": 5000, + "type": "string" + }, + "first_name_kana": { + "description": "The Kana variation of the person's first name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "first_name_kanji": { + "description": "The Kanji variation of the person's first name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "full_name_aliases": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A list of alternate names or aliases that the person is known by." + }, + "gender": { + "description": "The person's gender (International regulations require either \"male\" or \"female\").", + "type": "string" + }, + "id_number": { + "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).", + "maxLength": 5000, + "type": "string" + }, + "id_number_secondary": { + "description": "The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).", + "maxLength": 5000, + "type": "string" + }, + "last_name": { + "description": "The person's last name.", + "maxLength": 5000, + "type": "string" + }, + "last_name_kana": { + "description": "The Kana variation of the person's last name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "last_name_kanji": { + "description": "The Kanji variation of the person's last name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "maiden_name": { + "description": "The person's maiden name.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "nationality": { + "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", + "maxLength": 5000, + "type": "string" + }, + "person_token": { + "description": "A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.", + "maxLength": 5000, + "type": "string" + }, + "phone": { + "description": "The person's phone number.", + "type": "string" + }, + "political_exposure": { + "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", + "maxLength": 5000, + "type": "string" + }, + "registered_address": { + "description": "The person's registered address.", + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "relationship": { + "description": "The relationship that this person has with the account's legal entity.", + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "legal_guardian": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "percent_ownership": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "representative": { + "type": "boolean" + }, + "title": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "relationship_specs", + "type": "object" + }, + "ssn_last_4": { + "description": "The last four digits of the person's Social Security number (U.S. only).", + "type": "string" + }, + "verification": { + "description": "The person's verification status.", + "properties": { + "additional_document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + }, + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + } + }, + "title": "person_verification_specs", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/person" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/people/{person}": { + "delete": { + "description": "

Deletes an existing person’s relationship to the account’s legal entity. Any person with a relationship for an account can be deleted through the API, except if the person is the account_opener. If your integration is using the executive parameter, you cannot delete the only verified executive on file.

", + "operationId": "DeleteAccountsAccountPeoplePerson", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "person", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_person" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves an existing person.

", + "operationId": "GetAccountsAccountPeoplePerson", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "person", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/person" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates an existing person.

", + "operationId": "PostAccountsAccountPeoplePerson", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "person", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "additional_tos_acceptances": { + "explode": true, + "style": "deepObject" + }, + "address": { + "explode": true, + "style": "deepObject" + }, + "address_kana": { + "explode": true, + "style": "deepObject" + }, + "address_kanji": { + "explode": true, + "style": "deepObject" + }, + "dob": { + "explode": true, + "style": "deepObject" + }, + "documents": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "full_name_aliases": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "registered_address": { + "explode": true, + "style": "deepObject" + }, + "relationship": { + "explode": true, + "style": "deepObject" + }, + "verification": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "additional_tos_acceptances": { + "description": "Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.", + "properties": { + "account": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "settings_terms_of_service_specs", + "type": "object" + } + }, + "title": "person_additional_tos_acceptances_specs", + "type": "object" + }, + "address": { + "description": "The person's address.", + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "legal_entity_and_kyc_address_specs", + "type": "object" + }, + "address_kana": { + "description": "The Kana variation of the person's address (Japan only).", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "description": "The Kanji variation of the person's address (Japan only).", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "dob": { + "anyOf": [ + { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The person's date of birth." + }, + "documents": { + "description": "Documents that may be submitted to satisfy various informational requests.", + "properties": { + "company_authorization": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "passport": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "visa": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "person_documents_specs", + "type": "object" + }, + "email": { + "description": "The person's email address.", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "first_name": { + "description": "The person's first name.", + "maxLength": 5000, + "type": "string" + }, + "first_name_kana": { + "description": "The Kana variation of the person's first name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "first_name_kanji": { + "description": "The Kanji variation of the person's first name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "full_name_aliases": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A list of alternate names or aliases that the person is known by." + }, + "gender": { + "description": "The person's gender (International regulations require either \"male\" or \"female\").", + "type": "string" + }, + "id_number": { + "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).", + "maxLength": 5000, + "type": "string" + }, + "id_number_secondary": { + "description": "The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).", + "maxLength": 5000, + "type": "string" + }, + "last_name": { + "description": "The person's last name.", + "maxLength": 5000, + "type": "string" + }, + "last_name_kana": { + "description": "The Kana variation of the person's last name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "last_name_kanji": { + "description": "The Kanji variation of the person's last name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "maiden_name": { + "description": "The person's maiden name.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "nationality": { + "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", + "maxLength": 5000, + "type": "string" + }, + "person_token": { + "description": "A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.", + "maxLength": 5000, + "type": "string" + }, + "phone": { + "description": "The person's phone number.", + "type": "string" + }, + "political_exposure": { + "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", + "maxLength": 5000, + "type": "string" + }, + "registered_address": { + "description": "The person's registered address.", + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "relationship": { + "description": "The relationship that this person has with the account's legal entity.", + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "legal_guardian": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "percent_ownership": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "representative": { + "type": "boolean" + }, + "title": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "relationship_specs", + "type": "object" + }, + "ssn_last_4": { + "description": "The last four digits of the person's Social Security number (U.S. only).", + "type": "string" + }, + "verification": { + "description": "The person's verification status.", + "properties": { + "additional_document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + }, + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + } + }, + "title": "person_verification_specs", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/person" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/persons": { + "get": { + "description": "

Returns a list of people associated with the account’s legal entity. The people are returned sorted by creation date, with the most recent people appearing first.

", + "operationId": "GetAccountsAccountPersons", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Filters on the list of people returned based on the person's relationship to the account's company.", + "explode": true, + "in": "query", + "name": "relationship", + "required": false, + "schema": { + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "legal_guardian": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "representative": { + "type": "boolean" + } + }, + "title": "all_people_relationship_specs", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/person" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PersonList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new person.

", + "operationId": "PostAccountsAccountPersons", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "additional_tos_acceptances": { + "explode": true, + "style": "deepObject" + }, + "address": { + "explode": true, + "style": "deepObject" + }, + "address_kana": { + "explode": true, + "style": "deepObject" + }, + "address_kanji": { + "explode": true, + "style": "deepObject" + }, + "dob": { + "explode": true, + "style": "deepObject" + }, + "documents": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "full_name_aliases": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "registered_address": { + "explode": true, + "style": "deepObject" + }, + "relationship": { + "explode": true, + "style": "deepObject" + }, + "verification": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "additional_tos_acceptances": { + "description": "Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.", + "properties": { + "account": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "settings_terms_of_service_specs", + "type": "object" + } + }, + "title": "person_additional_tos_acceptances_specs", + "type": "object" + }, + "address": { + "description": "The person's address.", + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "legal_entity_and_kyc_address_specs", + "type": "object" + }, + "address_kana": { + "description": "The Kana variation of the person's address (Japan only).", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "description": "The Kanji variation of the person's address (Japan only).", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "dob": { + "anyOf": [ + { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The person's date of birth." + }, + "documents": { + "description": "Documents that may be submitted to satisfy various informational requests.", + "properties": { + "company_authorization": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "passport": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "visa": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "person_documents_specs", + "type": "object" + }, + "email": { + "description": "The person's email address.", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "first_name": { + "description": "The person's first name.", + "maxLength": 5000, + "type": "string" + }, + "first_name_kana": { + "description": "The Kana variation of the person's first name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "first_name_kanji": { + "description": "The Kanji variation of the person's first name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "full_name_aliases": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A list of alternate names or aliases that the person is known by." + }, + "gender": { + "description": "The person's gender (International regulations require either \"male\" or \"female\").", + "type": "string" + }, + "id_number": { + "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).", + "maxLength": 5000, + "type": "string" + }, + "id_number_secondary": { + "description": "The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).", + "maxLength": 5000, + "type": "string" + }, + "last_name": { + "description": "The person's last name.", + "maxLength": 5000, + "type": "string" + }, + "last_name_kana": { + "description": "The Kana variation of the person's last name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "last_name_kanji": { + "description": "The Kanji variation of the person's last name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "maiden_name": { + "description": "The person's maiden name.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "nationality": { + "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", + "maxLength": 5000, + "type": "string" + }, + "person_token": { + "description": "A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.", + "maxLength": 5000, + "type": "string" + }, + "phone": { + "description": "The person's phone number.", + "type": "string" + }, + "political_exposure": { + "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", + "maxLength": 5000, + "type": "string" + }, + "registered_address": { + "description": "The person's registered address.", + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "relationship": { + "description": "The relationship that this person has with the account's legal entity.", + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "legal_guardian": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "percent_ownership": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "representative": { + "type": "boolean" + }, + "title": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "relationship_specs", + "type": "object" + }, + "ssn_last_4": { + "description": "The last four digits of the person's Social Security number (U.S. only).", + "type": "string" + }, + "verification": { + "description": "The person's verification status.", + "properties": { + "additional_document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + }, + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + } + }, + "title": "person_verification_specs", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/person" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/persons/{person}": { + "delete": { + "description": "

Deletes an existing person’s relationship to the account’s legal entity. Any person with a relationship for an account can be deleted through the API, except if the person is the account_opener. If your integration is using the executive parameter, you cannot delete the only verified executive on file.

", + "operationId": "DeleteAccountsAccountPersonsPerson", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "person", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_person" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves an existing person.

", + "operationId": "GetAccountsAccountPersonsPerson", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "person", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/person" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates an existing person.

", + "operationId": "PostAccountsAccountPersonsPerson", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "person", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "additional_tos_acceptances": { + "explode": true, + "style": "deepObject" + }, + "address": { + "explode": true, + "style": "deepObject" + }, + "address_kana": { + "explode": true, + "style": "deepObject" + }, + "address_kanji": { + "explode": true, + "style": "deepObject" + }, + "dob": { + "explode": true, + "style": "deepObject" + }, + "documents": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "full_name_aliases": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "registered_address": { + "explode": true, + "style": "deepObject" + }, + "relationship": { + "explode": true, + "style": "deepObject" + }, + "verification": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "additional_tos_acceptances": { + "description": "Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.", + "properties": { + "account": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "settings_terms_of_service_specs", + "type": "object" + } + }, + "title": "person_additional_tos_acceptances_specs", + "type": "object" + }, + "address": { + "description": "The person's address.", + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "legal_entity_and_kyc_address_specs", + "type": "object" + }, + "address_kana": { + "description": "The Kana variation of the person's address (Japan only).", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "description": "The Kanji variation of the person's address (Japan only).", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "dob": { + "anyOf": [ + { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The person's date of birth." + }, + "documents": { + "description": "Documents that may be submitted to satisfy various informational requests.", + "properties": { + "company_authorization": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "passport": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "visa": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } + }, + "title": "person_documents_specs", + "type": "object" + }, + "email": { + "description": "The person's email address.", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "first_name": { + "description": "The person's first name.", + "maxLength": 5000, + "type": "string" + }, + "first_name_kana": { + "description": "The Kana variation of the person's first name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "first_name_kanji": { + "description": "The Kanji variation of the person's first name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "full_name_aliases": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A list of alternate names or aliases that the person is known by." + }, + "gender": { + "description": "The person's gender (International regulations require either \"male\" or \"female\").", + "type": "string" + }, + "id_number": { + "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).", + "maxLength": 5000, + "type": "string" + }, + "id_number_secondary": { + "description": "The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).", + "maxLength": 5000, + "type": "string" + }, + "last_name": { + "description": "The person's last name.", + "maxLength": 5000, + "type": "string" + }, + "last_name_kana": { + "description": "The Kana variation of the person's last name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "last_name_kanji": { + "description": "The Kanji variation of the person's last name (Japan only).", + "maxLength": 5000, + "type": "string" + }, + "maiden_name": { + "description": "The person's maiden name.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "nationality": { + "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", + "maxLength": 5000, + "type": "string" + }, + "person_token": { + "description": "A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.", + "maxLength": 5000, + "type": "string" + }, + "phone": { + "description": "The person's phone number.", + "type": "string" + }, + "political_exposure": { + "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", + "maxLength": 5000, + "type": "string" + }, + "registered_address": { + "description": "The person's registered address.", + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "relationship": { + "description": "The relationship that this person has with the account's legal entity.", + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "legal_guardian": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "percent_ownership": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "representative": { + "type": "boolean" + }, + "title": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "relationship_specs", + "type": "object" + }, + "ssn_last_4": { + "description": "The last four digits of the person's Social Security number (U.S. only).", + "type": "string" + }, + "verification": { + "description": "The person's verification status.", + "properties": { + "additional_document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + }, + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + } + }, + "title": "person_verification_specs", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/person" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/accounts/{account}/reject": { + "post": { + "description": "

With Connect, you can reject accounts that you have flagged as suspicious.

\n\n

Only accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time. Live-mode accounts can only be rejected after all balances are zero.

", + "operationId": "PostAccountsAccountReject", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "reason": { + "description": "The reason for rejecting the account. Can be `fraud`, `terms_of_service`, or `other`.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["reason"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/apple_pay/domains": { + "get": { + "description": "

List apple pay domains.

", + "operationId": "GetApplePayDomains", + "parameters": [ + { + "in": "query", + "name": "domain_name", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/apple_pay_domain" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/apple_pay/domains", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ApplePayDomainList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Create an apple pay domain.

", + "operationId": "PostApplePayDomains", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "domain_name": { + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "required": ["domain_name"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/apple_pay_domain" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/apple_pay/domains/{domain}": { + "delete": { + "description": "

Delete an apple pay domain.

", + "operationId": "DeleteApplePayDomainsDomain", + "parameters": [ + { + "in": "path", + "name": "domain", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_apple_pay_domain" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieve an apple pay domain.

", + "operationId": "GetApplePayDomainsDomain", + "parameters": [ + { + "in": "path", + "name": "domain", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/apple_pay_domain" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/application_fees": { + "get": { + "description": "

Returns a list of application fees you’ve previously collected. The application fees are returned in sorted order, with the most recent fees appearing first.

", + "operationId": "GetApplicationFees", + "parameters": [ + { + "description": "Only return application fees for the charge specified by this charge ID.", + "in": "query", + "name": "charge", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return applications fees that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/application_fee" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/application_fees", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PlatformEarningList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/application_fees/{fee}/refunds/{id}": { + "get": { + "description": "

By default, you can see the 10 most recent refunds stored directly on the application fee object, but you can also retrieve details about a specific refund stored on the application fee.

", + "operationId": "GetApplicationFeesFeeRefundsId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "fee", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/fee_refund" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the specified application fee refund by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

This request only accepts metadata as an argument.

", + "operationId": "PostApplicationFeesFeeRefundsId", + "parameters": [ + { + "in": "path", + "name": "fee", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/fee_refund" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/application_fees/{id}": { + "get": { + "description": "

Retrieves the details of an application fee that your account has collected. The same information is returned when refunding the application fee.

", + "operationId": "GetApplicationFeesId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/application_fee" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/application_fees/{id}/refund": { + "post": { + "description": "", + "operationId": "PostApplicationFeesIdRefund", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "type": "integer" + }, + "directive": { + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/application_fee" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/application_fees/{id}/refunds": { + "get": { + "description": "

You can see a list of the refunds belonging to a specific application fee. Note that the 10 most recent refunds are always available by default on the application fee object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional refunds.

", + "operationId": "GetApplicationFeesIdRefunds", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/fee_refund" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "FeeRefundList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Refunds an application fee that has previously been collected but not yet refunded.\nFunds will be refunded to the Stripe account from which the fee was originally collected.

\n\n

You can optionally refund only part of an application fee.\nYou can do so multiple times, until the entire fee has been refunded.

\n\n

Once entirely refunded, an application fee can’t be refunded again.\nThis method will raise an error when called on an already-refunded application fee,\nor when trying to refund more money than is left on an application fee.

", + "operationId": "PostApplicationFeesIdRefunds", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "A positive integer, in _cents (or local equivalent)_, representing how much of this fee to refund. Can refund only up to the remaining unrefunded amount of the fee.", + "type": "integer" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/fee_refund" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/apps/secrets": { + "get": { + "description": "

List all secrets stored on the given scope.

", + "operationId": "GetAppsSecrets", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.", + "explode": true, + "in": "query", + "name": "scope", + "required": true, + "schema": { + "properties": { + "type": { + "enum": ["account", "user"], + "type": "string" + }, + "user": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "scope_param", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/apps.secret" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/apps/secrets", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SecretServiceResourceSecretList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Create or replace a secret in the secret store.

", + "operationId": "PostAppsSecrets", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "scope": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "expires_at": { + "description": "The Unix timestamp for the expiry time of the secret, after which the secret deletes.", + "format": "unix-time", + "type": "integer" + }, + "name": { + "description": "A name for the secret that's unique within the scope.", + "maxLength": 5000, + "type": "string" + }, + "payload": { + "description": "The plaintext secret value to be stored.", + "maxLength": 5000, + "type": "string" + }, + "scope": { + "description": "Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.", + "properties": { + "type": { + "enum": ["account", "user"], + "type": "string" + }, + "user": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "scope_param", + "type": "object" + } + }, + "required": ["name", "payload", "scope"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/apps.secret" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/apps/secrets/delete": { + "post": { + "description": "

Deletes a secret from the secret store by name and scope.

", + "operationId": "PostAppsSecretsDelete", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "scope": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "name": { + "description": "A name for the secret that's unique within the scope.", + "maxLength": 5000, + "type": "string" + }, + "scope": { + "description": "Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.", + "properties": { + "type": { + "enum": ["account", "user"], + "type": "string" + }, + "user": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "scope_param", + "type": "object" + } + }, + "required": ["name", "scope"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/apps.secret" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/apps/secrets/find": { + "get": { + "description": "

Finds a secret in the secret store by name and scope.

", + "operationId": "GetAppsSecretsFind", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A name for the secret that's unique within the scope.", + "in": "query", + "name": "name", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.", + "explode": true, + "in": "query", + "name": "scope", + "required": true, + "schema": { + "properties": { + "type": { + "enum": ["account", "user"], + "type": "string" + }, + "user": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "scope_param", + "type": "object" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/apps.secret" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/balance": { + "get": { + "description": "

Retrieves the current account balance, based on the authentication that was used to make the request.\n For a sample request, see Accounting for negative balances.

", + "operationId": "GetBalance", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/balance" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/balance/history": { + "get": { + "description": "

Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.

\n\n

Note that this endpoint was previously called “Balance history” and used the path /v1/balance/history.

", + "operationId": "GetBalanceHistory", + "parameters": [ + { + "description": "Only return transactions that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return transactions in a certain currency. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "in": "query", + "name": "currency", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "For automatic Stripe payouts only, only returns transactions that were paid out on the specified payout ID.", + "in": "query", + "name": "payout", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only returns the original transaction.", + "in": "query", + "name": "source", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `climate_order_purchase`, `climate_order_refund`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_outbound`, `obligation_reversal_inbound`, `payment`, `payment_failure_refund`, `payment_network_reserve_hold`, `payment_network_reserve_release`, `payment_refund`, `payment_reversal`, `payment_unreconciled`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.", + "in": "query", + "name": "type", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/balance_transaction" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/balance_transactions", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "BalanceTransactionsList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/balance/history/{id}": { + "get": { + "description": "

Retrieves the balance transaction with the given ID.

\n\n

Note that this endpoint previously used the path /v1/balance/history/:id.

", + "operationId": "GetBalanceHistoryId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/balance_transaction" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/balance_transactions": { + "get": { + "description": "

Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.

\n\n

Note that this endpoint was previously called “Balance history” and used the path /v1/balance/history.

", + "operationId": "GetBalanceTransactions", + "parameters": [ + { + "description": "Only return transactions that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return transactions in a certain currency. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "in": "query", + "name": "currency", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "For automatic Stripe payouts only, only returns transactions that were paid out on the specified payout ID.", + "in": "query", + "name": "payout", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only returns the original transaction.", + "in": "query", + "name": "source", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `climate_order_purchase`, `climate_order_refund`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_outbound`, `obligation_reversal_inbound`, `payment`, `payment_failure_refund`, `payment_network_reserve_hold`, `payment_network_reserve_release`, `payment_refund`, `payment_reversal`, `payment_unreconciled`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.", + "in": "query", + "name": "type", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/balance_transaction" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/balance_transactions", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "BalanceTransactionsList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/balance_transactions/{id}": { + "get": { + "description": "

Retrieves the balance transaction with the given ID.

\n\n

Note that this endpoint previously used the path /v1/balance/history/:id.

", + "operationId": "GetBalanceTransactionsId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/balance_transaction" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/alerts": { + "get": { + "description": "

Lists billing active and inactive alerts

", + "operationId": "GetBillingAlerts", + "parameters": [ + { + "description": "Filter results to only include this type of alert.", + "in": "query", + "name": "alert_type", + "required": false, + "schema": { + "enum": ["usage_threshold"], + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Filter results to only include alerts with the given meter.", + "in": "query", + "name": "meter", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/billing.alert" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/billing/alerts", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ThresholdsResourceAlertList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a billing alert

", + "operationId": "PostBillingAlerts", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "filter": { + "explode": true, + "style": "deepObject" + }, + "usage_threshold_config": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "alert_type": { + "description": "The type of alert to create.", + "enum": ["usage_threshold"], + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "filter": { + "description": "Filters to limit the scope of an alert.", + "properties": { + "customer": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "alert_filter", + "type": "object" + }, + "title": { + "description": "The title of the alert.", + "maxLength": 256, + "type": "string" + }, + "usage_threshold_config": { + "description": "The configuration of the usage threshold.", + "properties": { + "gte": { + "type": "integer" + }, + "meter": { + "maxLength": 5000, + "type": "string" + }, + "recurrence": { + "enum": ["one_time"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["gte", "recurrence"], + "title": "usage_threshold_config", + "type": "object" + } + }, + "required": ["alert_type", "title"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.alert" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/alerts/{id}": { + "get": { + "description": "

Retrieves a billing alert given an ID

", + "operationId": "GetBillingAlertsId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.alert" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/alerts/{id}/activate": { + "post": { + "description": "

Reactivates this alert, allowing it to trigger again.

", + "operationId": "PostBillingAlertsIdActivate", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.alert" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/alerts/{id}/archive": { + "post": { + "description": "

Archives this alert, removing it from the list view and APIs. This is non-reversible.

", + "operationId": "PostBillingAlertsIdArchive", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.alert" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/alerts/{id}/deactivate": { + "post": { + "description": "

Deactivates this alert, preventing it from triggering.

", + "operationId": "PostBillingAlertsIdDeactivate", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.alert" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/meter_event_adjustments": { + "post": { + "description": "

Creates a billing meter event adjustment

", + "operationId": "PostBillingMeterEventAdjustments", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "cancel": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "cancel": { + "description": "Specifies which event to cancel.", + "properties": { + "identifier": { + "maxLength": 100, + "type": "string" + } + }, + "title": "event_adjustment_cancel_settings_param", + "type": "object" + }, + "event_name": { + "description": "The name of the meter event. Corresponds with the `event_name` field on a meter.", + "maxLength": 100, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "type": { + "description": "Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.", + "enum": ["cancel"], + "type": "string" + } + }, + "required": ["event_name", "type"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.meter_event_adjustment" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/meter_events": { + "post": { + "description": "

Creates a billing meter event

", + "operationId": "PostBillingMeterEvents", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "payload": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "event_name": { + "description": "The name of the meter event. Corresponds with the `event_name` field on a meter.", + "maxLength": 100, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "identifier": { + "description": "A unique identifier for the event. If not provided, one will be generated. We recommend using a globally unique identifier for this. We'll enforce uniqueness within a rolling 24 hour period.", + "maxLength": 100, + "type": "string" + }, + "payload": { + "additionalProperties": { + "type": "string" + }, + "description": "The payload of the event. This must contain the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).", + "type": "object" + }, + "timestamp": { + "description": "The time of the event. Measured in seconds since the Unix epoch. Must be within the past 35 calendar days or up to 5 minutes in the future. Defaults to current timestamp if not specified.", + "format": "unix-time", + "type": "integer" + } + }, + "required": ["event_name", "payload"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.meter_event" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/meters": { + "get": { + "description": "

Retrieve a list of billing meters.

", + "operationId": "GetBillingMeters", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Filter results to only include meters with the given status.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["active", "inactive"], + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/billing.meter" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/billing/meters", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "BillingMeterResourceBillingMeterList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a billing meter

", + "operationId": "PostBillingMeters", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "customer_mapping": { + "explode": true, + "style": "deepObject" + }, + "default_aggregation": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "value_settings": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "customer_mapping": { + "description": "Fields that specify how to map a meter event to a customer.", + "properties": { + "event_payload_key": { + "maxLength": 100, + "type": "string" + }, + "type": { + "enum": ["by_id"], + "type": "string" + } + }, + "required": ["event_payload_key", "type"], + "title": "customer_mapping_param", + "type": "object" + }, + "default_aggregation": { + "description": "The default settings to aggregate a meter's events with.", + "properties": { + "formula": { + "enum": ["count", "sum"], + "type": "string" + } + }, + "required": ["formula"], + "title": "aggregation_settings_param", + "type": "object" + }, + "display_name": { + "description": "The meter's name.", + "maxLength": 250, + "type": "string" + }, + "event_name": { + "description": "The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.", + "maxLength": 100, + "type": "string" + }, + "event_time_window": { + "description": "The time window to pre-aggregate meter events for, if any.", + "enum": ["day", "hour"], + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "value_settings": { + "description": "Fields that specify how to calculate a meter event's value.", + "properties": { + "event_payload_key": { + "maxLength": 100, + "type": "string" + } + }, + "required": ["event_payload_key"], + "title": "meter_value_settings_param", + "type": "object" + } + }, + "required": [ + "default_aggregation", + "display_name", + "event_name" + ], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.meter" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/meters/{id}": { + "get": { + "description": "

Retrieves a billing meter given an ID

", + "operationId": "GetBillingMetersId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "Unique identifier for the object.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.meter" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates a billing meter

", + "operationId": "PostBillingMetersId", + "parameters": [ + { + "description": "Unique identifier for the object.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "display_name": { + "description": "The meter's name.", + "maxLength": 250, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.meter" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/meters/{id}/deactivate": { + "post": { + "description": "

Deactivates a billing meter

", + "operationId": "PostBillingMetersIdDeactivate", + "parameters": [ + { + "description": "Unique identifier for the object.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.meter" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/meters/{id}/event_summaries": { + "get": { + "description": "

Retrieve a list of billing meter event summaries.

", + "operationId": "GetBillingMetersIdEventSummaries", + "parameters": [ + { + "description": "The customer for which to fetch event summaries.", + "in": "query", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "The timestamp from when to stop aggregating meter events (exclusive). Must be aligned with minute boundaries.", + "in": "query", + "name": "end_time", + "required": true, + "schema": { + "format": "unix-time", + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "Unique identifier for the object.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "The timestamp from when to start aggregating meter events (inclusive). Must be aligned with minute boundaries.", + "in": "query", + "name": "start_time", + "required": true, + "schema": { + "format": "unix-time", + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies what granularity to use when generating event summaries. If not specified, a single event summary would be returned for the specified time range. For hourly granularity, start and end times must align with hour boundaries (e.g., 00:00, 01:00, ..., 23:00). For daily granularity, start and end times must align with UTC day boundaries (00:00 UTC).", + "in": "query", + "name": "value_grouping_window", + "required": false, + "schema": { + "enum": ["day", "hour"], + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/billing.meter_event_summary" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/billing/meters/[^/]+/event_summaries", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "BillingMeterResourceBillingMeterEventSummaryList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing/meters/{id}/reactivate": { + "post": { + "description": "

Reactivates a billing meter

", + "operationId": "PostBillingMetersIdReactivate", + "parameters": [ + { + "description": "Unique identifier for the object.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing.meter" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing_portal/configurations": { + "get": { + "description": "

Returns a list of configurations that describe the functionality of the customer portal.

", + "operationId": "GetBillingPortalConfigurations", + "parameters": [ + { + "description": "Only return configurations that are active or inactive (e.g., pass `true` to only list active configurations).", + "in": "query", + "name": "active", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "Only return the default or non-default configurations (e.g., pass `true` to only list the default configuration).", + "in": "query", + "name": "is_default", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/billing_portal.configuration" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/billing_portal/configurations", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PortalPublicResourceConfigurationList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a configuration that describes the functionality and behavior of a PortalSession

", + "operationId": "PostBillingPortalConfigurations", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "business_profile": { + "explode": true, + "style": "deepObject" + }, + "default_return_url": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "features": { + "explode": true, + "style": "deepObject" + }, + "login_page": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "business_profile": { + "description": "The business information shown to customers in the portal.", + "properties": { + "headline": { + "anyOf": [ + { + "maxLength": 60, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "privacy_policy_url": { + "type": "string" + }, + "terms_of_service_url": { + "type": "string" + } + }, + "title": "business_profile_create_param", + "type": "object" + }, + "default_return_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "features": { + "description": "Information about the features available in the portal.", + "properties": { + "customer_update": { + "properties": { + "allowed_updates": { + "anyOf": [ + { + "items": { + "enum": [ + "address", + "email", + "name", + "phone", + "shipping", + "tax_id" + ], + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "customer_update_creation_param", + "type": "object" + }, + "invoice_history": { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "invoice_list_param", + "type": "object" + }, + "payment_method_update": { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "payment_method_update_param", + "type": "object" + }, + "subscription_cancel": { + "properties": { + "cancellation_reason": { + "properties": { + "enabled": { + "type": "boolean" + }, + "options": { + "anyOf": [ + { + "items": { + "enum": [ + "customer_service", + "low_quality", + "missing_features", + "other", + "switched_service", + "too_complex", + "too_expensive", + "unused" + ], + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "required": ["enabled", "options"], + "title": "subscription_cancellation_reason_creation_param", + "type": "object" + }, + "enabled": { + "type": "boolean" + }, + "mode": { + "enum": ["at_period_end", "immediately"], + "type": "string" + }, + "proration_behavior": { + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + } + }, + "required": ["enabled"], + "title": "subscription_cancel_creation_param", + "type": "object" + }, + "subscription_update": { + "properties": { + "default_allowed_updates": { + "anyOf": [ + { + "items": { + "enum": [ + "price", + "promotion_code", + "quantity" + ], + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "enabled": { + "type": "boolean" + }, + "products": { + "anyOf": [ + { + "items": { + "properties": { + "prices": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "product": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["prices", "product"], + "title": "subscription_update_product_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "proration_behavior": { + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + } + }, + "required": [ + "default_allowed_updates", + "enabled", + "products" + ], + "title": "subscription_update_creation_param", + "type": "object" + } + }, + "title": "features_creation_param", + "type": "object" + }, + "login_page": { + "description": "The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).", + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "login_page_create_param", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + } + }, + "required": ["business_profile", "features"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing_portal.configuration" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing_portal/configurations/{configuration}": { + "get": { + "description": "

Retrieves a configuration that describes the functionality of the customer portal.

", + "operationId": "GetBillingPortalConfigurationsConfiguration", + "parameters": [ + { + "in": "path", + "name": "configuration", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing_portal.configuration" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates a configuration that describes the functionality of the customer portal.

", + "operationId": "PostBillingPortalConfigurationsConfiguration", + "parameters": [ + { + "in": "path", + "name": "configuration", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "business_profile": { + "explode": true, + "style": "deepObject" + }, + "default_return_url": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "features": { + "explode": true, + "style": "deepObject" + }, + "login_page": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Whether the configuration is active and can be used to create portal sessions.", + "type": "boolean" + }, + "business_profile": { + "description": "The business information shown to customers in the portal.", + "properties": { + "headline": { + "anyOf": [ + { + "maxLength": 60, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "privacy_policy_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "terms_of_service_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "business_profile_update_param", + "type": "object" + }, + "default_return_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "features": { + "description": "Information about the features available in the portal.", + "properties": { + "customer_update": { + "properties": { + "allowed_updates": { + "anyOf": [ + { + "items": { + "enum": [ + "address", + "email", + "name", + "phone", + "shipping", + "tax_id" + ], + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "enabled": { + "type": "boolean" + } + }, + "title": "customer_update_updating_param", + "type": "object" + }, + "invoice_history": { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "invoice_list_param", + "type": "object" + }, + "payment_method_update": { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "payment_method_update_param", + "type": "object" + }, + "subscription_cancel": { + "properties": { + "cancellation_reason": { + "properties": { + "enabled": { + "type": "boolean" + }, + "options": { + "anyOf": [ + { + "items": { + "enum": [ + "customer_service", + "low_quality", + "missing_features", + "other", + "switched_service", + "too_complex", + "too_expensive", + "unused" + ], + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "required": ["enabled"], + "title": "subscription_cancellation_reason_updating_param", + "type": "object" + }, + "enabled": { + "type": "boolean" + }, + "mode": { + "enum": ["at_period_end", "immediately"], + "type": "string" + }, + "proration_behavior": { + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + } + }, + "title": "subscription_cancel_updating_param", + "type": "object" + }, + "subscription_update": { + "properties": { + "default_allowed_updates": { + "anyOf": [ + { + "items": { + "enum": [ + "price", + "promotion_code", + "quantity" + ], + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "enabled": { + "type": "boolean" + }, + "products": { + "anyOf": [ + { + "items": { + "properties": { + "prices": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "product": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["prices", "product"], + "title": "subscription_update_product_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "proration_behavior": { + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + } + }, + "title": "subscription_update_updating_param", + "type": "object" + } + }, + "title": "features_updating_param", + "type": "object" + }, + "login_page": { + "description": "The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).", + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "login_page_update_param", + "type": "object" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing_portal.configuration" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/billing_portal/sessions": { + "post": { + "description": "

Creates a session of the customer portal.

", + "operationId": "PostBillingPortalSessions", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "flow_data": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "configuration": { + "description": "The ID of an existing [configuration](https://stripe.com/docs/api/customer_portal/configuration) to use for this session, describing its functionality and features. If not specified, the session uses the default configuration.", + "maxLength": 5000, + "type": "string" + }, + "customer": { + "description": "The ID of an existing customer.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "flow_data": { + "description": "Information about a specific flow for the customer to go through. See the [docs](https://stripe.com/docs/customer-management/portal-deep-links) to learn more about using customer portal deep links and flows.", + "properties": { + "after_completion": { + "properties": { + "hosted_confirmation": { + "properties": { + "custom_message": { + "maxLength": 500, + "type": "string" + } + }, + "title": "after_completion_hosted_confirmation_param", + "type": "object" + }, + "redirect": { + "properties": { + "return_url": { + "type": "string" + } + }, + "required": ["return_url"], + "title": "after_completion_redirect_param", + "type": "object" + }, + "type": { + "enum": [ + "hosted_confirmation", + "portal_homepage", + "redirect" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "flow_data_after_completion_param", + "type": "object" + }, + "subscription_cancel": { + "properties": { + "retention": { + "properties": { + "coupon_offer": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["coupon"], + "title": "coupon_offer_param", + "type": "object" + }, + "type": { + "enum": ["coupon_offer"], + "type": "string" + } + }, + "required": ["coupon_offer", "type"], + "title": "retention_param", + "type": "object" + }, + "subscription": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["subscription"], + "title": "flow_data_subscription_cancel_param", + "type": "object" + }, + "subscription_update": { + "properties": { + "subscription": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["subscription"], + "title": "flow_data_subscription_update_param", + "type": "object" + }, + "subscription_update_confirm": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "subscription_update_confirm_discount_params", + "type": "object" + }, + "type": "array" + }, + "items": { + "items": { + "properties": { + "id": { + "maxLength": 5000, + "type": "string" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + } + }, + "required": ["id"], + "title": "subscription_update_confirm_item_params", + "type": "object" + }, + "type": "array" + }, + "subscription": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["items", "subscription"], + "title": "flow_data_subscription_update_confirm_param", + "type": "object" + }, + "type": { + "enum": [ + "payment_method_update", + "subscription_cancel", + "subscription_update", + "subscription_update_confirm" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "flow_data_param", + "type": "object" + }, + "locale": { + "description": "The IETF language tag of the locale customer portal is displayed in. If blank or auto, the customer’s `preferred_locales` or browser’s locale is used.", + "enum": [ + "auto", + "bg", + "cs", + "da", + "de", + "el", + "en", + "en-AU", + "en-CA", + "en-GB", + "en-IE", + "en-IN", + "en-NZ", + "en-SG", + "es", + "es-419", + "et", + "fi", + "fil", + "fr", + "fr-CA", + "hr", + "hu", + "id", + "it", + "ja", + "ko", + "lt", + "lv", + "ms", + "mt", + "nb", + "nl", + "pl", + "pt", + "pt-BR", + "ro", + "ru", + "sk", + "sl", + "sv", + "th", + "tr", + "vi", + "zh", + "zh-HK", + "zh-TW" + ], + "type": "string" + }, + "on_behalf_of": { + "description": "The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.", + "type": "string" + }, + "return_url": { + "description": "The default URL to redirect customers to when they click on the portal's link to return to your website.", + "type": "string" + } + }, + "required": ["customer"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/billing_portal.session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/charges": { + "get": { + "description": "

Returns a list of charges you’ve previously created. The charges are returned in sorted order, with the most recent charges appearing first.

", + "operationId": "GetCharges", + "parameters": [ + { + "description": "Only return charges that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return charges for the customer specified by this customer ID.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Only return charges that were created by the PaymentIntent specified by this PaymentIntent ID.", + "in": "query", + "name": "payment_intent", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return charges for this transfer group, limited to 100.", + "in": "query", + "name": "transfer_group", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/charge" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/charges", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ChargeList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

This method is no longer recommended—use the Payment Intents API\nto initiate a new payment instead. Confirmation of the PaymentIntent creates the Charge\nobject used to request payment.

", + "operationId": "PostCharges", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "card": { + "explode": true, + "style": "deepObject" + }, + "destination": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "radar_options": { + "explode": true, + "style": "deepObject" + }, + "shipping": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", + "type": "integer" + }, + "application_fee": { + "type": "integer" + }, + "application_fee_amount": { + "description": "A fee in cents (or local equivalent) that will be applied to the charge and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the `Stripe-Account` header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/connect/direct-charges#collect-fees).", + "type": "integer" + }, + "capture": { + "description": "Whether to immediately capture the charge. Defaults to `true`. When `false`, the charge issues an authorization (or pre-authorization), and will need to be [captured](https://stripe.com/docs/api#capture_charge) later. Uncaptured charges expire after a set number of days (7 by default). For more information, see the [authorizing charges and settling later](https://stripe.com/docs/charges/placing-a-hold) documentation.", + "type": "boolean" + }, + "card": { + "anyOf": [ + { + "properties": { + "address_city": { + "maxLength": 5000, + "type": "string" + }, + "address_country": { + "maxLength": 5000, + "type": "string" + }, + "address_line1": { + "maxLength": 5000, + "type": "string" + }, + "address_line2": { + "maxLength": 5000, + "type": "string" + }, + "address_state": { + "maxLength": 5000, + "type": "string" + }, + "address_zip": { + "maxLength": 5000, + "type": "string" + }, + "cvc": { + "maxLength": 5000, + "type": "string" + }, + "exp_month": { + "type": "integer" + }, + "exp_year": { + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "number": { + "maxLength": 5000, + "type": "string" + }, + "object": { + "enum": ["card"], + "maxLength": 5000, + "type": "string" + } + }, + "required": ["exp_month", "exp_year", "number"], + "title": "customer_payment_source_card", + "type": "object" + }, + { + "maxLength": 5000, + "type": "string" + } + ], + "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js).", + "x-stripeBypassValidation": true + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "The ID of an existing customer that will be charged in this request.", + "maxLength": 500, + "type": "string" + }, + "description": { + "description": "An arbitrary string which you can attach to a `Charge` object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.", + "maxLength": 40000, + "type": "string" + }, + "destination": { + "anyOf": [ + { + "properties": { + "account": { + "maxLength": 5000, + "type": "string" + }, + "amount": { + "type": "integer" + } + }, + "required": ["account"], + "title": "destination_specs", + "type": "object" + }, + { + "type": "string" + } + ] + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "on_behalf_of": { + "description": "The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant).", + "maxLength": 5000, + "type": "string" + }, + "radar_options": { + "description": "Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.", + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "receipt_email": { + "description": "The email address to which this charge's [receipt](https://stripe.com/docs/dashboard/receipts) will be sent. The receipt will not be sent until the charge is paid, and no receipts will be sent for test mode charges. If this charge is for a [Customer](https://stripe.com/docs/api/customers/object), the email address specified here will override the customer's email address. If `receipt_email` is specified for a charge in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).", + "type": "string" + }, + "shipping": { + "description": "Shipping information for the charge. Helps prevent fraud on charges for physical goods.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "tracking_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["address", "name"], + "title": "optional_fields_shipping", + "type": "object" + }, + "source": { + "description": "A payment source to be charged. This can be the ID of a [card](https://stripe.com/docs/api#cards) (i.e., credit or debit card), a [bank account](https://stripe.com/docs/api#bank_accounts), a [source](https://stripe.com/docs/api#sources), a [token](https://stripe.com/docs/api#tokens), or a [connected account](https://stripe.com/docs/connect/account-debits#charging-a-connected-account). For certain sources---namely, [cards](https://stripe.com/docs/api#cards), [bank accounts](https://stripe.com/docs/api#bank_accounts), and attached [sources](https://stripe.com/docs/api#sources)---you must also pass the ID of the associated customer.", + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "statement_descriptor": { + "description": "For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).\n\nFor a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.", + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_suffix": { + "description": "Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.", + "maxLength": 22, + "type": "string" + }, + "transfer_data": { + "description": "An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.", + "properties": { + "amount": { + "type": "integer" + }, + "destination": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + "transfer_group": { + "description": "A string that identifies this transaction as part of a group. For details, see [Grouping transactions](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options).", + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/charge" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/charges/search": { + "get": { + "description": "

Search for charges you’ve previously created using Stripe’s Search Query Language.\nDon’t use search in read-after-write flows where strict consistency is necessary. Under normal operating\nconditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up\nto an hour behind during outages. Search functionality is not available to merchants in India.

", + "operationId": "GetChargesSearch", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.", + "in": "query", + "name": "page", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for charges](https://stripe.com/docs/search#query-fields-for-charges).", + "in": "query", + "name": "query", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/charge" + }, + "type": "array" + }, + "has_more": { + "type": "boolean" + }, + "next_page": { + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["search_result"], + "type": "string" + }, + "total_count": { + "description": "The total number of objects that match the query, only accurate up to 10,000.", + "type": "integer" + }, + "url": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SearchResult", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/charges/{charge}": { + "get": { + "description": "

Retrieves the details of a charge that has previously been created. Supply the unique charge ID that was returned from your previous request, and Stripe will return the corresponding charge information. The same information is returned when creating or refunding the charge.

", + "operationId": "GetChargesCharge", + "parameters": [ + { + "in": "path", + "name": "charge", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/charge" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", + "operationId": "PostChargesCharge", + "parameters": [ + { + "in": "path", + "name": "charge", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "fraud_details": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "shipping": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "customer": { + "description": "The ID of an existing customer that will be associated with this request. This field may only be updated if there is no existing associated customer with this charge.", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string which you can attach to a charge object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.", + "maxLength": 40000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "fraud_details": { + "description": "A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms.", + "properties": { + "user_report": { + "enum": ["", "fraudulent", "safe"], + "maxLength": 5000, + "type": "string" + } + }, + "required": ["user_report"], + "title": "fraud_details", + "type": "object" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "receipt_email": { + "description": "This is the email address that the receipt for this charge will be sent to. If this field is updated, then a new email receipt will be sent to the updated address.", + "maxLength": 5000, + "type": "string" + }, + "shipping": { + "description": "Shipping information for the charge. Helps prevent fraud on charges for physical goods.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "tracking_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["address", "name"], + "title": "optional_fields_shipping", + "type": "object" + }, + "transfer_group": { + "description": "A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.", + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/charge" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/charges/{charge}/capture": { + "post": { + "description": "

Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.

\n\n

Uncaptured payments expire a set number of days after they are created (7 by default), after which they are marked as refunded and capture attempts will fail.

\n\n

Don’t use this method to capture a PaymentIntent-initiated charge. Use Capture a PaymentIntent.

", + "operationId": "PostChargesChargeCapture", + "parameters": [ + { + "in": "path", + "name": "charge", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "The amount to capture, which must be less than or equal to the original amount. Any additional amount will be automatically refunded.", + "type": "integer" + }, + "application_fee": { + "description": "An application fee to add on to this charge.", + "type": "integer" + }, + "application_fee_amount": { + "description": "An application fee amount to add on to this charge, which must be less than or equal to the original amount.", + "type": "integer" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "receipt_email": { + "description": "The email address to send this charge's receipt to. This will override the previously-specified email address for this charge, if one was set. Receipts will not be sent in test mode.", + "type": "string" + }, + "statement_descriptor": { + "description": "For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).\n\nFor a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.", + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_suffix": { + "description": "Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.", + "maxLength": 22, + "type": "string" + }, + "transfer_data": { + "description": "An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.", + "properties": { + "amount": { + "type": "integer" + } + }, + "title": "transfer_data_specs", + "type": "object" + }, + "transfer_group": { + "description": "A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.", + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/charge" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/charges/{charge}/dispute": { + "get": { + "description": "

Retrieve a dispute for a specified charge.

", + "operationId": "GetChargesChargeDispute", + "parameters": [ + { + "in": "path", + "name": "charge", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/dispute" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "", + "operationId": "PostChargesChargeDispute", + "parameters": [ + { + "in": "path", + "name": "charge", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "evidence": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "evidence": { + "description": "Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.", + "properties": { + "access_activity_log": { + "maxLength": 20000, + "type": "string" + }, + "billing_address": { + "maxLength": 5000, + "type": "string" + }, + "cancellation_policy": { + "type": "string" + }, + "cancellation_policy_disclosure": { + "maxLength": 20000, + "type": "string" + }, + "cancellation_rebuttal": { + "maxLength": 20000, + "type": "string" + }, + "customer_communication": { + "type": "string" + }, + "customer_email_address": { + "maxLength": 5000, + "type": "string" + }, + "customer_name": { + "maxLength": 5000, + "type": "string" + }, + "customer_purchase_ip": { + "maxLength": 5000, + "type": "string" + }, + "customer_signature": { + "type": "string" + }, + "duplicate_charge_documentation": { + "type": "string" + }, + "duplicate_charge_explanation": { + "maxLength": 20000, + "type": "string" + }, + "duplicate_charge_id": { + "maxLength": 5000, + "type": "string" + }, + "product_description": { + "maxLength": 20000, + "type": "string" + }, + "receipt": { + "type": "string" + }, + "refund_policy": { + "type": "string" + }, + "refund_policy_disclosure": { + "maxLength": 20000, + "type": "string" + }, + "refund_refusal_explanation": { + "maxLength": 20000, + "type": "string" + }, + "service_date": { + "maxLength": 5000, + "type": "string" + }, + "service_documentation": { + "type": "string" + }, + "shipping_address": { + "maxLength": 5000, + "type": "string" + }, + "shipping_carrier": { + "maxLength": 5000, + "type": "string" + }, + "shipping_date": { + "maxLength": 5000, + "type": "string" + }, + "shipping_documentation": { + "type": "string" + }, + "shipping_tracking_number": { + "maxLength": 5000, + "type": "string" + }, + "uncategorized_file": { + "type": "string" + }, + "uncategorized_text": { + "maxLength": 20000, + "type": "string" + } + }, + "title": "dispute_evidence_params", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "submit": { + "description": "Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/dispute" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/charges/{charge}/dispute/close": { + "post": { + "description": "", + "operationId": "PostChargesChargeDisputeClose", + "parameters": [ + { + "in": "path", + "name": "charge", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/dispute" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/charges/{charge}/refund": { + "post": { + "description": "

When you create a new refund, you must specify either a Charge or a PaymentIntent object.

\n\n

This action refunds a previously created charge that’s not refunded yet.\nFunds are refunded to the credit or debit card that’s originally charged.

\n\n

You can optionally refund only part of a charge.\nYou can repeat this until the entire charge is refunded.

\n\n

After you entirely refund a charge, you can’t refund it again.\nThis method raises an error when it’s called on an already-refunded charge,\nor when you attempt to refund more money than is left on a charge.

", + "operationId": "PostChargesChargeRefund", + "parameters": [ + { + "description": "The identifier of the charge to refund.", + "in": "path", + "name": "charge", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) representing how much of this charge to refund. Can refund only up to the remaining, unrefunded amount of the charge.", + "type": "integer" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "instructions_email": { + "description": "For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions.", + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "payment_intent": { + "description": "The identifier of the PaymentIntent to refund.", + "maxLength": 5000, + "type": "string" + }, + "reason": { + "description": "String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.", + "enum": [ + "duplicate", + "fraudulent", + "requested_by_customer" + ], + "maxLength": 5000, + "type": "string" + }, + "refund_application_fee": { + "description": "Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.", + "type": "boolean" + }, + "reverse_transfer": { + "description": "Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).

A transfer can be reversed only by the application that created the charge.", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/charge" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/charges/{charge}/refunds": { + "get": { + "description": "

You can see a list of the refunds belonging to a specific charge. Note that the 10 most recent refunds are always available by default on the charge object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional refunds.

", + "operationId": "GetChargesChargeRefunds", + "parameters": [ + { + "in": "path", + "name": "charge", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/refund" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "RefundList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.

\n\n

Creating a new refund will refund a charge that has previously been created but not yet refunded.\nFunds will be refunded to the credit or debit card that was originally charged.

\n\n

You can optionally refund only part of a charge.\nYou can do so multiple times, until the entire charge has been refunded.

\n\n

Once entirely refunded, a charge can’t be refunded again.\nThis method will raise an error when called on an already-refunded charge,\nor when trying to refund more money than is left on a charge.

", + "operationId": "PostChargesChargeRefunds", + "parameters": [ + { + "description": "The identifier of the charge to refund.", + "in": "path", + "name": "charge", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "Customer whose customer balance to refund from.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "instructions_email": { + "description": "For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions.", + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "origin": { + "description": "Origin of the refund", + "enum": ["customer_balance"], + "type": "string" + }, + "payment_intent": { + "description": "The identifier of the PaymentIntent to refund.", + "maxLength": 5000, + "type": "string" + }, + "reason": { + "description": "String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.", + "enum": [ + "duplicate", + "fraudulent", + "requested_by_customer" + ], + "maxLength": 5000, + "type": "string" + }, + "refund_application_fee": { + "description": "Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.", + "type": "boolean" + }, + "reverse_transfer": { + "description": "Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).

A transfer can be reversed only by the application that created the charge.", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/refund" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/charges/{charge}/refunds/{refund}": { + "get": { + "description": "

Retrieves the details of an existing refund.

", + "operationId": "GetChargesChargeRefundsRefund", + "parameters": [ + { + "in": "path", + "name": "charge", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "refund", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/refund" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Update a specified refund.

", + "operationId": "PostChargesChargeRefundsRefund", + "parameters": [ + { + "in": "path", + "name": "charge", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "refund", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/refund" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/checkout/sessions": { + "get": { + "description": "

Returns a list of Checkout Sessions.

", + "operationId": "GetCheckoutSessions", + "parameters": [ + { + "description": "Only return Checkout Sessions that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return the Checkout Sessions for the Customer specified.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return the Checkout Sessions for the Customer details specified.", + "explode": true, + "in": "query", + "name": "customer_details", + "required": false, + "schema": { + "properties": { + "email": { + "type": "string" + } + }, + "required": ["email"], + "title": "customer_details_params", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Only return the Checkout Session for the PaymentIntent specified.", + "in": "query", + "name": "payment_intent", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return the Checkout Sessions for the Payment Link specified.", + "in": "query", + "name": "payment_link", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return the Checkout Sessions matching the given status.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["complete", "expired", "open"], + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return the Checkout Session for the subscription specified.", + "in": "query", + "name": "subscription", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/checkout.session" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PaymentPagesCheckoutSessionList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a Session object.

", + "operationId": "PostCheckoutSessions", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "after_expiration": { + "explode": true, + "style": "deepObject" + }, + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "consent_collection": { + "explode": true, + "style": "deepObject" + }, + "custom_fields": { + "explode": true, + "style": "deepObject" + }, + "custom_text": { + "explode": true, + "style": "deepObject" + }, + "customer_update": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "invoice_creation": { + "explode": true, + "style": "deepObject" + }, + "line_items": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "payment_intent_data": { + "explode": true, + "style": "deepObject" + }, + "payment_method_data": { + "explode": true, + "style": "deepObject" + }, + "payment_method_options": { + "explode": true, + "style": "deepObject" + }, + "payment_method_types": { + "explode": true, + "style": "deepObject" + }, + "phone_number_collection": { + "explode": true, + "style": "deepObject" + }, + "saved_payment_method_options": { + "explode": true, + "style": "deepObject" + }, + "setup_intent_data": { + "explode": true, + "style": "deepObject" + }, + "shipping_address_collection": { + "explode": true, + "style": "deepObject" + }, + "shipping_options": { + "explode": true, + "style": "deepObject" + }, + "subscription_data": { + "explode": true, + "style": "deepObject" + }, + "tax_id_collection": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "after_expiration": { + "description": "Configure actions after a Checkout Session has expired.", + "properties": { + "recovery": { + "properties": { + "allow_promotion_codes": { + "type": "boolean" + }, + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "recovery_params", + "type": "object" + } + }, + "title": "after_expiration_params", + "type": "object" + }, + "allow_promotion_codes": { + "description": "Enables user redeemable promotion codes.", + "type": "boolean" + }, + "automatic_tax": { + "description": "Settings for automatic tax lookup for this session and resulting payments, invoices, and subscriptions.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_params", + "type": "object" + }, + "billing_address_collection": { + "description": "Specify whether Checkout should collect the customer's billing address. Defaults to `auto`.", + "enum": ["auto", "required"], + "type": "string" + }, + "cancel_url": { + "description": "If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website. This parameter is not allowed if ui_mode is `embedded`.", + "maxLength": 5000, + "type": "string" + }, + "client_reference_id": { + "description": "A unique string to reference the Checkout Session. This can be a\ncustomer ID, a cart ID, or similar, and can be used to reconcile the\nsession with your internal systems.", + "maxLength": 200, + "type": "string" + }, + "consent_collection": { + "description": "Configure fields for the Checkout Session to gather active consent from customers.", + "properties": { + "payment_method_reuse_agreement": { + "properties": { + "position": { + "enum": ["auto", "hidden"], + "type": "string" + } + }, + "required": ["position"], + "title": "payment_method_reuse_agreement_params", + "type": "object" + }, + "promotions": { + "enum": ["auto", "none"], + "type": "string" + }, + "terms_of_service": { + "enum": ["none", "required"], + "type": "string" + } + }, + "title": "consent_collection_params", + "type": "object" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Required in `setup` mode when `payment_method_types` is not set.", + "type": "string" + }, + "custom_fields": { + "description": "Collect additional information from your customer using custom fields. Up to 3 fields are supported.", + "items": { + "properties": { + "dropdown": { + "properties": { + "default_value": { + "maxLength": 100, + "type": "string" + }, + "options": { + "items": { + "properties": { + "label": { + "maxLength": 100, + "type": "string" + }, + "value": { + "maxLength": 100, + "type": "string" + } + }, + "required": ["label", "value"], + "title": "custom_field_option_param", + "type": "object" + }, + "type": "array" + } + }, + "required": ["options"], + "title": "custom_field_dropdown_param", + "type": "object" + }, + "key": { + "maxLength": 200, + "type": "string" + }, + "label": { + "properties": { + "custom": { + "maxLength": 50, + "type": "string" + }, + "type": { + "enum": ["custom"], + "type": "string" + } + }, + "required": ["custom", "type"], + "title": "custom_field_label_param", + "type": "object" + }, + "numeric": { + "properties": { + "default_value": { + "maxLength": 255, + "type": "string" + }, + "maximum_length": { + "type": "integer" + }, + "minimum_length": { + "type": "integer" + } + }, + "title": "custom_field_numeric_param", + "type": "object" + }, + "optional": { + "type": "boolean" + }, + "text": { + "properties": { + "default_value": { + "maxLength": 255, + "type": "string" + }, + "maximum_length": { + "type": "integer" + }, + "minimum_length": { + "type": "integer" + } + }, + "title": "custom_field_text_param", + "type": "object" + }, + "type": { + "enum": ["dropdown", "numeric", "text"], + "type": "string" + } + }, + "required": ["key", "label", "type"], + "title": "custom_field_param", + "type": "object" + }, + "type": "array" + }, + "custom_text": { + "description": "Display additional text for your customers using custom text.", + "properties": { + "after_submit": { + "anyOf": [ + { + "properties": { + "message": { + "maxLength": 1200, + "type": "string" + } + }, + "required": ["message"], + "title": "custom_text_position_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "shipping_address": { + "anyOf": [ + { + "properties": { + "message": { + "maxLength": 1200, + "type": "string" + } + }, + "required": ["message"], + "title": "custom_text_position_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "submit": { + "anyOf": [ + { + "properties": { + "message": { + "maxLength": 1200, + "type": "string" + } + }, + "required": ["message"], + "title": "custom_text_position_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "terms_of_service_acceptance": { + "anyOf": [ + { + "properties": { + "message": { + "maxLength": 1200, + "type": "string" + } + }, + "required": ["message"], + "title": "custom_text_position_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "custom_text_param", + "type": "object" + }, + "customer": { + "description": "ID of an existing Customer, if one exists. In `payment` mode, the customer’s most recently saved card\npayment method will be used to prefill the email, name, card details, and billing address\non the Checkout page. In `subscription` mode, the customer’s [default payment method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method)\nwill be used if it’s a card, otherwise the most recently saved card will be used. A valid billing address, billing name and billing email are required on the payment method for Checkout to prefill the customer's card details.\n\nIf the Customer already has a valid [email](https://stripe.com/docs/api/customers/object#customer_object-email) set, the email will be prefilled and not editable in Checkout.\nIf the Customer does not have a valid `email`, Checkout will set the email entered during the session on the Customer.\n\nIf blank for Checkout Sessions in `subscription` mode or with `customer_creation` set as `always` in `payment` mode, Checkout will create a new Customer object based on information provided during the payment flow.\n\nYou can set [`payment_intent_data.setup_future_usage`](https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-payment_intent_data-setup_future_usage) to have Checkout automatically attach the payment method to the Customer you pass in for future reuse.", + "maxLength": 5000, + "type": "string" + }, + "customer_creation": { + "description": "Configure whether a Checkout Session creates a [Customer](https://stripe.com/docs/api/customers) during Session confirmation.\n\nWhen a Customer is not created, you can still retrieve email, address, and other customer data entered in Checkout\nwith [customer_details](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-customer_details).\n\nSessions that don't create Customers instead are grouped by [guest customers](https://stripe.com/docs/payments/checkout/guest-customers)\nin the Dashboard. Promotion codes limited to first time customers will return invalid for these Sessions.\n\nCan only be set in `payment` and `setup` mode.", + "enum": ["always", "if_required"], + "type": "string" + }, + "customer_email": { + "description": "If provided, this value will be used when the Customer object is created.\nIf not provided, customers will be asked to enter their email address.\nUse this parameter to prefill customer data if you already have an email\non file. To access information about the customer once a session is\ncomplete, use the `customer` field.", + "type": "string" + }, + "customer_update": { + "description": "Controls what fields on Customer can be updated by the Checkout Session. Can only be provided when `customer` is provided.", + "properties": { + "address": { + "enum": ["auto", "never"], + "type": "string", + "x-stripeBypassValidation": true + }, + "name": { + "enum": ["auto", "never"], + "type": "string", + "x-stripeBypassValidation": true + }, + "shipping": { + "enum": ["auto", "never"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "customer_update_params", + "type": "object" + }, + "discounts": { + "description": "The coupon or promotion code to apply to this Session. Currently, only up to one may be specified.", + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discount_params", + "type": "object" + }, + "type": "array" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "expires_at": { + "description": "The Epoch time in seconds at which the Checkout Session will expire. It can be anywhere from 30 minutes to 24 hours after Checkout Session creation. By default, this value is 24 hours from creation.", + "format": "unix-time", + "type": "integer" + }, + "invoice_creation": { + "description": "Generate a post-purchase Invoice for one-time payments.", + "properties": { + "enabled": { + "type": "boolean" + }, + "invoice_data": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "custom_fields": { + "anyOf": [ + { + "items": { + "properties": { + "name": { + "maxLength": 40, + "type": "string" + }, + "value": { + "maxLength": 140, + "type": "string" + } + }, + "required": ["name", "value"], + "title": "custom_field_params", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "description": { + "maxLength": 1500, + "type": "string" + }, + "footer": { + "maxLength": 5000, + "type": "string" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "rendering_options": { + "anyOf": [ + { + "properties": { + "amount_tax_display": { + "enum": [ + "", + "exclude_tax", + "include_inclusive_tax" + ], + "type": "string" + } + }, + "title": "rendering_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "invoice_data_params", + "type": "object" + } + }, + "required": ["enabled"], + "title": "invoice_creation_params", + "type": "object" + }, + "line_items": { + "description": "A list of items the customer is purchasing. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).\n\nFor `payment` mode, there is a maximum of 100 line items, however it is recommended to consolidate line items if there are more than a few dozen.\n\nFor `subscription` mode, there is a maximum of 20 line items with recurring Prices and 20 line items with one-time Prices. Line items with one-time Prices will be on the initial invoice only.", + "items": { + "properties": { + "adjustable_quantity": { + "properties": { + "enabled": { + "type": "boolean" + }, + "maximum": { + "type": "integer" + }, + "minimum": { + "type": "integer" + } + }, + "required": ["enabled"], + "title": "adjustable_quantity_params", + "type": "object" + }, + "dynamic_tax_rates": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "product_data": { + "properties": { + "description": { + "maxLength": 40000, + "type": "string" + }, + "images": { + "items": { + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "tax_code": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["name"], + "title": "product_data", + "type": "object" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency"], + "title": "price_data_with_product_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "title": "line_item_params", + "type": "object" + }, + "type": "array" + }, + "locale": { + "description": "The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.", + "enum": [ + "auto", + "bg", + "cs", + "da", + "de", + "el", + "en", + "en-GB", + "es", + "es-419", + "et", + "fi", + "fil", + "fr", + "fr-CA", + "hr", + "hu", + "id", + "it", + "ja", + "ko", + "lt", + "lv", + "ms", + "mt", + "nb", + "nl", + "pl", + "pt", + "pt-BR", + "ro", + "ru", + "sk", + "sl", + "sv", + "th", + "tr", + "vi", + "zh", + "zh-HK", + "zh-TW" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "mode": { + "description": "The mode of the Checkout Session. Pass `subscription` if the Checkout Session includes at least one recurring item.", + "enum": ["payment", "setup", "subscription"], + "type": "string" + }, + "payment_intent_data": { + "description": "A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.", + "properties": { + "application_fee_amount": { + "type": "integer" + }, + "capture_method": { + "enum": ["automatic", "automatic_async", "manual"], + "type": "string" + }, + "description": { + "maxLength": 1000, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "on_behalf_of": { + "type": "string" + }, + "receipt_email": { + "type": "string" + }, + "setup_future_usage": { + "enum": ["off_session", "on_session"], + "type": "string" + }, + "shipping": { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["line1"], + "title": "address", + "type": "object" + }, + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "tracking_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["address", "name"], + "title": "shipping", + "type": "object" + }, + "statement_descriptor": { + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_suffix": { + "maxLength": 22, + "type": "string" + }, + "transfer_data": { + "properties": { + "amount": { + "type": "integer" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_params", + "type": "object" + }, + "transfer_group": { + "type": "string" + } + }, + "title": "payment_intent_data_params", + "type": "object" + }, + "payment_method_collection": { + "description": "Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.\nThis may occur if the Checkout Session includes a free trial or a discount.\n\nCan only be set in `subscription` mode. Defaults to `always`.\n\nIf you'd like information on how to collect a payment method outside of Checkout, read the guide on configuring [subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).", + "enum": ["always", "if_required"], + "type": "string" + }, + "payment_method_configuration": { + "description": "The ID of the payment method configuration to use with this Checkout session.", + "maxLength": 100, + "type": "string" + }, + "payment_method_data": { + "description": "This parameter allows you to set some attributes on the payment method created during a Checkout session.", + "properties": { + "allow_redisplay": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + } + }, + "title": "payment_method_data_param", + "type": "object" + }, + "payment_method_options": { + "description": "Payment-method-specific configuration.", + "properties": { + "acss_debit": { + "properties": { + "currency": { + "enum": ["cad", "usd"], + "type": "string" + }, + "mandate_options": { + "properties": { + "custom_mandate_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "default_for": { + "items": { + "enum": ["invoice", "subscription"], + "type": "string" + }, + "type": "array" + }, + "interval_description": { + "maxLength": 500, + "type": "string" + }, + "payment_schedule": { + "enum": ["combined", "interval", "sporadic"], + "type": "string" + }, + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": ["none", "off_session", "on_session"], + "type": "string" + }, + "verification_method": { + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "affirm": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "afterpay_clearpay": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "alipay": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "amazon_pay": { + "properties": { + "setup_future_usage": { + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "au_becs_debit": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "setup_future_usage": { + "enum": ["none", "off_session", "on_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "bancontact": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "boleto": { + "properties": { + "expires_after_days": { + "type": "integer" + }, + "setup_future_usage": { + "enum": ["none", "off_session", "on_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "card": { + "properties": { + "installments": { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "title": "installments_param", + "type": "object" + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string", + "x-stripeBypassValidation": true + }, + "setup_future_usage": { + "enum": ["off_session", "on_session"], + "type": "string" + }, + "statement_descriptor_suffix_kana": { + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_suffix_kanji": { + "maxLength": 17, + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "cashapp": { + "properties": { + "setup_future_usage": { + "enum": ["none", "off_session", "on_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "customer_balance": { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_params", + "type": "object" + }, + "requested_address_types": { + "items": { + "enum": [ + "aba", + "iban", + "sepa", + "sort_code", + "spei", + "swift", + "zengin" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "type": { + "enum": [ + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "mx_bank_transfer", + "us_bank_transfer" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "enum": ["bank_transfer"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "eps": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "fpx": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "giropay": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "grabpay": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "ideal": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "klarna": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "konbini": { + "properties": { + "expires_after_days": { + "type": "integer" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "link": { + "properties": { + "setup_future_usage": { + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "mobilepay": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "multibanco": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "oxxo": { + "properties": { + "expires_after_days": { + "type": "integer" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "p24": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + }, + "tos_shown_and_accepted": { + "type": "boolean" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "paynow": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "paypal": { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "enum": [ + "cs-CZ", + "da-DK", + "de-AT", + "de-DE", + "de-LU", + "el-GR", + "en-GB", + "en-US", + "es-ES", + "fi-FI", + "fr-BE", + "fr-FR", + "fr-LU", + "hu-HU", + "it-IT", + "nl-BE", + "nl-NL", + "pl-PL", + "pt-PT", + "sk-SK", + "sv-SE" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "reference": { + "maxLength": 127, + "type": "string" + }, + "risk_correlation_id": { + "maxLength": 32, + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "pix": { + "properties": { + "expires_after_seconds": { + "type": "integer" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "revolut_pay": { + "properties": { + "setup_future_usage": { + "enum": ["none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "setup_future_usage": { + "enum": ["none", "off_session", "on_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "sofort": { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "swish": { + "properties": { + "reference": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "us_bank_account": { + "properties": { + "financial_connections": { + "properties": { + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + } + }, + "title": "linked_account_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": ["none", "off_session", "on_session"], + "type": "string" + }, + "verification_method": { + "enum": ["automatic", "instant"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "wechat_pay": { + "properties": { + "app_id": { + "maxLength": 5000, + "type": "string" + }, + "client": { + "enum": ["android", "ios", "web"], + "type": "string", + "x-stripeBypassValidation": true + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "required": ["client"], + "title": "payment_method_options_param", + "type": "object" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "payment_method_types": { + "description": "A list of the types of payment methods (e.g., `card`) this Checkout Session can accept.\n\nYou can omit this attribute to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).\nSee [Dynamic Payment Methods](https://stripe.com/docs/payments/payment-methods/integration-options#using-dynamic-payment-methods) for more details.\n\nRead more about the supported payment methods and their requirements in our [payment\nmethod details guide](/docs/payments/checkout/payment-methods).\n\nIf multiple payment methods are passed, Checkout will dynamically reorder them to\nprioritize the most relevant payment methods based on the customer's location and\nother characteristics.", + "items": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "phone_number_collection": { + "description": "Controls phone number collection settings for the session.\n\nWe recommend that you review your privacy policy and check with your legal contacts\nbefore using this feature. Learn more about [collecting phone numbers with Checkout](https://stripe.com/docs/payments/checkout/phone-numbers).", + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "phone_number_collection_params", + "type": "object" + }, + "redirect_on_completion": { + "description": "This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-redirect-behavior) of embedded sessions. Defaults to `always`.", + "enum": ["always", "if_required", "never"], + "type": "string" + }, + "return_url": { + "description": "The URL to redirect your customer back to after they authenticate or cancel their payment on the\npayment method's app or site. This parameter is required if ui_mode is `embedded`\nand redirect-based payment methods are enabled on the session.", + "maxLength": 5000, + "type": "string" + }, + "saved_payment_method_options": { + "description": "Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.", + "properties": { + "allow_redisplay_filters": { + "items": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "type": "array" + }, + "payment_method_save": { + "enum": ["disabled", "enabled"], + "type": "string" + } + }, + "title": "saved_payment_method_options_param", + "type": "object" + }, + "setup_intent_data": { + "description": "A subset of parameters to be passed to SetupIntent creation for Checkout Sessions in `setup` mode.", + "properties": { + "description": { + "maxLength": 1000, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "on_behalf_of": { "type": "string" + } + }, + "title": "setup_intent_data_param", + "type": "object" + }, + "shipping_address_collection": { + "description": "When set, provides configuration for Checkout to collect a shipping address from a customer.", + "properties": { + "allowed_countries": { + "items": { + "enum": [ + "AC", + "AD", + "AE", + "AF", + "AG", + "AI", + "AL", + "AM", + "AO", + "AQ", + "AR", + "AT", + "AU", + "AW", + "AX", + "AZ", + "BA", + "BB", + "BD", + "BE", + "BF", + "BG", + "BH", + "BI", + "BJ", + "BL", + "BM", + "BN", + "BO", + "BQ", + "BR", + "BS", + "BT", + "BV", + "BW", + "BY", + "BZ", + "CA", + "CD", + "CF", + "CG", + "CH", + "CI", + "CK", + "CL", + "CM", + "CN", + "CO", + "CR", + "CV", + "CW", + "CY", + "CZ", + "DE", + "DJ", + "DK", + "DM", + "DO", + "DZ", + "EC", + "EE", + "EG", + "EH", + "ER", + "ES", + "ET", + "FI", + "FJ", + "FK", + "FO", + "FR", + "GA", + "GB", + "GD", + "GE", + "GF", + "GG", + "GH", + "GI", + "GL", + "GM", + "GN", + "GP", + "GQ", + "GR", + "GS", + "GT", + "GU", + "GW", + "GY", + "HK", + "HN", + "HR", + "HT", + "HU", + "ID", + "IE", + "IL", + "IM", + "IN", + "IO", + "IQ", + "IS", + "IT", + "JE", + "JM", + "JO", + "JP", + "KE", + "KG", + "KH", + "KI", + "KM", + "KN", + "KR", + "KW", + "KY", + "KZ", + "LA", + "LB", + "LC", + "LI", + "LK", + "LR", + "LS", + "LT", + "LU", + "LV", + "LY", + "MA", + "MC", + "MD", + "ME", + "MF", + "MG", + "MK", + "ML", + "MM", + "MN", + "MO", + "MQ", + "MR", + "MS", + "MT", + "MU", + "MV", + "MW", + "MX", + "MY", + "MZ", + "NA", + "NC", + "NE", + "NG", + "NI", + "NL", + "NO", + "NP", + "NR", + "NU", + "NZ", + "OM", + "PA", + "PE", + "PF", + "PG", + "PH", + "PK", + "PL", + "PM", + "PN", + "PR", + "PS", + "PT", + "PY", + "QA", + "RE", + "RO", + "RS", + "RU", + "RW", + "SA", + "SB", + "SC", + "SE", + "SG", + "SH", + "SI", + "SJ", + "SK", + "SL", + "SM", + "SN", + "SO", + "SR", + "SS", + "ST", + "SV", + "SX", + "SZ", + "TA", + "TC", + "TD", + "TF", + "TG", + "TH", + "TJ", + "TK", + "TL", + "TM", + "TN", + "TO", + "TR", + "TT", + "TV", + "TW", + "TZ", + "UA", + "UG", + "US", + "UY", + "UZ", + "VA", + "VC", + "VE", + "VG", + "VN", + "VU", + "WF", + "WS", + "XK", + "YE", + "YT", + "ZA", + "ZM", + "ZW", + "ZZ" + ], + "type": "string" + }, + "type": "array" + } + }, + "required": ["allowed_countries"], + "title": "shipping_address_collection_params", + "type": "object" + }, + "shipping_options": { + "description": "The shipping rate options to apply to this Session. Up to a maximum of 5.", + "items": { + "properties": { + "shipping_rate": { + "maxLength": 5000, + "type": "string" + }, + "shipping_rate_data": { + "properties": { + "delivery_estimate": { + "properties": { + "maximum": { + "properties": { + "unit": { + "enum": [ + "business_day", + "day", + "hour", + "month", + "week" + ], + "type": "string" + }, + "value": { + "type": "integer" + } + }, + "required": ["unit", "value"], + "title": "delivery_estimate_bound", + "type": "object" + }, + "minimum": { + "properties": { + "unit": { + "enum": [ + "business_day", + "day", + "hour", + "month", + "week" + ], + "type": "string" + }, + "value": { + "type": "integer" + } + }, + "required": ["unit", "value"], + "title": "delivery_estimate_bound", + "type": "object" + } + }, + "title": "delivery_estimate", + "type": "object" + }, + "display_name": { + "maxLength": 100, + "type": "string" + }, + "fixed_amount": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + }, + "currency_options": { + "additionalProperties": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + } + }, + "required": ["amount"], + "title": "currency_option", + "type": "object" + }, + "type": "object" + } + }, + "required": ["amount", "currency"], + "title": "fixed_amount", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tax_code": { + "type": "string" + }, + "type": { + "enum": ["fixed_amount"], + "type": "string" + } + }, + "required": ["display_name"], + "title": "method_params", + "type": "object" + } }, - "registration_number": { - "maxLength": 5000, + "title": "shipping_option_params", + "type": "object" + }, + "type": "array" + }, + "submit_type": { + "description": "Describes the type of transaction being performed by Checkout in order to customize\nrelevant text on the page, such as the submit button. `submit_type` can only be\nspecified on Checkout Sessions in `payment` mode. If blank or `auto`, `pay` is used.", + "enum": ["auto", "book", "donate", "pay"], + "type": "string" + }, + "subscription_data": { + "description": "A subset of parameters to be passed to subscription creation for Checkout Sessions in `subscription` mode.", + "properties": { + "application_fee_percent": { + "type": "number" + }, + "billing_cycle_anchor": { + "format": "unix-time", + "type": "integer" + }, + "default_tax_rates": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "description": { + "maxLength": 500, "type": "string" }, - "structure": { - "enum": [ - "", - "government_instrumentality", - "governmental_unit", - "incorporated_non_profit", - "limited_liability_partnership", - "multi_member_llc", - "private_company", - "private_corporation", - "private_partnership", - "public_company", - "public_corporation", - "public_partnership", - "sole_proprietorship", - "tax_exempt_government_instrumentality", - "unincorporated_association", - "unincorporated_non_profit" - ], - "type": "string", - "x-stripeBypassValidation": true + "invoice_settings": { + "properties": { + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings_params", + "type": "object" }, - "tax_id": { - "maxLength": 5000, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "on_behalf_of": { "type": "string" }, - "tax_id_registrar": { - "maxLength": 5000, + "proration_behavior": { + "enum": ["create_prorations", "none"], "type": "string" }, - "vat_id": { - "maxLength": 5000, + "transfer_data": { + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + "trial_end": { + "format": "unix-time", + "type": "integer" + }, + "trial_period_days": { + "type": "integer" + }, + "trial_settings": { + "properties": { + "end_behavior": { + "properties": { + "missing_payment_method": { + "enum": ["cancel", "create_invoice", "pause"], + "type": "string" + } + }, + "required": ["missing_payment_method"], + "title": "end_behavior", + "type": "object" + } + }, + "required": ["end_behavior"], + "title": "trial_settings_config", + "type": "object" + } + }, + "title": "subscription_data_params", + "type": "object" + }, + "success_url": { + "description": "The URL to which Stripe should send customers when payment or setup\nis complete.\nThis parameter is not allowed if ui_mode is `embedded`. If you’d like to use\ninformation from the successful Checkout Session on your page, read the\nguide on [customizing your success page](https://stripe.com/docs/payments/checkout/custom-success-page).", + "maxLength": 5000, + "type": "string" + }, + "tax_id_collection": { + "description": "Controls tax ID collection during checkout.", + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "tax_id_collection_params", + "type": "object" + }, + "ui_mode": { + "description": "The UI mode of the Session. Defaults to `hosted`.", + "enum": ["embedded", "hosted"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/checkout.session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/checkout/sessions/{session}": { + "get": { + "description": "

Retrieves a Session object.

", + "operationId": "GetCheckoutSessionsSession", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "session", + "required": true, + "schema": { + "maxLength": 66, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/checkout.session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates a Session object.

", + "operationId": "PostCheckoutSessionsSession", + "parameters": [ + { + "in": "path", + "name": "session", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/checkout.session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/checkout/sessions/{session}/expire": { + "post": { + "description": "

A Session can be expired when it is in one of these statuses: open

\n\n

After it expires, a customer can’t complete a Session and customers loading the Session see a message saying the Session is expired.

", + "operationId": "PostCheckoutSessionsSessionExpire", + "parameters": [ + { + "in": "path", + "name": "session", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/checkout.session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/checkout/sessions/{session}/line_items": { + "get": { + "description": "

When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", + "operationId": "GetCheckoutSessionsSessionLineItems", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "in": "path", + "name": "session", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PaymentPagesCheckoutSessionListLineItems", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/climate/orders": { + "get": { + "description": "

Lists all Climate order objects. The orders are returned sorted by creation date, with the\nmost recently created orders appearing first.

", + "operationId": "GetClimateOrders", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/climate.order" }, - "verification": { - "properties": { - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "verification_document_specs", - "type": "object" - } - }, - "title": "verification_specs", - "type": "object" - } + "type": "array" }, - "title": "company_specs", - "type": "object" + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/climate/orders", + "type": "string" + } }, - "default_currency": { - "description": "Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://stripe.com/docs/payouts).", - "type": "string" + "required": ["data", "has_more", "object", "url"], + "title": "ClimateRemovalsOrdersList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a Climate order object for a given Climate product. The order will be processed immediately\nafter creation and payment will be deducted your Stripe balance.

", + "operationId": "PostClimateOrders", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "beneficiary": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "Requested amount of carbon removal units. Either this or `metric_tons` must be specified.", + "type": "integer" }, - "documents": { - "description": "Documents that may be submitted to satisfy various informational requests.", + "beneficiary": { + "description": "Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.", "properties": { - "bank_account_ownership_verification": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_license": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_memorandum_of_association": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_ministerial_decree": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_registration_verification": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_tax_id_verification": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" + "public_name": { + "maxLength": 5000, + "type": "string" } }, - "title": "documents_specs", + "required": ["public_name"], + "title": "beneficiary_params", "type": "object" }, - "email": { - "description": "The email address of the account holder. This is only to make the account easier to identify to you. Stripe will never directly email Custom accounts.", + "currency": { + "description": "Request currency for the order as a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a supported [settlement currency for your account](https://stripe.com/docs/currencies). If omitted, the account's default currency will be used.", + "maxLength": 5000, "type": "string" }, "expand": { @@ -24712,244 +64421,178 @@ }, "type": "array" }, - "external_account": { - "description": "A card or bank account to attach to the account for receiving [payouts](https://stripe.com/docs/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://stripe.com/docs/api#account_create_bank_account) creation.

By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the bank account or card creation API.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" }, - "individual": { - "description": "Information about the person represented by the account. This field is null unless `business_type` is set to `individual`.", - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kanji_specs", - "type": "object" - }, - "dob": { - "anyOf": [ - { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" - }, - "year": { - "type": "integer" - } - }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "email": { - "type": "string" - }, - "first_name": { - "maxLength": 100, - "type": "string" - }, - "first_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "gender": { - "type": "string" - }, - "id_number": { - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "maxLength": 100, - "type": "string" - }, - "last_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "last_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "maiden_name": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "phone": { - "type": "string" - }, - "political_exposure": { - "enum": ["existing", "none"], - "type": "string" - }, - "ssn_last_4": { - "maxLength": 5000, - "type": "string" - }, - "verification": { + "metric_tons": { + "description": "Requested number of tons for the order. Either this or `amount` must be specified.", + "format": "decimal", + "type": "string" + }, + "product": { + "description": "Unique identifier of the Climate product.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["product"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/climate.order" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/climate/orders/{order}": { + "get": { + "description": "

Retrieves the details of a Climate order object with the given ID.

", + "operationId": "GetClimateOrdersOrder", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "Unique identifier of the order.", + "in": "path", + "name": "order", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/climate.order" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the specified order by setting the values of the parameters passed.

", + "operationId": "PostClimateOrdersOrder", + "parameters": [ + { + "description": "Unique identifier of the order.", + "in": "path", + "name": "order", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "beneficiary": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "beneficiary": { + "anyOf": [ + { "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { - "properties": { - "back": { - "maxLength": 500, + "public_name": { + "anyOf": [ + { + "maxLength": 5000, "type": "string" }, - "front": { - "maxLength": 500, + { + "enum": [""], "type": "string" } - }, - "title": "person_verification_document_specs", - "type": "object" + ] } }, - "title": "person_verification_specs", - "type": "object" - } - }, - "title": "individual_specs", - "type": "object" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, + "required": ["public_name"], + "title": "beneficiary_params", "type": "object" }, { @@ -24957,155 +64600,21 @@ "type": "string" } ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "description": "Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set." }, - "settings": { - "description": "Options for customizing how the account functions within Stripe.", - "properties": { - "branding": { - "properties": { - "icon": { - "maxLength": 5000, - "type": "string" - }, - "logo": { - "maxLength": 5000, - "type": "string" - }, - "primary_color": { - "maxLength": 5000, - "type": "string" - }, - "secondary_color": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "branding_settings_specs", - "type": "object" - }, - "card_payments": { - "properties": { - "decline_on": { - "properties": { - "avs_failure": { - "type": "boolean" - }, - "cvc_failure": { - "type": "boolean" - } - }, - "title": "decline_charge_on_specs", - "type": "object" - }, - "statement_descriptor_prefix": { - "maxLength": 10, - "type": "string" - } - }, - "title": "card_payments_settings_specs", - "type": "object" - }, - "payments": { - "properties": { - "statement_descriptor": { - "maxLength": 22, - "type": "string" - }, - "statement_descriptor_kana": { - "maxLength": 22, - "type": "string" - }, - "statement_descriptor_kanji": { - "maxLength": 22, - "type": "string" - } - }, - "title": "payments_settings_specs", - "type": "object" - }, - "payouts": { - "properties": { - "debit_negative_balances": { - "type": "boolean" - }, - "schedule": { - "properties": { - "delay_days": { - "anyOf": [ - { - "enum": ["minimum"], - "maxLength": 5000, - "type": "string" - }, - { - "type": "integer" - } - ] - }, - "interval": { - "enum": [ - "daily", - "manual", - "monthly", - "weekly" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "monthly_anchor": { - "type": "integer" - }, - "weekly_anchor": { - "enum": [ - "friday", - "monday", - "saturday", - "sunday", - "thursday", - "tuesday", - "wednesday" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "transfer_schedule_specs", - "type": "object" - }, - "statement_descriptor": { - "maxLength": 22, - "type": "string" - } - }, - "title": "payout_settings_specs", - "type": "object" - } + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "title": "settings_specs", - "type": "object" + "type": "array" }, - "tos_acceptance": { - "description": "Details on the account's acceptance of the [Stripe Services Agreement](https://stripe.com/docs/connect/updating-accounts#tos-acceptance).", - "properties": { - "date": { - "format": "unix-time", - "type": "integer" - }, - "ip": { - "type": "string" - }, - "service_agreement": { - "maxLength": 5000, - "type": "string" - }, - "user_agent": { - "maxLength": 5000, - "type": "string" - } + "metadata": { + "additionalProperties": { + "type": "string" }, - "title": "tos_acceptance_specs", + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" } }, @@ -25120,7 +64629,377 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/climate.order" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/climate/orders/{order}/cancel": { + "post": { + "description": "

Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the\nreservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier\nmight cancel reservations if suppliers fail to deliver. If Frontier cancels the reservation, Stripe\nprovides 90 days advance notice and refunds the amount_total.

", + "operationId": "PostClimateOrdersOrderCancel", + "parameters": [ + { + "description": "Unique identifier of the order.", + "in": "path", + "name": "order", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/climate.order" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/climate/products": { + "get": { + "description": "

Lists all available Climate product objects.

", + "operationId": "GetClimateProducts", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/climate.product" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/climate/products", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ClimateRemovalsProductsList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/climate/products/{product}": { + "get": { + "description": "

Retrieves the details of a Climate product with the given ID.

", + "operationId": "GetClimateProductsProduct", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "product", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/climate.product" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/climate/suppliers": { + "get": { + "description": "

Lists all available Climate supplier objects.

", + "operationId": "GetClimateSuppliers", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/climate.supplier" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/climate/suppliers", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ClimateRemovalsSuppliersList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -25139,100 +65018,44 @@ } } }, - "/v1/account/bank_accounts": { - "post": { - "description": "

Create an external account for a given account.

", - "operationId": "PostAccountBankAccounts", + "/v1/climate/suppliers/{supplier}": { + "get": { + "description": "

Retrieves a Climate supplier object.

", + "operationId": "GetClimateSuppliersSupplier", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "supplier", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "bank_account": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "bank_account": { - "anyOf": [ - { - "properties": { - "account_holder_name": { - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "type": "string" - }, - "object": { - "enum": ["bank_account"], - "maxLength": 5000, - "type": "string" - }, - "routing_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "country"], - "title": "external_account_payout_bank_account", - "type": "object" - }, - { - "maxLength": 5000, - "type": "string" - } - ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." - }, - "default_for_currency": { - "description": "When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.", - "type": "boolean" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "external_account": { - "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -25244,7 +65067,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "$ref": "#/components/schemas/climate.supplier" } } }, @@ -25263,19 +65086,35 @@ } } }, - "/v1/account/bank_accounts/{id}": { - "delete": { - "description": "

Delete a specified external account for a given account.

", - "operationId": "DeleteAccountBankAccountsId", + "/v1/confirmation_tokens/{confirmation_token}": { + "get": { + "description": "

Retrieves an existing ConfirmationToken object

", + "operationId": "GetConfirmationTokensConfirmationToken", "parameters": [ { "in": "path", - "name": "id", + "name": "confirmation_token", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" } ], "requestBody": { @@ -25283,6 +65122,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -25295,7 +65135,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_external_account" + "$ref": "#/components/schemas/confirmation_token" } } }, @@ -25312,11 +65152,24 @@ "description": "Error response." } } - }, + } + }, + "/v1/country_specs": { "get": { - "description": "

Retrieve a specified external account for a given account.

", - "operationId": "GetAccountBankAccountsId", + "description": "

Lists all Country Spec objects available in the API.

", + "operationId": "GetCountrySpecs", "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -25333,13 +65186,25 @@ "style": "deepObject" }, { - "in": "path", - "name": "id", - "required": true, + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, "schema": { + "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" } ], "requestBody": { @@ -25347,6 +65212,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -25359,7 +65225,34 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/country_spec" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/country_specs", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "CountrySpecList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -25376,90 +65269,297 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates the metadata, account holder name, and account holder type of a bank account belonging to a Custom account, and optionally sets it as the default for its currency. Other bank account details are not editable by design.

\n\n

You can re-enable a disabled bank account by performing an update call without providing any arguments or changes.

", - "operationId": "PostAccountBankAccountsId", + } + }, + "/v1/country_specs/{country}": { + "get": { + "description": "

Returns a Country Spec for a given Country code.

", + "operationId": "GetCountrySpecsCountry", "parameters": [ { "in": "path", - "name": "id", + "name": "country", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/country_spec" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/coupons": { + "get": { + "description": "

Returns a list of your coupons.

", + "operationId": "GetCoupons", + "parameters": [ + { + "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" }, - "metadata": { - "explode": true, - "style": "deepObject" + { + "type": "integer" } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, "schema": { - "properties": { - "account_holder_name": { - "description": "The name of the person or business that owns the bank account.", - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "description": "The type of entity that holds the account. This can be either `individual` or `company`.", - "enum": ["", "company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "address_city": { - "description": "City/District/Suburb/Town/Village.", - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "description": "Billing address country, if provided when creating card.", - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "description": "Address line 1 (Street address/PO Box/Company name).", - "maxLength": 5000, - "type": "string" + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/coupon" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/coupons", + "type": "string" + } }, - "address_line2": { - "description": "Address line 2 (Apartment/Suite/Unit/Building).", - "maxLength": 5000, - "type": "string" + "required": ["data", "has_more", "object", "url"], + "title": "CouponsResourceCouponList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

You can create coupons easily via the coupon management page of the Stripe dashboard. Coupon creation is also accessible via the API if you need to create coupons on the fly.

\n\n

A coupon has either a percent_off or an amount_off and currency. If you set an amount_off, that amount will be subtracted from any invoice’s subtotal. For example, an invoice with a subtotal of 100 will have a final total of 0 if a coupon with an amount_off of 200 is applied to it and an invoice with a subtotal of 300 will have a final total of 100 if a coupon with an amount_off of 200 is applied to it.

", + "operationId": "PostCoupons", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "applies_to": { + "explode": true, + "style": "deepObject" + }, + "currency_options": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount_off": { + "description": "A positive integer representing the amount to subtract from an invoice total (required if `percent_off` is not passed).", + "type": "integer" }, - "address_state": { - "description": "State/County/Province/Region.", - "maxLength": 5000, - "type": "string" + "applies_to": { + "description": "A hash containing directions for what this Coupon will apply discounts to.", + "properties": { + "products": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "title": "applies_to_params", + "type": "object" }, - "address_zip": { - "description": "ZIP or postal code.", - "maxLength": 5000, + "currency": { + "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed).", "type": "string" }, - "default_for_currency": { - "description": "When set to true, this becomes the default external account for its currency.", - "type": "boolean" + "currency_options": { + "additionalProperties": { + "properties": { + "amount_off": { + "type": "integer" + } + }, + "required": ["amount_off"], + "title": "currency_option", + "type": "object" + }, + "description": "Coupons defined in each available currency option (only supported if `amount_off` is passed). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).", + "type": "object" }, - "exp_month": { - "description": "Two digit number representing the card’s expiration month.", - "maxLength": 5000, - "type": "string" + "duration": { + "description": "Specifies how long the discount will be in effect if used on a subscription. Defaults to `once`.", + "enum": ["forever", "once", "repeating"], + "type": "string", + "x-stripeBypassValidation": true }, - "exp_year": { - "description": "Four digit number representing the card’s expiration year.", - "maxLength": 5000, - "type": "string" + "duration_in_months": { + "description": "Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect.", + "type": "integer" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -25469,6 +65569,15 @@ }, "type": "array" }, + "id": { + "description": "Unique string of your choice that will be used to identify this coupon when applying it to a customer. If you don't want to specify a particular code, you can leave the ID blank and we'll generate a random code for you.", + "maxLength": 5000, + "type": "string" + }, + "max_redemptions": { + "description": "A positive integer specifying the number of times the coupon can be redeemed before it's no longer valid. For example, you might have a 50% off coupon that the first 20 readers of your blog can use.", + "type": "integer" + }, "metadata": { "anyOf": [ { @@ -25485,9 +65594,18 @@ "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, "name": { - "description": "Cardholder name.", - "maxLength": 5000, + "description": "Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.", + "maxLength": 40, "type": "string" + }, + "percent_off": { + "description": "A positive float larger than 0, and smaller or equal to 100, that represents the discount the coupon will apply (required if `amount_off` is not passed).", + "type": "number" + }, + "redeem_by": { + "description": "Unix timestamp specifying the last time at which the coupon can be redeemed. After the redeem_by date, the coupon can no longer be applied to new customers.", + "format": "unix-time", + "type": "integer" } }, "type": "object" @@ -25501,7 +65619,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "$ref": "#/components/schemas/coupon" } } }, @@ -25520,25 +65638,20 @@ } } }, - "/v1/account/capabilities": { - "get": { - "description": "

Returns a list of capabilities associated with the account. The capabilities are returned sorted by creation date, with the most recent capability appearing first.

", - "operationId": "GetAccountCapabilities", + "/v1/coupons/{coupon}": { + "delete": { + "description": "

You can delete coupons via the coupon management page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can’t redeem the coupon. You can also delete coupons via the API.

", + "operationId": "DeleteCouponsCoupon", "parameters": [ { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, + "in": "path", + "name": "coupon", + "required": true, "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "simple" } ], "requestBody": { @@ -25546,6 +65659,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -25558,33 +65672,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/capability" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "ListAccountCapability", - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/deleted_coupon" } } }, @@ -25601,18 +65689,17 @@ "description": "Error response." } } - } - }, - "/v1/account/capabilities/{capability}": { + }, "get": { - "description": "

Retrieves information about the specified Account Capability.

", - "operationId": "GetAccountCapabilitiesCapability", + "description": "

Retrieves the coupon with the given ID.

", + "operationId": "GetCouponsCoupon", "parameters": [ { "in": "path", - "name": "capability", + "name": "coupon", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" @@ -25638,6 +65725,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -25650,7 +65738,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/capability" + "$ref": "#/components/schemas/coupon" } } }, @@ -25669,14 +65757,15 @@ } }, "post": { - "description": "

Updates an existing Account Capability.

", - "operationId": "PostAccountCapabilitiesCapability", + "description": "

Updates the metadata of a coupon. Other coupon details (currency, duration, amount_off) are, by design, not editable.

", + "operationId": "PostCouponsCoupon", "parameters": [ { "in": "path", - "name": "capability", + "name": "coupon", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" @@ -25686,13 +65775,36 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { + "currency_options": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { + "currency_options": { + "additionalProperties": { + "properties": { + "amount_off": { + "type": "integer" + } + }, + "required": ["amount_off"], + "title": "currency_option", + "type": "object" + }, + "description": "Coupons defined in each available currency option (only supported if the coupon is amount-based). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).", + "type": "object" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -25701,9 +65813,25 @@ }, "type": "array" }, - "requested": { - "description": "Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.", - "type": "boolean" + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "name": { + "description": "Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.", + "maxLength": 40, + "type": "string" } }, "type": "object" @@ -25717,7 +65845,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/capability" + "$ref": "#/components/schemas/coupon" } } }, @@ -25736,17 +65864,62 @@ } } }, - "/v1/account/external_accounts": { + "/v1/credit_notes": { "get": { - "description": "

List external accounts for an account.

", - "operationId": "GetAccountExternalAccounts", + "description": "

Returns a list of credit notes.

", + "operationId": "GetCreditNotes", "parameters": [ + { + "description": "Only return credit notes that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return credit notes for the customer specified by this customer ID.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", "name": "ending_before", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" @@ -25766,6 +65939,17 @@ }, "style": "deepObject" }, + { + "description": "Only return credit notes for the invoice specified by this invoice ID.", + "in": "query", + "name": "invoice", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", @@ -25782,6 +65966,7 @@ "name": "starting_after", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" @@ -25792,6 +65977,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -25807,17 +65993,8 @@ "description": "", "properties": { "data": { - "description": "The list contains all external accounts that have been attached to the Stripe account. These may be bank accounts or cards.", "items": { - "anyOf": [ - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/card" - } - ], - "title": "Polymorphic" + "$ref": "#/components/schemas/credit_note" }, "type": "array" }, @@ -25837,7 +66014,7 @@ } }, "required": ["data", "has_more", "object", "url"], - "title": "ExternalAccountList", + "title": "CreditNotesList", "type": "object", "x-expandableFields": ["data"] } @@ -25858,75 +66035,49 @@ } }, "post": { - "description": "

Create an external account for a given account.

", - "operationId": "PostAccountExternalAccounts", + "description": "

Issue a credit note to adjust the amount of a finalized invoice. For a status=open invoice, a credit note reduces\nits amount_due. For a status=paid invoice, a credit note does not affect its amount_due. Instead, it can result\nin any combination of the following:

\n\n
    \n
  • Refund: create a new refund (using refund_amount) or link an existing refund (using refund).
  • \n
  • Customer balance credit: credit the customer’s balance (using credit_amount) which will be automatically applied to their next invoice when it’s finalized.
  • \n
  • Outside of Stripe credit: record the amount that is or will be credited outside of Stripe (using out_of_band_amount).
  • \n
\n\n

For post-payment credit notes the sum of the refund, credit and outside of Stripe amounts must equal the credit note total.

\n\n

You may issue multiple credit notes for an invoice. Each credit note will increment the invoice’s pre_payment_credit_notes_amount\nor post_payment_credit_notes_amount depending on its status at the time of credit note creation.

", + "operationId": "PostCreditNotes", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "bank_account": { + "expand": { "explode": true, "style": "deepObject" }, - "expand": { + "lines": { "explode": true, "style": "deepObject" }, "metadata": { "explode": true, "style": "deepObject" + }, + "shipping_cost": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "bank_account": { - "anyOf": [ - { - "properties": { - "account_holder_name": { - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "type": "string" - }, - "object": { - "enum": ["bank_account"], - "maxLength": 5000, - "type": "string" - }, - "routing_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "country"], - "title": "external_account_payout_bank_account", - "type": "object" - }, - { - "maxLength": 5000, - "type": "string" - } - ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." + "amount": { + "description": "The integer amount in cents (or local equivalent) representing the total amount of the credit note.", + "type": "integer" }, - "default_for_currency": { - "description": "When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.", - "type": "boolean" + "credit_amount": { + "description": "The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.", + "type": "integer" + }, + "effective_at": { + "description": "The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.", + "format": "unix-time", + "type": "integer" + }, + "email_type": { + "description": "Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.", + "enum": ["credit_note", "none"], + "type": "string" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -25936,11 +66087,98 @@ }, "type": "array" }, - "external_account": { - "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", + "invoice": { + "description": "ID of the invoice.", "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" + }, + "lines": { + "description": "Line items that make up the credit note.", + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "invoice_line_item": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + }, + "tax_amounts": { + "anyOf": [ + { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_rate": { + "maxLength": 5000, + "type": "string" + }, + "taxable_amount": { + "type": "integer" + } + }, + "required": [ + "amount", + "tax_rate", + "taxable_amount" + ], + "title": "tax_amount_with_tax_rate_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": { + "enum": ["custom_line_item", "invoice_line_item"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["type"], + "title": "credit_note_line_item_params", + "type": "object" + }, + "type": "array" + }, + "memo": { + "description": "The credit note's memo appears on the credit note PDF.", + "maxLength": 5000, + "type": "string" }, "metadata": { "additionalProperties": { @@ -25948,71 +66186,54 @@ }, "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" + }, + "out_of_band_amount": { + "description": "The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.", + "type": "integer" + }, + "reason": { + "description": "Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`", + "enum": [ + "duplicate", + "fraudulent", + "order_change", + "product_unsatisfactory" + ], + "type": "string" + }, + "refund": { + "description": "ID of an existing refund to link this credit note to.", + "type": "string" + }, + "refund_amount": { + "description": "The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.", + "type": "integer" + }, + "shipping_cost": { + "description": "When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note.", + "properties": { + "shipping_rate": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "credit_note_shipping_cost", + "type": "object" } }, + "required": ["invoice"], "type": "object" } } }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/external_account" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/account/external_accounts/{id}": { - "delete": { - "description": "

Delete a specified external account for a given account.

", - "operationId": "DeleteAccountExternalAccountsId", - "parameters": [ - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_external_account" + "$ref": "#/components/schemas/credit_note" } } }, @@ -26029,11 +66250,55 @@ "description": "Error response." } } - }, + } + }, + "/v1/credit_notes/preview": { "get": { - "description": "

Retrieve a specified external account for a given account.

", - "operationId": "GetAccountExternalAccountsId", + "description": "

Get a preview of a credit note without creating it.

", + "operationId": "GetCreditNotesPreview", "parameters": [ + { + "description": "The integer amount in cents (or local equivalent) representing the total amount of the credit note.", + "in": "query", + "name": "amount", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.", + "in": "query", + "name": "credit_amount", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.", + "in": "query", + "name": "effective_at", + "required": false, + "schema": { + "format": "unix-time", + "type": "integer" + }, + "style": "form" + }, + { + "description": "Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.", + "in": "query", + "name": "email_type", + "required": false, + "schema": { + "enum": ["credit_note", "none"], + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -26050,13 +66315,190 @@ "style": "deepObject" }, { - "in": "path", - "name": "id", + "description": "ID of the invoice.", + "in": "query", + "name": "invoice", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" + }, + { + "description": "Line items that make up the credit note.", + "explode": true, + "in": "query", + "name": "lines", + "required": false, + "schema": { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "invoice_line_item": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + }, + "tax_amounts": { + "anyOf": [ + { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_rate": { + "maxLength": 5000, + "type": "string" + }, + "taxable_amount": { + "type": "integer" + } + }, + "required": ["amount", "tax_rate", "taxable_amount"], + "title": "tax_amount_with_tax_rate_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": { + "enum": ["custom_line_item", "invoice_line_item"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["type"], + "title": "credit_note_line_item_params", + "type": "object" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "The credit note's memo appears on the credit note PDF.", + "in": "query", + "name": "memo", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "explode": true, + "in": "query", + "name": "metadata", + "required": false, + "schema": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.", + "in": "query", + "name": "out_of_band_amount", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`", + "in": "query", + "name": "reason", + "required": false, + "schema": { + "enum": [ + "duplicate", + "fraudulent", + "order_change", + "product_unsatisfactory" + ], + "type": "string" + }, + "style": "form" + }, + { + "description": "ID of an existing refund to link this credit note to.", + "in": "query", + "name": "refund", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.", + "in": "query", + "name": "refund_amount", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note.", + "explode": true, + "in": "query", + "name": "shipping_cost", + "required": false, + "schema": { + "properties": { + "shipping_rate": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "credit_note_shipping_cost", + "type": "object" + }, + "style": "deepObject" } ], "requestBody": { @@ -26064,6 +66506,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -26076,7 +66519,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "$ref": "#/components/schemas/credit_note" } } }, @@ -26093,254 +66536,335 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates the metadata, account holder name, and account holder type of a bank account belonging to a Custom account, and optionally sets it as the default for its currency. Other bank account details are not editable by design.

\n\n

You can re-enable a disabled bank account by performing an update call without providing any arguments or changes.

", - "operationId": "PostAccountExternalAccountsId", + } + }, + "/v1/credit_notes/preview/lines": { + "get": { + "description": "

When retrieving a credit note preview, you’ll get a lines property containing the first handful of those items. This URL you can retrieve the full (paginated) list of line items.

", + "operationId": "GetCreditNotesPreviewLines", "parameters": [ { - "in": "path", - "name": "id", - "required": true, + "description": "The integer amount in cents (or local equivalent) representing the total amount of the credit note.", + "in": "query", + "name": "amount", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.", + "in": "query", + "name": "credit_amount", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.", + "in": "query", + "name": "effective_at", + "required": false, + "schema": { + "format": "unix-time", + "type": "integer" + }, + "style": "form" + }, + { + "description": "Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.", + "in": "query", + "name": "email_type", + "required": false, "schema": { + "enum": ["credit_note", "none"], "type": "string" }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" }, - "schema": { + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "ID of the invoice.", + "in": "query", + "name": "invoice", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Line items that make up the credit note.", + "explode": true, + "in": "query", + "name": "lines", + "required": false, + "schema": { + "items": { "properties": { - "account_holder_name": { - "description": "The name of the person or business that owns the bank account.", - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "description": "The type of entity that holds the account. This can be either `individual` or `company`.", - "enum": ["", "company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "address_city": { - "description": "City/District/Suburb/Town/Village.", - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "description": "Billing address country, if provided when creating card.", - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "description": "Address line 1 (Street address/PO Box/Company name).", - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "description": "Address line 2 (Apartment/Suite/Unit/Building).", - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "description": "State/County/Province/Region.", - "maxLength": 5000, - "type": "string" + "amount": { + "type": "integer" }, - "address_zip": { - "description": "ZIP or postal code.", + "description": { "maxLength": 5000, "type": "string" }, - "default_for_currency": { - "description": "When set to true, this becomes the default external account for its currency.", - "type": "boolean" - }, - "exp_month": { - "description": "Two digit number representing the card’s expiration month.", + "invoice_line_item": { "maxLength": 5000, "type": "string" }, - "exp_year": { - "description": "Four digit number representing the card’s expiration year.", - "maxLength": 5000, - "type": "string" + "quantity": { + "type": "integer" }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "tax_amounts": { + "anyOf": [ + { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_rate": { + "maxLength": 5000, + "type": "string" + }, + "taxable_amount": { + "type": "integer" + } + }, + "required": ["amount", "tax_rate", "taxable_amount"], + "title": "tax_amount_with_tax_rate_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "metadata": { + "tax_rates": { "anyOf": [ { - "additionalProperties": { + "items": { + "maxLength": 5000, "type": "string" }, - "type": "object" + "type": "array" }, { "enum": [""], "type": "string" } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + ] }, - "name": { - "description": "Cardholder name.", - "maxLength": 5000, + "type": { + "enum": ["custom_line_item", "invoice_line_item"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", "type": "string" } }, + "required": ["type"], + "title": "credit_note_line_item_params", "type": "object" - } - } + }, + "type": "array" + }, + "style": "deepObject" }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/external_account" - } - } + { + "description": "The credit note's memo appears on the credit note PDF.", + "in": "query", + "name": "memo", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" }, - "description": "Successful response." + "style": "form" + }, + { + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "explode": true, + "in": "query", + "name": "metadata", + "required": false, + "schema": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.", + "in": "query", + "name": "out_of_band_amount", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`", + "in": "query", + "name": "reason", + "required": false, + "schema": { + "enum": [ + "duplicate", + "fraudulent", + "order_change", + "product_unsatisfactory" + ], + "type": "string" + }, + "style": "form" + }, + { + "description": "ID of an existing refund to link this credit note to.", + "in": "query", + "name": "refund", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } + { + "description": "The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.", + "in": "query", + "name": "refund_amount", + "required": false, + "schema": { + "type": "integer" }, - "description": "Error response." - } - } - } - }, - "/v1/account/login_links": { - "post": { - "description": "

Creates a single-use login link for an Express account to access their Stripe dashboard.

\n\n

You may only create login links for Express accounts connected to your platform.

", - "operationId": "PostAccountLoginLinks", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "account": { - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "redirect_url": { - "description": "Where to redirect the user after they log out of their dashboard.", - "type": "string" - } - }, - "required": ["account"], - "type": "object" - } - } + "style": "form" }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/login_link" + { + "description": "When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note.", + "explode": true, + "in": "query", + "name": "shipping_cost", + "required": false, + "schema": { + "properties": { + "shipping_rate": { + "maxLength": 5000, + "type": "string" } - } + }, + "title": "credit_note_shipping_cost", + "type": "object" }, - "description": "Successful response." + "style": "deepObject" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" }, - "description": "Error response." + "style": "form" } - } - } - }, - "/v1/account/logout": { - "put": { - "description": "

Invalidates all sessions for a light account, for a platform to use during platform logout.

\n\n

You may only log out Express accounts connected to your platform.

", - "operationId": "PutAccountLogout", + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "account": { - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, - "required": ["account"], + "additionalProperties": false, + "properties": {}, "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/light_account_logout" + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/credit_note_line_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "CreditNoteLinesList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -26359,11 +66883,21 @@ } } }, - "/v1/account/people": { + "/v1/credit_notes/{credit_note}/lines": { "get": { - "description": "

Returns a list of people associated with the account’s legal entity. The people are returned sorted by creation date, with the most recent people appearing first.

", - "operationId": "GetAccountPeople", + "description": "

When retrieving a credit note, you’ll get a lines property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", + "operationId": "GetCreditNotesCreditNoteLines", "parameters": [ + { + "in": "path", + "name": "credit_note", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -26400,32 +66934,6 @@ }, "style": "form" }, - { - "description": "Filters on the list of people returned based on the person's relationship to the account's company.", - "explode": true, - "in": "query", - "name": "relationship", - "required": false, - "schema": { - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "representative": { - "type": "boolean" - } - }, - "title": "all_people_relationship_specs", - "type": "object" - }, - "style": "deepObject" - }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -26443,6 +66951,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -26458,8 +66967,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/credit_note_line_item" }, "type": "array" }, @@ -26479,6 +66989,7 @@ } }, "required": ["data", "has_more", "object", "url"], + "title": "CreditNoteLinesList", "type": "object", "x-expandableFields": ["data"] } @@ -26497,340 +67008,124 @@ "description": "Error response." } } - }, - "post": { - "description": "

Creates a new person.

", - "operationId": "PostAccountPeople", + } + }, + "/v1/credit_notes/{id}": { + "get": { + "description": "

Retrieves the credit note object with the given identifier.

", + "operationId": "GetCreditNotesId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "address": { - "explode": true, - "style": "deepObject" - }, - "address_kana": { - "explode": true, - "style": "deepObject" - }, - "address_kanji": { - "explode": true, - "style": "deepObject" - }, - "dob": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "relationship": { - "explode": true, - "style": "deepObject" - }, - "verification": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "account": { - "maxLength": 5000, - "type": "string" - }, - "address": { - "description": "The person's address.", - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "description": "The Kana variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "description": "The Kanji variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kanji_specs", - "type": "object" - }, - "dob": { - "anyOf": [ - { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" - }, - "year": { - "type": "integer" - } - }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The person's date of birth." - }, - "email": { - "description": "The person's email address.", - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "first_name": { - "description": "The person's first name.", - "maxLength": 5000, - "type": "string" - }, - "first_name_kana": { - "description": "The Kana variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "description": "The Kanji variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "gender": { - "description": "The person's gender (International regulations require either \"male\" or \"female\").", - "type": "string" - }, - "id_number": { - "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://stripe.com/docs/stripe.js#collecting-pii-data).", - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "description": "The person's last name.", - "maxLength": 5000, - "type": "string" - }, - "last_name_kana": { - "description": "The Kana variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "last_name_kanji": { - "description": "The Kanji variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "maiden_name": { - "description": "The person's maiden name.", - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "nationality": { - "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", - "maxLength": 5000, - "type": "string" - }, - "person_token": { - "description": "A [person token](https://stripe.com/docs/connect/account-tokens), used to securely provide details to the person.", - "maxLength": 5000, - "type": "string" - }, - "phone": { - "description": "The person's phone number.", - "type": "string" - }, - "political_exposure": { - "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", - "maxLength": 5000, - "type": "string" - }, - "relationship": { - "description": "The relationship that this person has with the account's legal entity.", - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "percent_ownership": { - "anyOf": [ - { - "type": "number" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "representative": { - "type": "boolean" - }, - "title": { - "maxLength": 5000, - "type": "string" - } + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/credit_note" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates an existing credit note.

", + "operationId": "PostCreditNotesId", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "title": "relationship_specs", - "type": "object" + "type": "array" }, - "ssn_last_4": { - "description": "The last four digits of the person's Social Security number (U.S. only).", + "memo": { + "description": "Credit note memo.", + "maxLength": 5000, "type": "string" }, - "verification": { - "description": "The person's verification status.", - "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - } + "metadata": { + "additionalProperties": { + "type": "string" }, - "title": "person_verification_specs", + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" } }, @@ -26845,7 +67140,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/credit_note" } } }, @@ -26864,14 +67159,14 @@ } } }, - "/v1/account/people/{person}": { - "delete": { - "description": "

Deletes an existing person’s relationship to the account’s legal entity. Any person with a relationship for an account can be deleted through the API, except if the person is the account_opener. If your integration is using the executive parameter, you cannot delete the only verified executive on file.

", - "operationId": "DeleteAccountPeoplePerson", + "/v1/credit_notes/{id}/void": { + "post": { + "description": "

Marks a credit note as void. Learn more about voiding credit notes.

", + "operationId": "PostCreditNotesIdVoid", "parameters": [ { "in": "path", - "name": "person", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -26883,9 +67178,24 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -26897,7 +67207,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_person" + "$ref": "#/components/schemas/credit_note" } } }, @@ -26914,11 +67224,205 @@ "description": "Error response." } } - }, + } + }, + "/v1/customer_sessions": { + "post": { + "description": "

Creates a Customer Session object that includes a single-use client secret that you can use on your front-end to grant client-side API access for certain customer resources.

", + "operationId": "PostCustomerSessions", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "components": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "components": { + "description": "Configuration for each component. Exactly 1 component must be enabled.", + "properties": { + "buy_button": { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "buy_button_param", + "type": "object" + }, + "payment_element": { + "properties": { + "enabled": { + "type": "boolean" + }, + "features": { + "properties": { + "payment_method_allow_redisplay_filters": { + "items": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "type": "array" + }, + "payment_method_redisplay": { + "enum": ["disabled", "enabled"], + "type": "string", + "x-stripeBypassValidation": true + }, + "payment_method_redisplay_limit": { + "type": "integer" + }, + "payment_method_remove": { + "enum": ["disabled", "enabled"], + "type": "string", + "x-stripeBypassValidation": true + }, + "payment_method_save": { + "enum": ["disabled", "enabled"], + "type": "string", + "x-stripeBypassValidation": true + }, + "payment_method_save_usage": { + "enum": ["off_session", "on_session"], + "type": "string" + } + }, + "title": "features_param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "payment_element_param", + "type": "object" + }, + "pricing_table": { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "pricing_table_param", + "type": "object" + } + }, + "title": "components", + "type": "object" + }, + "customer": { + "description": "The ID of an existing customer for which to create the Customer Session.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "required": ["components", "customer"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/customer_session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/customers": { "get": { - "description": "

Retrieves an existing person.

", - "operationId": "GetAccountPeoplePerson", + "description": "

Returns a list of your customers. The customers are returned sorted by creation date, with the most recent customers appearing first.

", + "operationId": "GetCustomers", "parameters": [ + { + "description": "Only return customers that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A case-sensitive filter on the list based on the customer's `email` field. The value must be a string.", + "in": "query", + "name": "email", + "required": false, + "schema": { + "maxLength": 512, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -26935,14 +67439,36 @@ "style": "deepObject" }, { - "in": "path", - "name": "person", - "required": true, + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" + }, + { + "description": "Provides a list of customers that are associated with the specified test clock. The response will not include customers with test clocks if this parameter is not set.", + "in": "query", + "name": "test_clock", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" } ], "requestBody": { @@ -26950,6 +67476,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -26962,7 +67489,34 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/customer" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/customers", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "CustomerResourceCustomerList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -26981,20 +67535,8 @@ } }, "post": { - "description": "

Updates an existing person.

", - "operationId": "PostAccountPeoplePerson", - "parameters": [ - { - "in": "path", - "name": "person", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], + "description": "

Creates a new customer object.

", + "operationId": "PostCustomers", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -27003,158 +67545,72 @@ "explode": true, "style": "deepObject" }, - "address_kana": { + "cash_balance": { "explode": true, "style": "deepObject" }, - "address_kanji": { + "expand": { "explode": true, "style": "deepObject" }, - "dob": { + "invoice_settings": { "explode": true, "style": "deepObject" }, - "expand": { + "metadata": { "explode": true, "style": "deepObject" }, - "metadata": { + "preferred_locales": { "explode": true, "style": "deepObject" }, - "relationship": { + "shipping": { "explode": true, "style": "deepObject" }, - "verification": { + "tax": { + "explode": true, + "style": "deepObject" + }, + "tax_id_data": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "account": { - "maxLength": 5000, - "type": "string" - }, "address": { - "description": "The person's address.", - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "description": "The Kana variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "description": "The Kanji variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kanji_specs", - "type": "object" - }, - "dob": { "anyOf": [ { "properties": { - "day": { - "type": "integer" + "city": { + "maxLength": 5000, + "type": "string" }, - "month": { - "type": "integer" + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" }, - "year": { - "type": "integer" + "state": { + "maxLength": 5000, + "type": "string" } }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", + "title": "optional_fields_address", "type": "object" }, { @@ -27162,63 +67618,118 @@ "type": "string" } ], - "description": "The person's date of birth." + "description": "The customer's address." }, - "email": { - "description": "The person's email address.", - "type": "string" + "balance": { + "description": "An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.", + "type": "integer" }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" + "cash_balance": { + "description": "Balance information and default balance settings for this customer.", + "properties": { + "settings": { + "properties": { + "reconciliation_mode": { + "enum": ["automatic", "manual", "merchant_default"], + "type": "string" + } + }, + "title": "balance_settings_param", + "type": "object" + } }, - "type": "array" - }, - "first_name": { - "description": "The person's first name.", - "maxLength": 5000, - "type": "string" - }, - "first_name_kana": { - "description": "The Kana variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" + "title": "cash_balance_param", + "type": "object" }, - "first_name_kanji": { - "description": "The Kanji variation of the person's first name (Japan only).", + "coupon": { "maxLength": 5000, "type": "string" }, - "gender": { - "description": "The person's gender (International regulations require either \"male\" or \"female\").", - "type": "string" - }, - "id_number": { - "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://stripe.com/docs/stripe.js#collecting-pii-data).", + "description": { + "description": "An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.", "maxLength": 5000, "type": "string" }, - "last_name": { - "description": "The person's last name.", - "maxLength": 5000, + "email": { + "description": "Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.", + "maxLength": 512, "type": "string" }, - "last_name_kana": { - "description": "The Kana variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "last_name_kanji": { - "description": "The Kanji variation of the person's last name (Japan only).", + "invoice_prefix": { + "description": "The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.", "maxLength": 5000, "type": "string" }, - "maiden_name": { - "description": "The person's maiden name.", - "maxLength": 5000, - "type": "string" + "invoice_settings": { + "description": "Default invoice settings for this customer.", + "properties": { + "custom_fields": { + "anyOf": [ + { + "items": { + "properties": { + "name": { + "maxLength": 40, + "type": "string" + }, + "value": { + "maxLength": 140, + "type": "string" + } + }, + "required": ["name", "value"], + "title": "custom_field_params", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "default_payment_method": { + "maxLength": 5000, + "type": "string" + }, + "footer": { + "maxLength": 5000, + "type": "string" + }, + "rendering_options": { + "anyOf": [ + { + "properties": { + "amount_tax_display": { + "enum": [ + "", + "exclude_tax", + "include_inclusive_tax" + ], + "type": "string" + } + }, + "title": "customer_rendering_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "customer_param", + "type": "object" }, "metadata": { "anyOf": [ @@ -27235,41 +67746,103 @@ ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "nationality": { - "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", - "maxLength": 5000, + "name": { + "description": "The customer's full name or business name.", + "maxLength": 256, "type": "string" }, - "person_token": { - "description": "A [person token](https://stripe.com/docs/connect/account-tokens), used to securely provide details to the person.", + "next_invoice_sequence": { + "description": "The sequence to be used on the customer's next invoice. Defaults to 1.", + "type": "integer" + }, + "payment_method": { "maxLength": 5000, "type": "string" }, "phone": { - "description": "The person's phone number.", + "description": "The customer's phone number.", + "maxLength": 20, "type": "string" }, - "political_exposure": { - "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", + "preferred_locales": { + "description": "Customer's preferred languages, ordered by preference.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "promotion_code": { + "description": "The ID of a promotion code to apply to the customer. The customer will have a discount applied on all recurring payments. Charges you create through the API will not have the discount.", "maxLength": 5000, "type": "string" }, - "relationship": { - "description": "The relationship that this person has with the account's legal entity.", - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" + "shipping": { + "anyOf": [ + { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["address", "name"], + "title": "customer_shipping", + "type": "object" }, - "percent_ownership": { + { + "enum": [""], + "type": "string" + } + ], + "description": "The customer's shipping information. Appears on invoices emailed to this customer." + }, + "source": { + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "tax": { + "description": "Tax details about the customer.", + "properties": { + "ip_address": { "anyOf": [ { - "type": "number" + "type": "string" }, { "enum": [""], @@ -27277,55 +67850,118 @@ } ] }, - "representative": { - "type": "boolean" - }, - "title": { - "maxLength": 5000, + "validate_location": { + "enum": ["deferred", "immediately"], "type": "string" } }, - "title": "relationship_specs", + "title": "tax_param", "type": "object" }, - "ssn_last_4": { - "description": "The last four digits of the person's Social Security number (U.S. only).", + "tax_exempt": { + "description": "The customer's tax exemption. One of `none`, `exempt`, or `reverse`.", + "enum": ["", "exempt", "none", "reverse"], "type": "string" }, - "verification": { - "description": "The person's verification status.", - "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } + "tax_id_data": { + "description": "The customer's tax IDs.", + "items": { + "properties": { + "type": { + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true }, - "title": "person_verification_document_specs", - "type": "object" + "value": { + "type": "string" + } }, - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - } + "required": ["type", "value"], + "title": "data_params", + "type": "object" }, - "title": "person_verification_specs", - "type": "object" + "type": "array" + }, + "test_clock": { + "description": "ID of the test clock to attach to the customer.", + "maxLength": 5000, + "type": "string" } }, "type": "object" @@ -27339,7 +67975,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/customer" } } }, @@ -27358,22 +67994,11 @@ } } }, - "/v1/account/persons": { + "/v1/customers/search": { "get": { - "description": "

Returns a list of people associated with the account’s legal entity. The people are returned sorted by creation date, with the most recent people appearing first.

", - "operationId": "GetAccountPersons", + "description": "

Search for customers you’ve previously created using Stripe’s Search Query Language.\nDon’t use search in read-after-write flows where strict consistency is necessary. Under normal operating\nconditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up\nto an hour behind during outages. Search functionality is not available to merchants in India.

", + "operationId": "GetCustomersSearch", "parameters": [ - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -27400,36 +68025,21 @@ "style": "form" }, { - "description": "Filters on the list of people returned based on the person's relationship to the account's company.", - "explode": true, + "description": "A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.", "in": "query", - "name": "relationship", + "name": "page", "required": false, "schema": { - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "representative": { - "type": "boolean" - } - }, - "title": "all_people_relationship_specs", - "type": "object" + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "form" }, { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for customers](https://stripe.com/docs/search#query-fields-for-customers).", "in": "query", - "name": "starting_after", - "required": false, + "name": "query", + "required": true, "schema": { "maxLength": 5000, "type": "string" @@ -27442,6 +68052,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -27458,26 +68069,34 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/customer" }, "type": "array" }, "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", "type": "boolean" }, + "next_page": { + "maxLength": 5000, + "nullable": true, + "type": "string" + }, "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["search_result"], "type": "string" }, + "total_count": { + "description": "The total number of objects that match the query, only accurate up to 10,000.", + "type": "integer" + }, "url": { - "description": "The URL where this list can be accessed.", "maxLength": 5000, "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "SearchResult", "type": "object", "x-expandableFields": ["data"] } @@ -27493,13 +68112,151 @@ } } }, - "description": "Error response." + "description": "Error response." + } + } + } + }, + "/v1/customers/{customer}": { + "delete": { + "description": "

Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.

", + "operationId": "DeleteCustomersCustomer", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_customer" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves a Customer object.

", + "operationId": "GetCustomersCustomer", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "$ref": "#/components/schemas/customer" + }, + { + "$ref": "#/components/schemas/deleted_customer" + } + ] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the specified customer by setting the values of the parameters passed. Any parameters not provided will be left unchanged. For example, if you pass the source parameter, that becomes the customer’s active source (e.g., a card) to be used for all charges in the future. When you update a customer to a new valid card source by passing the source parameter: for each of the customer’s current subscriptions, if the subscription bills automatically and is in the past_due state, then the latest open invoice for the subscription with automatic collection enabled will be retried. This retry will not count as an automatic retry, and will not affect the next regularly scheduled payment for the invoice. Changing the default_source for a customer will not trigger this behavior.

\n\n

This request accepts mostly the same arguments as the customer creation call.

", + "operationId": "PostCustomersCustomer", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" } - } - }, - "post": { - "description": "

Creates a new person.

", - "operationId": "PostAccountPersons", + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -27508,15 +68265,15 @@ "explode": true, "style": "deepObject" }, - "address_kana": { + "bank_account": { "explode": true, "style": "deepObject" }, - "address_kanji": { + "card": { "explode": true, "style": "deepObject" }, - "dob": { + "cash_balance": { "explode": true, "style": "deepObject" }, @@ -27524,207 +68281,315 @@ "explode": true, "style": "deepObject" }, + "invoice_settings": { + "explode": true, + "style": "deepObject" + }, "metadata": { "explode": true, "style": "deepObject" }, - "relationship": { + "preferred_locales": { "explode": true, "style": "deepObject" }, - "verification": { + "shipping": { + "explode": true, + "style": "deepObject" + }, + "tax": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "account": { - "maxLength": 5000, - "type": "string" - }, "address": { - "description": "The person's address.", - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" }, - "state": { - "maxLength": 5000, + { + "enum": [""], "type": "string" } - }, - "title": "address_specs", - "type": "object" + ], + "description": "The customer's address." }, - "address_kana": { - "description": "The Kana variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" + "balance": { + "description": "An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.", + "type": "integer" }, - "address_kanji": { - "description": "The Kanji variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" + "bank_account": { + "anyOf": [ + { + "properties": { + "account_holder_name": { + "maxLength": 5000, + "type": "string" + }, + "account_holder_type": { + "enum": ["company", "individual"], + "maxLength": 5000, + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "currency": { + "type": "string" + }, + "object": { + "enum": ["bank_account"], + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "country"], + "title": "customer_payment_source_bank_account", + "type": "object" }, - "town": { + { "maxLength": 5000, "type": "string" } - }, - "title": "japan_address_kanji_specs", - "type": "object" + ], + "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/js), or a dictionary containing a user's bank account details." }, - "dob": { + "card": { "anyOf": [ { "properties": { - "day": { - "type": "integer" + "address_city": { + "maxLength": 5000, + "type": "string" }, - "month": { + "address_country": { + "maxLength": 5000, + "type": "string" + }, + "address_line1": { + "maxLength": 5000, + "type": "string" + }, + "address_line2": { + "maxLength": 5000, + "type": "string" + }, + "address_state": { + "maxLength": 5000, + "type": "string" + }, + "address_zip": { + "maxLength": 5000, + "type": "string" + }, + "cvc": { + "maxLength": 5000, + "type": "string" + }, + "exp_month": { "type": "integer" }, - "year": { + "exp_year": { "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "number": { + "maxLength": 5000, + "type": "string" + }, + "object": { + "enum": ["card"], + "maxLength": 5000, + "type": "string" } }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", + "required": ["exp_month", "exp_year", "number"], + "title": "customer_payment_source_card", "type": "object" }, { - "enum": [""], + "maxLength": 5000, "type": "string" } ], - "description": "The person's date of birth." - }, - "email": { - "description": "The person's email address.", - "type": "string" + "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js).", + "x-stripeBypassValidation": true }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" + "cash_balance": { + "description": "Balance information and default balance settings for this customer.", + "properties": { + "settings": { + "properties": { + "reconciliation_mode": { + "enum": ["automatic", "manual", "merchant_default"], + "type": "string" + } + }, + "title": "balance_settings_param", + "type": "object" + } }, - "type": "array" + "title": "cash_balance_param", + "type": "object" }, - "first_name": { - "description": "The person's first name.", + "coupon": { "maxLength": 5000, "type": "string" }, - "first_name_kana": { - "description": "The Kana variation of the person's first name (Japan only).", - "maxLength": 5000, + "default_alipay_account": { + "description": "ID of Alipay account to make the customer's new default for invoice payments.", + "maxLength": 500, "type": "string" }, - "first_name_kanji": { - "description": "The Kanji variation of the person's first name (Japan only).", - "maxLength": 5000, + "default_bank_account": { + "description": "ID of bank account to make the customer's new default for invoice payments.", + "maxLength": 500, "type": "string" }, - "gender": { - "description": "The person's gender (International regulations require either \"male\" or \"female\").", + "default_card": { + "description": "ID of card to make the customer's new default for invoice payments.", + "maxLength": 500, "type": "string" }, - "id_number": { - "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://stripe.com/docs/stripe.js#collecting-pii-data).", - "maxLength": 5000, + "default_source": { + "description": "If you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method) parameter.\n\nProvide the ID of a payment source already attached to this customer to make it this customer's default payment source.\n\nIf you want to add a new payment source and make it the default, see the [source](https://stripe.com/docs/api/customers/update#update_customer-source) property.", + "maxLength": 500, "type": "string" }, - "last_name": { - "description": "The person's last name.", + "description": { + "description": "An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.", "maxLength": 5000, "type": "string" }, - "last_name_kana": { - "description": "The Kana variation of the person's last name (Japan only).", - "maxLength": 5000, + "email": { + "description": "Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.", + "maxLength": 512, "type": "string" }, - "last_name_kanji": { - "description": "The Kanji variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "maiden_name": { - "description": "The person's maiden name.", + "invoice_prefix": { + "description": "The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.", "maxLength": 5000, "type": "string" }, + "invoice_settings": { + "description": "Default invoice settings for this customer.", + "properties": { + "custom_fields": { + "anyOf": [ + { + "items": { + "properties": { + "name": { + "maxLength": 40, + "type": "string" + }, + "value": { + "maxLength": 140, + "type": "string" + } + }, + "required": ["name", "value"], + "title": "custom_field_params", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "default_payment_method": { + "maxLength": 5000, + "type": "string" + }, + "footer": { + "maxLength": 5000, + "type": "string" + }, + "rendering_options": { + "anyOf": [ + { + "properties": { + "amount_tax_display": { + "enum": [ + "", + "exclude_tax", + "include_inclusive_tax" + ], + "type": "string" + } + }, + "title": "customer_rendering_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "customer_param", + "type": "object" + }, "metadata": { "anyOf": [ { @@ -27740,97 +68605,118 @@ ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "nationality": { - "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", - "maxLength": 5000, + "name": { + "description": "The customer's full name or business name.", + "maxLength": 256, "type": "string" }, - "person_token": { - "description": "A [person token](https://stripe.com/docs/connect/account-tokens), used to securely provide details to the person.", - "maxLength": 5000, - "type": "string" + "next_invoice_sequence": { + "description": "The sequence to be used on the customer's next invoice. Defaults to 1.", + "type": "integer" }, "phone": { - "description": "The person's phone number.", - "type": "string" - }, - "political_exposure": { - "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", - "maxLength": 5000, + "description": "The customer's phone number.", + "maxLength": 20, "type": "string" }, - "relationship": { - "description": "The relationship that this person has with the account's legal entity.", - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "percent_ownership": { - "anyOf": [ - { - "type": "number" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "representative": { - "type": "boolean" - }, - "title": { - "maxLength": 5000, - "type": "string" - } + "preferred_locales": { + "description": "Customer's preferred languages, ordered by preference.", + "items": { + "maxLength": 5000, + "type": "string" }, - "title": "relationship_specs", - "type": "object" + "type": "array" }, - "ssn_last_4": { - "description": "The last four digits of the person's Social Security number (U.S. only).", + "promotion_code": { + "description": "The ID of a promotion code to apply to the customer. The customer will have a discount applied on all recurring payments. Charges you create through the API will not have the discount.", + "maxLength": 5000, "type": "string" }, - "verification": { - "description": "The person's verification status.", - "properties": { - "additional_document": { + "shipping": { + "anyOf": [ + { "properties": { - "back": { - "maxLength": 500, + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "name": { + "maxLength": 5000, "type": "string" }, - "front": { - "maxLength": 500, + "phone": { + "maxLength": 5000, "type": "string" } }, - "title": "person_verification_document_specs", + "required": ["address", "name"], + "title": "customer_shipping", "type": "object" }, - "document": { - "properties": { - "back": { - "maxLength": 500, + { + "enum": [""], + "type": "string" + } + ], + "description": "The customer's shipping information. Appears on invoices emailed to this customer." + }, + "source": { + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "tax": { + "description": "Tax details about the customer.", + "properties": { + "ip_address": { + "anyOf": [ + { "type": "string" }, - "front": { - "maxLength": 500, + { + "enum": [""], "type": "string" } - }, - "title": "person_verification_document_specs", - "type": "object" + ] + }, + "validate_location": { + "enum": ["deferred", "immediately"], + "type": "string" } }, - "title": "person_verification_specs", + "title": "tax_param", "type": "object" + }, + "tax_exempt": { + "description": "The customer's tax exemption. One of `none`, `exempt`, or `reverse`.", + "enum": ["", "exempt", "none", "reverse"], + "type": "string" } }, "type": "object" @@ -27844,7 +68730,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/customer" } } }, @@ -27863,61 +68749,32 @@ } } }, - "/v1/account/persons/{person}": { - "delete": { - "description": "

Deletes an existing person’s relationship to the account’s legal entity. Any person with a relationship for an account can be deleted through the API, except if the person is the account_opener. If your integration is using the executive parameter, you cannot delete the only verified executive on file.

", - "operationId": "DeleteAccountPersonsPerson", + "/v1/customers/{customer}/balance_transactions": { + "get": { + "description": "

Returns a list of transactions that updated the customer’s balances.

", + "operationId": "GetCustomersCustomerBalanceTransactions", "parameters": [ { "in": "path", - "name": "person", + "name": "customer", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/deleted_person" - } - } + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" }, - "description": "Successful response." + "style": "form" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "get": { - "description": "

Retrieves an existing person.

", - "operationId": "GetAccountPersonsPerson", - "parameters": [ { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -27934,14 +68791,25 @@ "style": "deepObject" }, { - "in": "path", - "name": "person", - "required": true, + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" } ], "requestBody": { @@ -27949,6 +68817,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -27961,7 +68830,34 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/customer_balance_transaction" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "CustomerBalanceTransactionList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -27980,12 +68876,12 @@ } }, "post": { - "description": "

Updates an existing person.

", - "operationId": "PostAccountPersonsPerson", + "description": "

Creates an immutable transaction that updates the customer’s credit balance.

", + "operationId": "PostCustomersCustomerBalanceTransactions", "parameters": [ { "in": "path", - "name": "person", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -27998,22 +68894,6 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "address": { - "explode": true, - "style": "deepObject" - }, - "address_kana": { - "explode": true, - "style": "deepObject" - }, - "address_kanji": { - "explode": true, - "style": "deepObject" - }, - "dob": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" @@ -28021,150 +68901,22 @@ "metadata": { "explode": true, "style": "deepObject" - }, - "relationship": { - "explode": true, - "style": "deepObject" - }, - "verification": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "account": { - "maxLength": 5000, - "type": "string" - }, - "address": { - "description": "The person's address.", - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "description": "The Kana variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "description": "The Kanji variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kanji_specs", - "type": "object" + "amount": { + "description": "The integer amount in **cents (or local equivalent)** to apply to the customer's credit balance.", + "type": "integer" }, - "dob": { - "anyOf": [ - { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" - }, - "year": { - "type": "integer" - } - }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The person's date of birth." + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Specifies the [`invoice_credit_balance`](https://stripe.com/docs/api/customers/object#customer_object-invoice_credit_balance) that this transaction will apply to. If the customer's `currency` is not set, it will be updated to this value.", + "type": "string" }, - "email": { - "description": "The person's email address.", + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 350, "type": "string" }, "expand": { @@ -28175,50 +68927,6 @@ }, "type": "array" }, - "first_name": { - "description": "The person's first name.", - "maxLength": 5000, - "type": "string" - }, - "first_name_kana": { - "description": "The Kana variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "description": "The Kanji variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "gender": { - "description": "The person's gender (International regulations require either \"male\" or \"female\").", - "type": "string" - }, - "id_number": { - "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://stripe.com/docs/stripe.js#collecting-pii-data).", - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "description": "The person's last name.", - "maxLength": 5000, - "type": "string" - }, - "last_name_kana": { - "description": "The Kana variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "last_name_kanji": { - "description": "The Kanji variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "maiden_name": { - "description": "The person's maiden name.", - "maxLength": 5000, - "type": "string" - }, "metadata": { "anyOf": [ { @@ -28233,100 +68941,86 @@ } ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "nationality": { - "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", - "maxLength": 5000, - "type": "string" - }, - "person_token": { - "description": "A [person token](https://stripe.com/docs/connect/account-tokens), used to securely provide details to the person.", - "maxLength": 5000, - "type": "string" - }, - "phone": { - "description": "The person's phone number.", - "type": "string" - }, - "political_exposure": { - "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", - "maxLength": 5000, - "type": "string" - }, - "relationship": { - "description": "The relationship that this person has with the account's legal entity.", - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "percent_ownership": { - "anyOf": [ - { - "type": "number" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "representative": { - "type": "boolean" - }, - "title": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "relationship_specs", - "type": "object" - }, - "ssn_last_4": { - "description": "The last four digits of the person's Social Security number (U.S. only).", - "type": "string" - }, - "verification": { - "description": "The person's verification status.", - "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - } - }, - "title": "person_verification_specs", - "type": "object" } }, + "required": ["amount", "currency"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/customer_balance_transaction" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/customers/{customer}/balance_transactions/{transaction}": { + "get": { + "description": "

Retrieves a specific customer balance transaction that updated the customer’s balances.

", + "operationId": "GetCustomersCustomerBalanceTransactionsTransaction", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "transaction", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -28338,7 +69032,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/customer_balance_transaction" } } }, @@ -28352,15 +69046,35 @@ } } }, - "description": "Error response." + "description": "Error response." + } + } + }, + "post": { + "description": "

Most credit balance transaction fields are immutable, but you may update its description and metadata.

", + "operationId": "PostCustomersCustomerBalanceTransactionsTransaction", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "transaction", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" } - } - } - }, - "/v1/account_links": { - "post": { - "description": "

Creates an AccountLink object that includes a single-use Stripe URL that the platform can redirect their user to in order to take them through the Connect Onboarding flow.

", - "operationId": "PostAccountLinks", + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -28368,18 +69082,18 @@ "expand": { "explode": true, "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "account": { - "description": "The identifier of the account to create an account link for.", - "maxLength": 5000, - "type": "string" - }, - "collect": { - "description": "Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`.", - "enum": ["currently_due", "eventually_due"], + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 350, "type": "string" }, "expand": { @@ -28390,34 +69104,34 @@ }, "type": "array" }, - "refresh_url": { - "description": "The URL the user will be redirected to if the account link is expired, has been previously-visited, or is otherwise invalid. The URL you specify should attempt to generate a new account link with the same parameters used to create the original account link, then redirect the user to the new account link's URL so they can continue with Connect Onboarding. If a new account link cannot be generated or the redirect fails you should display a useful error to the user.", - "type": "string" - }, - "return_url": { - "description": "The URL that the user will be redirected to upon leaving or completing the linked flow.", - "type": "string" - }, - "type": { - "description": "The type of account link the user is requesting. Possible values are `account_onboarding` or `account_update`.", - "enum": ["account_onboarding", "account_update"], - "type": "string", - "x-stripeBypassValidation": true + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." } }, - "required": ["account", "type"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/account_link" + "$ref": "#/components/schemas/customer_balance_transaction" } } }, @@ -28436,42 +69150,21 @@ } } }, - "/v1/accounts": { + "/v1/customers/{customer}/bank_accounts": { "get": { - "description": "

Returns a list of accounts connected to your platform via Connect. If you’re not a platform, the list is empty.

", - "operationId": "GetAccounts", + "deprecated": true, + "description": "

You can see a list of the bank accounts belonging to a Customer. Note that the 10 most recent sources are always available by default on the Customer. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional bank accounts.

", + "operationId": "GetCustomersCustomerBankAccounts", "parameters": [ { - "explode": true, - "in": "query", - "name": "created", - "required": false, + "in": "path", + "name": "customer", + "required": true, "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "simple" }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", @@ -28524,716 +69217,528 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/account" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/accounts", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

With Connect, you can create Stripe accounts for your users.\nTo do this, you’ll first need to register your platform.

", - "operationId": "PostAccounts", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "bank_account": { - "explode": true, - "style": "deepObject" - }, - "business_profile": { - "explode": true, - "style": "deepObject" - }, - "capabilities": { - "explode": true, - "style": "deepObject" - }, - "company": { - "explode": true, - "style": "deepObject" - }, - "documents": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "individual": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "settings": { - "explode": true, - "style": "deepObject" - }, - "tos_acceptance": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "account_token": { - "description": "An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.", - "maxLength": 5000, - "type": "string" - }, - "bank_account": { - "anyOf": [ - { - "properties": { - "account_holder_name": { - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "type": "string" - }, - "object": { - "enum": ["bank_account"], - "maxLength": 5000, - "type": "string" - }, - "routing_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "country"], - "title": "external_account_payout_bank_account", - "type": "object" - }, - { - "maxLength": 5000, - "type": "string" - } - ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." - }, - "business_profile": { - "description": "Business information about the account.", - "properties": { - "mcc": { - "maxLength": 4, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "product_description": { - "maxLength": 40000, - "type": "string" - }, - "support_address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "support_email": { - "type": "string" - }, - "support_phone": { - "maxLength": 5000, - "type": "string" - }, - "support_url": { - "type": "string" - }, - "url": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "business_profile_specs", - "type": "object" - }, - "business_type": { - "description": "The business type.", - "enum": [ - "company", - "government_entity", - "individual", - "non_profit" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "capabilities": { - "description": "Each key of the dictionary represents a capability, and each capability maps to its settings (e.g. whether it has been requested or not). Each capability will be inactive until you have provided its specific requirements and Stripe has verified them. An account may have some of its requested capabilities be active and some be inactive.", - "properties": { - "afterpay_clearpay_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "au_becs_debit_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "bacs_debit_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "bancontact_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "card_issuing": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "card_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "cartes_bancaires_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "eps_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "fpx_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "giropay_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "grabpay_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "ideal_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "jcb_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "legacy_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "oxxo_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "p24_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "sepa_debit_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "sofort_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "tax_reporting_us_1099_k": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "tax_reporting_us_1099_misc": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/bank_account" }, - "transfers": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - } + "type": "array" }, - "title": "capabilities_param", - "type": "object" + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } }, - "company": { - "description": "Information about the company or business. This field is available for any `business_type`.", - "properties": { - "address": { + "required": ["data", "has_more", "object", "url"], + "title": "BankAccountList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

When you create a new credit card, you must specify a customer or recipient on which to create it.

\n\n

If the card’s owner has no default card, then the new card will become the default.\nHowever, if the owner already has a default, then it will not change.\nTo change the default, you should update the customer to have a new default_source.

", + "operationId": "PostCustomersCustomerBankAccounts", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "bank_account": { + "explode": true, + "style": "deepObject" + }, + "card": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "alipay_account": { + "description": "A token returned by [Stripe.js](https://stripe.com/docs/js) representing the user’s Alipay account details.", + "maxLength": 5000, + "type": "string" + }, + "bank_account": { + "anyOf": [ + { "properties": { - "city": { - "maxLength": 100, + "account_holder_name": { + "maxLength": 5000, "type": "string" }, - "country": { + "account_holder_type": { + "enum": ["company", "individual"], "maxLength": 5000, "type": "string" }, - "line1": { - "maxLength": 200, + "account_number": { + "maxLength": 5000, "type": "string" }, - "line2": { - "maxLength": 200, + "country": { + "maxLength": 5000, "type": "string" }, - "postal_code": { + "currency": { + "type": "string" + }, + "object": { + "enum": ["bank_account"], "maxLength": 5000, "type": "string" }, - "state": { + "routing_number": { "maxLength": 5000, "type": "string" } }, - "title": "address_specs", + "required": ["account_number", "country"], + "title": "customer_payment_source_bank_account", "type": "object" }, - "address_kana": { + { + "maxLength": 5000, + "type": "string" + } + ], + "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/js), or a dictionary containing a user's bank account details." + }, + "card": { + "anyOf": [ + { "properties": { - "city": { + "address_city": { "maxLength": 5000, "type": "string" }, - "country": { + "address_country": { "maxLength": 5000, "type": "string" }, - "line1": { + "address_line1": { "maxLength": 5000, "type": "string" }, - "line2": { + "address_line2": { "maxLength": 5000, "type": "string" }, - "postal_code": { + "address_state": { "maxLength": 5000, "type": "string" }, - "state": { + "address_zip": { "maxLength": 5000, "type": "string" }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "properties": { - "city": { + "cvc": { "maxLength": 5000, "type": "string" }, - "country": { - "maxLength": 5000, - "type": "string" + "exp_month": { + "type": "integer" }, - "line1": { - "maxLength": 5000, - "type": "string" + "exp_year": { + "type": "integer" }, - "line2": { - "maxLength": 5000, - "type": "string" + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" }, - "postal_code": { + "name": { "maxLength": 5000, "type": "string" }, - "state": { + "number": { "maxLength": 5000, "type": "string" }, - "town": { + "object": { + "enum": ["card"], "maxLength": 5000, "type": "string" } }, - "title": "japan_address_kanji_specs", + "required": ["exp_month", "exp_year", "number"], + "title": "customer_payment_source_card", "type": "object" }, - "directors_provided": { - "type": "boolean" - }, - "executives_provided": { - "type": "boolean" - }, - "name": { - "maxLength": 100, - "type": "string" - }, - "name_kana": { - "maxLength": 100, - "type": "string" - }, - "name_kanji": { - "maxLength": 100, - "type": "string" - }, - "owners_provided": { - "type": "boolean" - }, - "phone": { - "maxLength": 5000, - "type": "string" - }, - "registration_number": { - "maxLength": 5000, - "type": "string" - }, - "structure": { - "enum": [ - "", - "government_instrumentality", - "governmental_unit", - "incorporated_non_profit", - "limited_liability_partnership", - "multi_member_llc", - "private_company", - "private_corporation", - "private_partnership", - "public_company", - "public_corporation", - "public_partnership", - "sole_proprietorship", - "tax_exempt_government_instrumentality", - "unincorporated_association", - "unincorporated_non_profit" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "tax_id": { - "maxLength": 5000, - "type": "string" - }, - "tax_id_registrar": { - "maxLength": 5000, - "type": "string" - }, - "vat_id": { + { "maxLength": 5000, "type": "string" - }, - "verification": { - "properties": { - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "verification_document_specs", - "type": "object" - } - }, - "title": "verification_specs", - "type": "object" } + ], + "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js).", + "x-stripeBypassValidation": true + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "title": "company_specs", + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" }, - "country": { - "description": "The country in which the account holder resides, or in which the business is legally established. This should be an ISO 3166-1 alpha-2 country code. For example, if you are in the United States and the business for which you're creating an account is legally represented in Canada, you would use `CA` as the country for the account being created.", + "source": { + "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payment_source" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/customers/{customer}/bank_accounts/{id}": { + "delete": { + "description": "

Delete a specified source for a given customer.

", + "operationId": "DeleteCustomersCustomerBankAccountsId", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_source" + }, + { + "$ref": "#/components/schemas/deleted_payment_source" + } + ] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "deprecated": true, + "description": "

By default, you can see the 10 most recent sources stored on a Customer directly on the object, but you can also retrieve details about a specific bank account stored on the Stripe account.

", + "operationId": "GetCustomersCustomerBankAccountsId", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/bank_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Update a specified source for a given customer.

", + "operationId": "PostCustomersCustomerBankAccountsId", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "owner": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account_holder_name": { + "description": "The name of the person or business that owns the bank account.", + "maxLength": 5000, + "type": "string" + }, + "account_holder_type": { + "description": "The type of entity that holds the account. This can be either `individual` or `company`.", + "enum": ["company", "individual"], "maxLength": 5000, "type": "string" }, - "default_currency": { - "description": "Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://stripe.com/docs/payouts).", + "address_city": { + "description": "City/District/Suburb/Town/Village.", + "maxLength": 5000, "type": "string" }, - "documents": { - "description": "Documents that may be submitted to satisfy various informational requests.", - "properties": { - "bank_account_ownership_verification": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_license": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_memorandum_of_association": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_ministerial_decree": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_registration_verification": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_tax_id_verification": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - } - }, - "title": "documents_specs", - "type": "object" + "address_country": { + "description": "Billing address country, if provided when creating card.", + "maxLength": 5000, + "type": "string" }, - "email": { - "description": "The email address of the account holder. This is only to make the account easier to identify to you. Stripe will never directly email Custom accounts.", + "address_line1": { + "description": "Address line 1 (Street address/PO Box/Company name).", + "maxLength": 5000, + "type": "string" + }, + "address_line2": { + "description": "Address line 2 (Apartment/Suite/Unit/Building).", + "maxLength": 5000, + "type": "string" + }, + "address_state": { + "description": "State/County/Province/Region.", + "maxLength": 5000, + "type": "string" + }, + "address_zip": { + "description": "ZIP or postal code.", + "maxLength": 5000, + "type": "string" + }, + "exp_month": { + "description": "Two digit number representing the card’s expiration month.", + "maxLength": 5000, + "type": "string" + }, + "exp_year": { + "description": "Four digit number representing the card’s expiration year.", + "maxLength": 5000, "type": "string" }, "expand": { @@ -29244,238 +69749,6 @@ }, "type": "array" }, - "external_account": { - "description": "A card or bank account to attach to the account for receiving [payouts](https://stripe.com/docs/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://stripe.com/docs/api#account_create_bank_account) creation.

By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the bank account or card creation API.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "individual": { - "description": "Information about the person represented by the account. This field is null unless `business_type` is set to `individual`.", - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kanji_specs", - "type": "object" - }, - "dob": { - "anyOf": [ - { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" - }, - "year": { - "type": "integer" - } - }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "email": { - "type": "string" - }, - "first_name": { - "maxLength": 100, - "type": "string" - }, - "first_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "gender": { - "type": "string" - }, - "id_number": { - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "maxLength": 100, - "type": "string" - }, - "last_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "last_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "maiden_name": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "phone": { - "type": "string" - }, - "political_exposure": { - "enum": ["existing", "none"], - "type": "string" - }, - "ssn_last_4": { - "maxLength": 5000, - "type": "string" - }, - "verification": { - "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - } - }, - "title": "person_verification_specs", - "type": "object" - } - }, - "title": "individual_specs", - "type": "object" - }, "metadata": { "anyOf": [ { @@ -29491,159 +69764,57 @@ ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "settings": { - "description": "Options for customizing how the account functions within Stripe.", + "name": { + "description": "Cardholder name.", + "maxLength": 5000, + "type": "string" + }, + "owner": { "properties": { - "branding": { + "address": { "properties": { - "icon": { + "city": { "maxLength": 5000, "type": "string" }, - "logo": { + "country": { "maxLength": 5000, "type": "string" }, - "primary_color": { + "line1": { "maxLength": 5000, "type": "string" }, - "secondary_color": { + "line2": { "maxLength": 5000, "type": "string" - } - }, - "title": "branding_settings_specs", - "type": "object" - }, - "card_payments": { - "properties": { - "decline_on": { - "properties": { - "avs_failure": { - "type": "boolean" - }, - "cvc_failure": { - "type": "boolean" - } - }, - "title": "decline_charge_on_specs", - "type": "object" - }, - "statement_descriptor_prefix": { - "maxLength": 10, - "type": "string" - } - }, - "title": "card_payments_settings_specs", - "type": "object" - }, - "payments": { - "properties": { - "statement_descriptor": { - "maxLength": 22, - "type": "string" - }, - "statement_descriptor_kana": { - "maxLength": 22, - "type": "string" }, - "statement_descriptor_kanji": { - "maxLength": 22, + "postal_code": { + "maxLength": 5000, "type": "string" - } - }, - "title": "payments_settings_specs", - "type": "object" - }, - "payouts": { - "properties": { - "debit_negative_balances": { - "type": "boolean" }, - "schedule": { - "properties": { - "delay_days": { - "anyOf": [ - { - "enum": ["minimum"], - "maxLength": 5000, - "type": "string" - }, - { - "type": "integer" - } - ] - }, - "interval": { - "enum": [ - "daily", - "manual", - "monthly", - "weekly" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "monthly_anchor": { - "type": "integer" - }, - "weekly_anchor": { - "enum": [ - "friday", - "monday", - "saturday", - "sunday", - "thursday", - "tuesday", - "wednesday" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "transfer_schedule_specs", - "type": "object" - }, - "statement_descriptor": { - "maxLength": 22, + "state": { + "maxLength": 5000, "type": "string" } }, - "title": "payout_settings_specs", + "title": "source_address", "type": "object" - } - }, - "title": "settings_specs", - "type": "object" - }, - "tos_acceptance": { - "description": "Details on the account's acceptance of the [Stripe Services Agreement](https://stripe.com/docs/connect/updating-accounts#tos-acceptance).", - "properties": { - "date": { - "format": "unix-time", - "type": "integer" }, - "ip": { + "email": { "type": "string" }, - "service_agreement": { + "name": { "maxLength": 5000, "type": "string" }, - "user_agent": { + "phone": { "maxLength": 5000, "type": "string" } }, - "title": "tos_acceptance_specs", + "title": "owner", "type": "object" - }, - "type": { - "description": "The type of Stripe account to create. May be one of `custom`, `express` or `standard`.", - "enum": ["custom", "express", "standard"], - "type": "string" } }, "type": "object" @@ -29657,7 +69828,17 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/account" + "anyOf": [ + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/source" + } + ] } } }, @@ -29676,14 +69857,24 @@ } } }, - "/v1/accounts/{account}": { - "delete": { - "description": "

With Connect, you can delete Custom or Express accounts you manage.

\n\n

Accounts created using test-mode keys can be deleted at any time. Accounts created using live-mode keys can only be deleted once all balances are zero.

\n\n

If you want to delete your own account, use the account information tab in your account settings instead.

", - "operationId": "DeleteAccountsAccount", + "/v1/customers/{customer}/bank_accounts/{id}/verify": { + "post": { + "description": "

Verify a specified bank account for a given customer.

", + "operationId": "PostCustomersCustomerBankAccountsIdVerify", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -29695,9 +69886,35 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "amounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "amounts": { + "description": "Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.", + "items": { + "type": "integer" + }, + "type": "array" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -29709,7 +69926,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_account" + "$ref": "#/components/schemas/bank_account" } } }, @@ -29726,14 +69943,17 @@ "description": "Error response." } } - }, + } + }, + "/v1/customers/{customer}/cards": { "get": { - "description": "

Retrieves the details of an account.

", - "operationId": "GetAccountsAccount", + "deprecated": true, + "description": "

You can see a list of the cards belonging to a customer.\nNote that the 10 most recent sources are always available on the Customer object.\nIf you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional cards.

", + "operationId": "GetCustomersCustomerCards", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -29741,6 +69961,16 @@ }, "style": "simple" }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -29755,6 +69985,26 @@ "type": "array" }, "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" } ], "requestBody": { @@ -29762,6 +70012,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -29774,7 +70025,33 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/account" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/card" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "CardList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -29793,12 +70070,12 @@ } }, "post": { - "description": "

Updates a connected Express or Custom account by setting the values of the parameters passed. Any parameters not provided are left unchanged. Most parameters can be changed only for Custom accounts. (These are marked Custom Only below.) Parameters marked Custom and Express are supported by both account types.

\n\n

To update your own account, use the Dashboard. Refer to our Connect documentation to learn more about updating accounts.

", - "operationId": "PostAccountsAccount", + "description": "

When you create a new credit card, you must specify a customer or recipient on which to create it.

\n\n

If the card’s owner has no default card, then the new card will become the default.\nHowever, if the owner already has a default, then it will not change.\nTo change the default, you should update the customer to have a new default_source.

", + "operationId": "PostCustomersCustomerCards", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -29815,19 +70092,7 @@ "explode": true, "style": "deepObject" }, - "business_profile": { - "explode": true, - "style": "deepObject" - }, - "capabilities": { - "explode": true, - "style": "deepObject" - }, - "company": { - "explode": true, - "style": "deepObject" - }, - "documents": { + "card": { "explode": true, "style": "deepObject" }, @@ -29835,27 +70100,16 @@ "explode": true, "style": "deepObject" }, - "individual": { - "explode": true, - "style": "deepObject" - }, "metadata": { "explode": true, "style": "deepObject" - }, - "settings": { - "explode": true, - "style": "deepObject" - }, - "tos_acceptance": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "account_token": { - "description": "An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.", + "alipay_account": { + "description": "A token returned by [Stripe.js](https://stripe.com/docs/js) representing the user’s Alipay account details.", "maxLength": 5000, "type": "string" }, @@ -29894,7 +70148,7 @@ } }, "required": ["account_number", "country"], - "title": "external_account_payout_bank_account", + "title": "customer_payment_source_bank_account", "type": "object" }, { @@ -29902,557 +70156,383 @@ "type": "string" } ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." - }, - "business_profile": { - "description": "Business information about the account.", - "properties": { - "mcc": { - "maxLength": 4, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "product_description": { - "maxLength": 40000, - "type": "string" - }, - "support_address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "support_email": { - "type": "string" - }, - "support_phone": { - "maxLength": 5000, - "type": "string" - }, - "support_url": { - "type": "string" - }, - "url": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "business_profile_specs", - "type": "object" - }, - "business_type": { - "description": "The business type.", - "enum": [ - "company", - "government_entity", - "individual", - "non_profit" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "capabilities": { - "description": "Each key of the dictionary represents a capability, and each capability maps to its settings (e.g. whether it has been requested or not). Each capability will be inactive until you have provided its specific requirements and Stripe has verified them. An account may have some of its requested capabilities be active and some be inactive.", - "properties": { - "afterpay_clearpay_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "au_becs_debit_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "bacs_debit_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "bancontact_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "card_issuing": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "card_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "cartes_bancaires_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "eps_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "fpx_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "giropay_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "grabpay_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "ideal_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "jcb_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "legacy_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "oxxo_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "p24_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "sepa_debit_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "sofort_payments": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "tax_reporting_us_1099_k": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "tax_reporting_us_1099_misc": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - }, - "transfers": { - "properties": { - "requested": { - "type": "boolean" - } - }, - "title": "capability_param", - "type": "object" - } - }, - "title": "capabilities_param", - "type": "object" + "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/js), or a dictionary containing a user's bank account details." }, - "company": { - "description": "Information about the company or business. This field is available for any `business_type`.", - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { + "card": { + "anyOf": [ + { "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { + "address_city": { "maxLength": 5000, "type": "string" }, - "state": { + "address_country": { "maxLength": 5000, "type": "string" }, - "town": { + "address_line1": { "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "properties": { - "city": { + "type": "string" + }, + "address_line2": { "maxLength": 5000, "type": "string" }, - "country": { + "address_state": { "maxLength": 5000, "type": "string" }, - "line1": { + "address_zip": { "maxLength": 5000, "type": "string" }, - "line2": { + "cvc": { "maxLength": 5000, "type": "string" }, - "postal_code": { + "exp_month": { + "type": "integer" + }, + "exp_year": { + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "name": { "maxLength": 5000, "type": "string" }, - "state": { + "number": { "maxLength": 5000, "type": "string" }, - "town": { + "object": { + "enum": ["card"], "maxLength": 5000, "type": "string" } }, - "title": "japan_address_kanji_specs", + "required": ["exp_month", "exp_year", "number"], + "title": "customer_payment_source_card", "type": "object" }, - "directors_provided": { - "type": "boolean" - }, - "executives_provided": { - "type": "boolean" - }, - "name": { - "maxLength": 100, - "type": "string" - }, - "name_kana": { - "maxLength": 100, - "type": "string" - }, - "name_kanji": { - "maxLength": 100, - "type": "string" - }, - "owners_provided": { - "type": "boolean" - }, - "phone": { - "maxLength": 5000, - "type": "string" - }, - "registration_number": { - "maxLength": 5000, - "type": "string" - }, - "structure": { - "enum": [ - "", - "government_instrumentality", - "governmental_unit", - "incorporated_non_profit", - "limited_liability_partnership", - "multi_member_llc", - "private_company", - "private_corporation", - "private_partnership", - "public_company", - "public_corporation", - "public_partnership", - "sole_proprietorship", - "tax_exempt_government_instrumentality", - "unincorporated_association", - "unincorporated_non_profit" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "tax_id": { - "maxLength": 5000, - "type": "string" - }, - "tax_id_registrar": { - "maxLength": 5000, - "type": "string" - }, - "vat_id": { + { "maxLength": 5000, "type": "string" - }, - "verification": { - "properties": { - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "verification_document_specs", - "type": "object" - } - }, - "title": "verification_specs", - "type": "object" } + ], + "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js).", + "x-stripeBypassValidation": true + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "title": "company_specs", + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" }, - "default_currency": { - "description": "Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://stripe.com/docs/payouts).", + "source": { + "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payment_source" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/customers/{customer}/cards/{id}": { + "delete": { + "description": "

Delete a specified source for a given customer.

", + "operationId": "DeleteCustomersCustomerCardsId", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_source" + }, + { + "$ref": "#/components/schemas/deleted_payment_source" + } + ] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "deprecated": true, + "description": "

You can always see the 10 most recent cards directly on a customer; this method lets you retrieve details about a specific card stored on the customer.

", + "operationId": "GetCustomersCustomerCardsId", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/card" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Update a specified source for a given customer.

", + "operationId": "PostCustomersCustomerCardsId", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "owner": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account_holder_name": { + "description": "The name of the person or business that owns the bank account.", + "maxLength": 5000, "type": "string" }, - "documents": { - "description": "Documents that may be submitted to satisfy various informational requests.", - "properties": { - "bank_account_ownership_verification": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_license": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_memorandum_of_association": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_ministerial_decree": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_registration_verification": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - }, - "company_tax_id_verification": { - "properties": { - "files": { - "items": { - "maxLength": 500, - "type": "string" - }, - "type": "array" - } - }, - "title": "documents_param", - "type": "object" - } - }, - "title": "documents_specs", - "type": "object" + "account_holder_type": { + "description": "The type of entity that holds the account. This can be either `individual` or `company`.", + "enum": ["company", "individual"], + "maxLength": 5000, + "type": "string" }, - "email": { - "description": "The email address of the account holder. This is only to make the account easier to identify to you. Stripe will never directly email Custom accounts.", + "address_city": { + "description": "City/District/Suburb/Town/Village.", + "maxLength": 5000, + "type": "string" + }, + "address_country": { + "description": "Billing address country, if provided when creating card.", + "maxLength": 5000, + "type": "string" + }, + "address_line1": { + "description": "Address line 1 (Street address/PO Box/Company name).", + "maxLength": 5000, + "type": "string" + }, + "address_line2": { + "description": "Address line 2 (Apartment/Suite/Unit/Building).", + "maxLength": 5000, + "type": "string" + }, + "address_state": { + "description": "State/County/Province/Region.", + "maxLength": 5000, + "type": "string" + }, + "address_zip": { + "description": "ZIP or postal code.", + "maxLength": 5000, + "type": "string" + }, + "exp_month": { + "description": "Two digit number representing the card’s expiration month.", + "maxLength": 5000, + "type": "string" + }, + "exp_year": { + "description": "Four digit number representing the card’s expiration year.", + "maxLength": 5000, "type": "string" }, "expand": { @@ -30463,80 +70543,29 @@ }, "type": "array" }, - "external_account": { - "description": "A card or bank account to attach to the account for receiving [payouts](https://stripe.com/docs/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://stripe.com/docs/api#account_create_bank_account) creation.

By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the bank account or card creation API.", + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "name": { + "description": "Cardholder name.", "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" }, - "individual": { - "description": "Information about the person represented by the account. This field is null unless `business_type` is set to `individual`.", + "owner": { "properties": { "address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { "properties": { "city": { "maxLength": 5000, @@ -30561,302 +70590,182 @@ "state": { "maxLength": 5000, "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" } }, - "title": "japan_address_kanji_specs", + "title": "source_address", "type": "object" }, - "dob": { - "anyOf": [ - { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" - }, - "year": { - "type": "integer" - } - }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, "email": { "type": "string" }, - "first_name": { - "maxLength": 100, - "type": "string" - }, - "first_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "gender": { - "type": "string" - }, - "id_number": { - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "maxLength": 100, - "type": "string" - }, - "last_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "last_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "maiden_name": { + "name": { "maxLength": 5000, "type": "string" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, "phone": { - "type": "string" - }, - "political_exposure": { - "enum": ["existing", "none"], - "type": "string" - }, - "ssn_last_4": { "maxLength": 5000, "type": "string" - }, - "verification": { - "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - } - }, - "title": "person_verification_specs", - "type": "object" } }, - "title": "individual_specs", + "title": "owner", "type": "object" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "settings": { - "description": "Options for customizing how the account functions within Stripe.", - "properties": { - "branding": { - "properties": { - "icon": { - "maxLength": 5000, - "type": "string" - }, - "logo": { - "maxLength": 5000, - "type": "string" - }, - "primary_color": { - "maxLength": 5000, - "type": "string" - }, - "secondary_color": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "branding_settings_specs", - "type": "object" - }, - "card_payments": { - "properties": { - "decline_on": { - "properties": { - "avs_failure": { - "type": "boolean" - }, - "cvc_failure": { - "type": "boolean" - } - }, - "title": "decline_charge_on_specs", - "type": "object" - }, - "statement_descriptor_prefix": { - "maxLength": 10, - "type": "string" - } - }, - "title": "card_payments_settings_specs", - "type": "object" - }, - "payments": { - "properties": { - "statement_descriptor": { - "maxLength": 22, - "type": "string" - }, - "statement_descriptor_kana": { - "maxLength": 22, - "type": "string" - }, - "statement_descriptor_kanji": { - "maxLength": 22, - "type": "string" - } - }, - "title": "payments_settings_specs", - "type": "object" - }, - "payouts": { - "properties": { - "debit_negative_balances": { - "type": "boolean" - }, - "schedule": { - "properties": { - "delay_days": { - "anyOf": [ - { - "enum": ["minimum"], - "maxLength": 5000, - "type": "string" - }, - { - "type": "integer" - } - ] - }, - "interval": { - "enum": [ - "daily", - "manual", - "monthly", - "weekly" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "monthly_anchor": { - "type": "integer" - }, - "weekly_anchor": { - "enum": [ - "friday", - "monday", - "saturday", - "sunday", - "thursday", - "tuesday", - "wednesday" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "transfer_schedule_specs", - "type": "object" - }, - "statement_descriptor": { - "maxLength": 22, - "type": "string" - } - }, - "title": "payout_settings_specs", - "type": "object" - } + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "$ref": "#/components/schemas/card" }, - "title": "settings_specs", - "type": "object" + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/source" + } + ] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/customers/{customer}/cash_balance": { + "get": { + "description": "

Retrieves a customer’s cash balance.

", + "operationId": "GetCustomersCustomerCashBalance", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/cash_balance" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Changes the settings on a customer’s cash balance.

", + "operationId": "PostCustomersCustomerCashBalance", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "settings": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "tos_acceptance": { - "description": "Details on the account's acceptance of the [Stripe Services Agreement](https://stripe.com/docs/connect/updating-accounts#tos-acceptance).", + "settings": { + "description": "A hash of settings for this cash balance.", "properties": { - "date": { - "format": "unix-time", - "type": "integer" - }, - "ip": { - "type": "string" - }, - "service_agreement": { - "maxLength": 5000, - "type": "string" - }, - "user_agent": { - "maxLength": 5000, + "reconciliation_mode": { + "enum": ["automatic", "manual", "merchant_default"], "type": "string" } }, - "title": "tos_acceptance_specs", + "title": "balance_settings_param", "type": "object" } }, @@ -30871,7 +70780,134 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/cash_balance" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/customers/{customer}/cash_balance_transactions": { + "get": { + "description": "

Returns a list of transactions that modified the customer’s cash balance.

", + "operationId": "GetCustomersCustomerCashBalanceTransactions", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "Customers with certain payments enabled have a cash balance, representing funds that were paid\nby the customer to a merchant, but have not yet been allocated to a payment. Cash Balance Transactions\nrepresent when funds are moved into or out of this balance. This includes funding by the customer, allocation\nto payments, and refunds to the customer.", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/customer_cash_balance_transaction" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "CustomerCashBalanceTransactionList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -30890,112 +70926,53 @@ } } }, - "/v1/accounts/{account}/bank_accounts": { - "post": { - "description": "

Create an external account for a given account.

", - "operationId": "PostAccountsAccountBankAccounts", + "/v1/customers/{customer}/cash_balance_transactions/{transaction}": { + "get": { + "description": "

Retrieves a specific cash balance transaction, which updated the customer’s cash balance.

", + "operationId": "GetCustomersCustomerCashBalanceTransactionsTransaction", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "transaction", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "bank_account": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "bank_account": { - "anyOf": [ - { - "properties": { - "account_holder_name": { - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "type": "string" - }, - "object": { - "enum": ["bank_account"], - "maxLength": 5000, - "type": "string" - }, - "routing_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "country"], - "title": "external_account_payout_bank_account", - "type": "object" - }, - { - "maxLength": 5000, - "type": "string" - } - ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." - }, - "default_for_currency": { - "description": "When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.", - "type": "boolean" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "external_account": { - "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -31007,7 +70984,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "$ref": "#/components/schemas/customer_cash_balance_transaction" } } }, @@ -31026,29 +71003,20 @@ } } }, - "/v1/accounts/{account}/bank_accounts/{id}": { + "/v1/customers/{customer}/discount": { "delete": { - "description": "

Delete a specified external account for a given account.

", - "operationId": "DeleteAccountsAccountBankAccountsId", + "description": "

Removes the currently applied discount on a customer.

", + "operationId": "DeleteCustomersCustomerDiscount", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" } ], "requestBody": { @@ -31056,6 +71024,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -31068,7 +71037,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_external_account" + "$ref": "#/components/schemas/deleted_discount" } } }, @@ -31087,12 +71056,12 @@ } }, "get": { - "description": "

Retrieve a specified external account for a given account.

", - "operationId": "GetAccountsAccountBankAccountsId", + "description": "", + "operationId": "GetCustomersCustomerDiscount", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -31114,15 +71083,6 @@ "type": "array" }, "style": "deepObject" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" } ], "requestBody": { @@ -31130,6 +71090,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -31142,7 +71103,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "$ref": "#/components/schemas/discount" } } }, @@ -31159,99 +71120,80 @@ "description": "Error response." } } - }, + } + }, + "/v1/customers/{customer}/funding_instructions": { "post": { - "description": "

Updates the metadata, account holder name, and account holder type of a bank account belonging to a Custom account, and optionally sets it as the default for its currency. Other bank account details are not editable by design.

\n\n

You can re-enable a disabled bank account by performing an update call without providing any arguments or changes.

", - "operationId": "PostAccountsAccountBankAccountsId", + "description": "

Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new\nfunding instructions will be created. If funding instructions have already been created for a given customer, the same\nfunding instructions will be retrieved. In other words, we will return the same funding instructions each time.

", + "operationId": "PostCustomersCustomerFundingInstructions", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "expand": { + "bank_transfer": { "explode": true, "style": "deepObject" }, - "metadata": { + "expand": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "account_holder_name": { - "description": "The name of the person or business that owns the bank account.", - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "description": "The type of entity that holds the account. This can be either `individual` or `company`.", - "enum": ["", "company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "address_city": { - "description": "City/District/Suburb/Town/Village.", - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "description": "Billing address country, if provided when creating card.", - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "description": "Address line 1 (Street address/PO Box/Company name).", - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "description": "Address line 2 (Apartment/Suite/Unit/Building).", - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "description": "State/County/Province/Region.", - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "description": "ZIP or postal code.", - "maxLength": 5000, - "type": "string" - }, - "default_for_currency": { - "description": "When set to true, this becomes the default external account for its currency.", - "type": "boolean" - }, - "exp_month": { - "description": "Two digit number representing the card’s expiration month.", - "maxLength": 5000, - "type": "string" + "bank_transfer": { + "description": "Additional parameters for `bank_transfer` funding types", + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_account_params", + "type": "object" + }, + "requested_address_types": { + "items": { + "enum": ["iban", "sort_code", "spei", "zengin"], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "type": { + "enum": [ + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "mx_bank_transfer", + "us_bank_transfer" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "bank_transfer_params", + "type": "object" }, - "exp_year": { - "description": "Four digit number representing the card’s expiration year.", - "maxLength": 5000, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, "expand": { @@ -31262,39 +71204,25 @@ }, "type": "array" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "name": { - "description": "Cardholder name.", - "maxLength": 5000, + "funding_type": { + "description": "The `funding_type` to get the instructions for.", + "enum": ["bank_transfer"], "type": "string" } }, + "required": ["bank_transfer", "currency", "funding_type"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "$ref": "#/components/schemas/funding_instructions" } } }, @@ -31313,14 +71241,25 @@ } } }, - "/v1/accounts/{account}/capabilities": { + "/v1/customers/{customer}/payment_methods": { "get": { - "description": "

Returns a list of capabilities associated with the account. The capabilities are returned sorted by creation date, with the most recent capability appearing first.

", - "operationId": "GetAccountsAccountCapabilities", + "description": "

Returns a list of PaymentMethods for a given Customer

", + "operationId": "GetCustomersCustomerPaymentMethods", "parameters": [ + { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "in": "query", + "name": "allow_redisplay", + "required": false, + "schema": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "style": "form" + }, { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -31328,6 +71267,16 @@ }, "style": "simple" }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -31342,6 +71291,76 @@ "type": "array" }, "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.", + "in": "query", + "name": "type", + "required": false, + "schema": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "style": "form" } ], "requestBody": { @@ -31349,6 +71368,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -31365,7 +71385,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/capability" + "$ref": "#/components/schemas/payment_method" }, "type": "array" }, @@ -31385,7 +71405,7 @@ } }, "required": ["data", "has_more", "object", "url"], - "title": "ListAccountCapability", + "title": "CustomerPaymentMethodResourceList", "type": "object", "x-expandableFields": ["data"] } @@ -31406,14 +71426,14 @@ } } }, - "/v1/accounts/{account}/capabilities/{capability}": { + "/v1/customers/{customer}/payment_methods/{payment_method}": { "get": { - "description": "

Retrieves information about the specified Account Capability.

", - "operationId": "GetAccountsAccountCapabilitiesCapability", + "description": "

Retrieves a PaymentMethod object for a given Customer.

", + "operationId": "GetCustomersCustomerPaymentMethodsPaymentMethod", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -31421,15 +71441,6 @@ }, "style": "simple" }, - { - "in": "path", - "name": "capability", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -31444,91 +71455,25 @@ "type": "array" }, "style": "deepObject" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/capability" - } - } - }, - "description": "Successful response." }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates an existing Account Capability.

", - "operationId": "PostAccountsAccountCapabilitiesCapability", - "parameters": [ { "in": "path", - "name": "account", + "name": "payment_method", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - }, - { - "in": "path", - "name": "capability", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "requested": { - "description": "Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.", - "type": "boolean" - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -31540,7 +71485,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/capability" + "$ref": "#/components/schemas/payment_method" } } }, @@ -31559,14 +71504,14 @@ } } }, - "/v1/accounts/{account}/external_accounts": { + "/v1/customers/{customer}/sources": { "get": { - "description": "

List external accounts for an account.

", - "operationId": "GetAccountsAccountExternalAccounts", + "description": "

List sources for a specified customer.

", + "operationId": "GetCustomersCustomerSources", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -31609,6 +71554,17 @@ }, "style": "form" }, + { + "description": "Filter sources according to a particular object type.", + "in": "query", + "name": "object", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -31625,6 +71581,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -31640,7 +71597,7 @@ "description": "", "properties": { "data": { - "description": "The list contains all external accounts that have been attached to the Stripe account. These may be bank accounts or cards.", + "description": "Details about each object.", "items": { "anyOf": [ { @@ -31648,9 +71605,13 @@ }, { "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/source" } ], - "title": "Polymorphic" + "title": "Polymorphic", + "x-stripeBypassValidation": true }, "type": "array" }, @@ -31670,7 +71631,7 @@ } }, "required": ["data", "has_more", "object", "url"], - "title": "ExternalAccountList", + "title": "ApmsSourcesSourceList", "type": "object", "x-expandableFields": ["data"] } @@ -31691,12 +71652,12 @@ } }, "post": { - "description": "

Create an external account for a given account.

", - "operationId": "PostAccountsAccountExternalAccounts", + "description": "

When you create a new credit card, you must specify a customer or recipient on which to create it.

\n\n

If the card’s owner has no default card, then the new card will become the default.\nHowever, if the owner already has a default, then it will not change.\nTo change the default, you should update the customer to have a new default_source.

", + "operationId": "PostCustomersCustomerSources", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -31713,6 +71674,10 @@ "explode": true, "style": "deepObject" }, + "card": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" @@ -31723,7 +71688,13 @@ } }, "schema": { + "additionalProperties": false, "properties": { + "alipay_account": { + "description": "A token returned by [Stripe.js](https://stripe.com/docs/js) representing the user’s Alipay account details.", + "maxLength": 5000, + "type": "string" + }, "bank_account": { "anyOf": [ { @@ -31759,7 +71730,7 @@ } }, "required": ["account_number", "country"], - "title": "external_account_payout_bank_account", + "title": "customer_payment_source_bank_account", "type": "object" }, { @@ -31767,11 +71738,77 @@ "type": "string" } ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." + "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/js), or a dictionary containing a user's bank account details." }, - "default_for_currency": { - "description": "When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.", - "type": "boolean" + "card": { + "anyOf": [ + { + "properties": { + "address_city": { + "maxLength": 5000, + "type": "string" + }, + "address_country": { + "maxLength": 5000, + "type": "string" + }, + "address_line1": { + "maxLength": 5000, + "type": "string" + }, + "address_line2": { + "maxLength": 5000, + "type": "string" + }, + "address_state": { + "maxLength": 5000, + "type": "string" + }, + "address_zip": { + "maxLength": 5000, + "type": "string" + }, + "cvc": { + "maxLength": 5000, + "type": "string" + }, + "exp_month": { + "type": "integer" + }, + "exp_year": { + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "number": { + "maxLength": 5000, + "type": "string" + }, + "object": { + "enum": ["card"], + "maxLength": 5000, + "type": "string" + } + }, + "required": ["exp_month", "exp_year", "number"], + "title": "customer_payment_source_card", + "type": "object" + }, + { + "maxLength": 5000, + "type": "string" + } + ], + "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js).", + "x-stripeBypassValidation": true }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -31781,18 +71818,18 @@ }, "type": "array" }, - "external_account": { - "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, "metadata": { "additionalProperties": { "type": "string" }, "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" + }, + "source": { + "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true } }, "type": "object" @@ -31806,7 +71843,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "$ref": "#/components/schemas/payment_source" } } }, @@ -31825,14 +71862,14 @@ } } }, - "/v1/accounts/{account}/external_accounts/{id}": { + "/v1/customers/{customer}/sources/{id}": { "delete": { - "description": "

Delete a specified external account for a given account.

", - "operationId": "DeleteAccountsAccountExternalAccountsId", + "description": "

Delete a specified source for a given customer.

", + "operationId": "DeleteCustomersCustomerSourcesId", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -31853,9 +71890,24 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -31867,7 +71919,14 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_external_account" + "anyOf": [ + { + "$ref": "#/components/schemas/payment_source" + }, + { + "$ref": "#/components/schemas/deleted_payment_source" + } + ] } } }, @@ -31886,12 +71945,12 @@ } }, "get": { - "description": "

Retrieve a specified external account for a given account.

", - "operationId": "GetAccountsAccountExternalAccountsId", + "description": "

Retrieve a specified source for a given customer.

", + "operationId": "GetCustomersCustomerSourcesId", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -31919,6 +71978,7 @@ "name": "id", "required": true, "schema": { + "maxLength": 500, "type": "string" }, "style": "simple" @@ -31929,6 +71989,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -31941,7 +72002,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "$ref": "#/components/schemas/payment_source" } } }, @@ -31960,12 +72021,12 @@ } }, "post": { - "description": "

Updates the metadata, account holder name, and account holder type of a bank account belonging to a Custom account, and optionally sets it as the default for its currency. Other bank account details are not editable by design.

\n\n

You can re-enable a disabled bank account by performing an update call without providing any arguments or changes.

", - "operationId": "PostAccountsAccountExternalAccountsId", + "description": "

Update a specified source for a given customer.

", + "operationId": "PostCustomersCustomerSourcesId", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -31978,6 +72039,7 @@ "name": "id", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" @@ -31994,9 +72056,14 @@ "metadata": { "explode": true, "style": "deepObject" + }, + "owner": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "account_holder_name": { "description": "The name of the person or business that owns the bank account.", @@ -32005,7 +72072,7 @@ }, "account_holder_type": { "description": "The type of entity that holds the account. This can be either `individual` or `company`.", - "enum": ["", "company", "individual"], + "enum": ["company", "individual"], "maxLength": 5000, "type": "string" }, @@ -32039,10 +72106,6 @@ "maxLength": 5000, "type": "string" }, - "default_for_currency": { - "description": "When set to true, this becomes the default external account for its currency.", - "type": "boolean" - }, "exp_month": { "description": "Two digit number representing the card’s expiration month.", "maxLength": 5000, @@ -32080,6 +72143,53 @@ "description": "Cardholder name.", "maxLength": 5000, "type": "string" + }, + "owner": { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "source_address", + "type": "object" + }, + "email": { + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "owner", + "type": "object" } }, "type": "object" @@ -32093,7 +72203,17 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/external_account" + "anyOf": [ + { + "$ref": "#/components/schemas/card" + }, + { + "$ref": "#/components/schemas/bank_account" + }, + { + "$ref": "#/components/schemas/source" + } + ] } } }, @@ -32112,84 +72232,24 @@ } } }, - "/v1/accounts/{account}/login_links": { + "/v1/customers/{customer}/sources/{id}/verify": { "post": { - "description": "

Creates a single-use login link for an Express account to access their Stripe dashboard.

\n\n

You may only create login links for Express accounts connected to your platform.

", - "operationId": "PostAccountsAccountLoginLinks", + "description": "

Verify a specified bank account for a given customer.

", + "operationId": "PostCustomersCustomerSourcesIdVerify", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "redirect_url": { - "description": "Where to redirect the user after they log out of their dashboard.", - "type": "string" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/login_link" - } - } - }, - "description": "Successful response." }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/accounts/{account}/logout": { - "put": { - "description": "

Invalidates all sessions for a light account, for a platform to use during platform logout.

\n\n

You may only log out Express accounts connected to your platform.

", - "operationId": "PutAccountsAccountLogout", - "parameters": [ { "in": "path", - "name": "account", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -32202,13 +72262,25 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { + "amounts": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { + "amounts": { + "description": "Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.", + "items": { + "type": "integer" + }, + "type": "array" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -32229,7 +72301,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/light_account_logout" + "$ref": "#/components/schemas/bank_account" } } }, @@ -32248,14 +72320,14 @@ } } }, - "/v1/accounts/{account}/people": { + "/v1/customers/{customer}/subscriptions": { "get": { - "description": "

Returns a list of people associated with the account’s legal entity. The people are returned sorted by creation date, with the most recent people appearing first.

", - "operationId": "GetAccountsAccountPeople", + "description": "

You can see a list of the customer’s active subscriptions. Note that the 10 most recent active subscriptions are always available by default on the customer object. If you need more than those 10, you can use the limit and starting_after parameters to page through additional subscriptions.

", + "operationId": "GetCustomersCustomerSubscriptions", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -32299,32 +72371,6 @@ }, "style": "form" }, - { - "description": "Filters on the list of people returned based on the person's relationship to the account's company.", - "explode": true, - "in": "query", - "name": "relationship", - "required": false, - "schema": { - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "representative": { - "type": "boolean" - } - }, - "title": "all_people_relationship_specs", - "type": "object" - }, - "style": "deepObject" - }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -32342,6 +72388,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -32357,8 +72404,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/subscription" }, "type": "array" }, @@ -32378,6 +72426,7 @@ } }, "required": ["data", "has_more", "object", "url"], + "title": "SubscriptionList", "type": "object", "x-expandableFields": ["data"] } @@ -32398,12 +72447,12 @@ } }, "post": { - "description": "

Creates a new person.

", - "operationId": "PostAccountsAccountPeople", + "description": "

Creates a new subscription on an existing customer.

", + "operationId": "PostCustomersCustomerSubscriptions", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -32416,19 +72465,27 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "address": { + "add_invoice_items": { "explode": true, "style": "deepObject" }, - "address_kana": { + "application_fee_percent": { "explode": true, "style": "deepObject" }, - "address_kanji": { + "automatic_tax": { "explode": true, "style": "deepObject" }, - "dob": { + "billing_thresholds": { + "explode": true, + "style": "deepObject" + }, + "default_tax_rates": { + "explode": true, + "style": "deepObject" + }, + "discounts": { "explode": true, "style": "deepObject" }, @@ -32436,138 +72493,782 @@ "explode": true, "style": "deepObject" }, + "invoice_settings": { + "explode": true, + "style": "deepObject" + }, + "items": { + "explode": true, + "style": "deepObject" + }, "metadata": { "explode": true, "style": "deepObject" }, - "relationship": { + "payment_settings": { "explode": true, "style": "deepObject" }, - "verification": { + "pending_invoice_item_interval": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { + "explode": true, + "style": "deepObject" + }, + "trial_end": { + "explode": true, + "style": "deepObject" + }, + "trial_settings": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "address": { - "description": "The person's address.", - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" + "add_invoice_items": { + "description": "A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.", + "items": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } }, - "line2": { - "maxLength": 200, - "type": "string" + "title": "add_invoice_item_entry", + "type": "object" + }, + "type": "array" + }, + "application_fee_percent": { + "anyOf": [ + { + "type": "number" }, - "postal_code": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ], + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions)." + }, + "automatic_tax": { + "description": "Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.", + "properties": { + "enabled": { + "type": "boolean" }, - "state": { - "maxLength": 5000, - "type": "string" + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" } }, - "title": "address_specs", + "required": ["enabled"], + "title": "automatic_tax_config", "type": "object" }, - "address_kana": { - "description": "The Kana variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" + "backdate_start_date": { + "description": "For new subscriptions, a past timestamp to backdate the subscription's start date to. If set, the first invoice will contain a proration for the timespan between the start date and the current time. Can be combined with trials and the billing cycle anchor.", + "format": "unix-time", + "type": "integer" + }, + "billing_cycle_anchor": { + "description": "A future timestamp in UTC format to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). The anchor is the reference point that aligns future billing cycle dates. It sets the day of week for `week` intervals, the day of month for `month` and `year` intervals, and the month of year for `year` intervals.", + "format": "unix-time", + "type": "integer", + "x-stripeBypassValidation": true + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" }, - "postal_code": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." + }, + "cancel_at": { + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.", + "format": "unix-time", + "type": "integer" + }, + "cancel_at_period_end": { + "description": "Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.", + "type": "boolean" + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "coupon": { + "description": "The ID of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "days_until_due": { + "description": "Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.", + "type": "integer" + }, + "default_payment_method": { + "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "maxLength": 5000, + "type": "string" + }, + "default_source": { + "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "state": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ], + "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" }, - "town": { - "maxLength": 5000, + { + "enum": [""], "type": "string" } + ], + "description": "The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "title": "japan_address_kana_specs", - "type": "object" + "type": "array" }, - "address_kanji": { - "description": "The Kanji variation of the person's address (Japan only).", + "invoice_settings": { + "description": "All invoices will be billed using the specified settings.", "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "line1": { - "maxLength": 5000, - "type": "string" + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings_param", + "type": "object" + }, + "items": { + "description": "A list of up to 20 subscription items, each with an attached price.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } }, - "line2": { - "maxLength": 5000, - "type": "string" + "title": "subscription_item_create_params", + "type": "object" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" }, - "postal_code": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "off_session": { + "description": "Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).", + "type": "boolean" + }, + "payment_behavior": { + "description": "Only applies to subscriptions with `collection_method=charge_automatically`.\n\nUse `allow_incomplete` to create Subscriptions with `status=incomplete` if the first invoice can't be paid. Creating Subscriptions with this status allows you to manage scenarios where additional customer actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `default_incomplete` to create Subscriptions with `status=incomplete` when the first invoice requires payment, otherwise start as active. Subscriptions transition to `status=active` when successfully confirming the PaymentIntent on the first invoice. This allows simpler management of scenarios where additional customer actions are needed to pay a subscription’s invoice, such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method. If the PaymentIntent is not confirmed within 23 hours Subscriptions transition to `status=incomplete_expired`, which is a terminal state.\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice can't be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further customer action is needed, this parameter doesn't create a Subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.\n\n`pending_if_incomplete` is only used with updates and cannot be passed when creating a Subscription.\n\nSubscriptions with `collection_method=send_invoice` are automatically activated regardless of the first Invoice status.", + "enum": [ + "allow_incomplete", + "default_incomplete", + "error_if_incomplete", + "pending_if_incomplete" + ], + "type": "string" + }, + "payment_settings": { + "description": "Payment settings to pass to invoices created by the subscription.", + "properties": { + "payment_method_options": { + "properties": { + "acss_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bancontact": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": ["de", "en", "fr", "nl"], + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string" + } + }, + "title": "subscription_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "customer_balance": { + "anyOf": [ + { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_param", + "type": "object" + }, + "type": { + "type": "string" + } + }, + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "konbini": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "type": "string" + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_method_options", + "type": "object" }, - "state": { - "maxLength": 5000, - "type": "string" + "payment_method_types": { + "anyOf": [ + { + "items": { + "enum": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "konbini", + "link", + "multibanco", + "p24", + "paynow", + "paypal", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "us_bank_account", + "wechat_pay" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "town": { - "maxLength": 5000, + "save_default_payment_method": { + "enum": ["off", "on_subscription"], "type": "string" } }, - "title": "japan_address_kanji_specs", + "title": "payment_settings", "type": "object" }, - "dob": { + "pending_invoice_item_interval": { "anyOf": [ { "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" }, - "year": { + "interval_count": { "type": "integer" } }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", + "required": ["interval"], + "title": "pending_invoice_item_interval_params", "type": "object" }, { @@ -32575,169 +73276,71 @@ "type": "string" } ], - "description": "The person's date of birth." - }, - "email": { - "description": "The person's email address.", - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "first_name": { - "description": "The person's first name.", - "maxLength": 5000, - "type": "string" - }, - "first_name_kana": { - "description": "The Kana variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "description": "The Kanji variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "gender": { - "description": "The person's gender (International regulations require either \"male\" or \"female\").", - "type": "string" - }, - "id_number": { - "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://stripe.com/docs/stripe.js#collecting-pii-data).", - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "description": "The person's last name.", - "maxLength": 5000, - "type": "string" + "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval." }, - "last_name_kana": { - "description": "The Kana variation of the person's last name (Japan only).", + "promotion_code": { + "description": "The promotion code to apply to this subscription. A promotion code applied to a subscription will only affect invoices created for that particular subscription. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", "maxLength": 5000, "type": "string" }, - "last_name_kanji": { - "description": "The Kanji variation of the person's last name (Japan only).", - "maxLength": 5000, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], "type": "string" }, - "maiden_name": { - "description": "The person's maiden name.", - "maxLength": 5000, - "type": "string" + "transfer_data": { + "description": "If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.", + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" }, - "metadata": { + "trial_end": { "anyOf": [ { - "additionalProperties": { - "type": "string" - }, - "type": "object" + "enum": ["now"], + "maxLength": 5000, + "type": "string" }, { - "enum": [""], - "type": "string" + "format": "unix-time", + "type": "integer" } ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "nationality": { - "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", - "maxLength": 5000, - "type": "string" - }, - "person_token": { - "description": "A [person token](https://stripe.com/docs/connect/account-tokens), used to securely provide details to the person.", - "maxLength": 5000, - "type": "string" - }, - "phone": { - "description": "The person's phone number.", - "type": "string" - }, - "political_exposure": { - "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", - "maxLength": 5000, - "type": "string" + "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more." }, - "relationship": { - "description": "The relationship that this person has with the account's legal entity.", - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "percent_ownership": { - "anyOf": [ - { - "type": "number" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "representative": { - "type": "boolean" - }, - "title": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "relationship_specs", - "type": "object" + "trial_from_plan": { + "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.", + "type": "boolean" }, - "ssn_last_4": { - "description": "The last four digits of the person's Social Security number (U.S. only).", - "type": "string" + "trial_period_days": { + "description": "Integer representing the number of trial period days before the customer is charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.", + "type": "integer" }, - "verification": { - "description": "The person's verification status.", + "trial_settings": { + "description": "Settings related to subscription trials.", "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { + "end_behavior": { "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, + "missing_payment_method": { + "enum": ["cancel", "create_invoice", "pause"], "type": "string" } }, - "title": "person_verification_document_specs", + "required": ["missing_payment_method"], + "title": "end_behavior", "type": "object" } }, - "title": "person_verification_specs", + "required": ["end_behavior"], + "title": "trial_settings_config", "type": "object" } }, @@ -32752,7 +73355,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/subscription" } } }, @@ -32771,14 +73374,14 @@ } } }, - "/v1/accounts/{account}/people/{person}": { + "/v1/customers/{customer}/subscriptions/{subscription_exposed_id}": { "delete": { - "description": "

Deletes an existing person’s relationship to the account’s legal entity. Any person with a relationship for an account can be deleted through the API, except if the person is the account_opener. If your integration is using the executive parameter, you cannot delete the only verified executive on file.

", - "operationId": "DeleteAccountsAccountPeoplePerson", + "description": "

Cancels a customer’s subscription. If you set the at_period_end parameter to true, the subscription will remain active until the end of the period, at which point it will be canceled and not renewed. Otherwise, with the default false value, the subscription is terminated immediately. In either case, the customer will not be charged again for the subscription.

\n\n

Note, however, that any pending invoice items that you’ve created will still be charged for at the end of the period, unless manually deleted. If you’ve set the subscription to cancel at the end of the period, any pending prorations will also be left in place and collected at the end of the period. But if the subscription is set to cancel immediately, pending prorations will be removed.

\n\n

By default, upon subscription cancellation, Stripe will stop automatic collection of all finalized invoices for the customer. This is intended to prevent unexpected payment attempts after the customer has canceled a subscription. However, you can resume automatic collection of the invoices manually after subscription cancellation to have us proceed. Or, you could check for unpaid invoices before allowing the customer to cancel the subscription at all.

", + "operationId": "DeleteCustomersCustomerSubscriptionsSubscriptionExposedId", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -32788,7 +73391,7 @@ }, { "in": "path", - "name": "person", + "name": "subscription_exposed_id", "required": true, "schema": { "maxLength": 5000, @@ -32800,9 +73403,32 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "invoice_now": { + "description": "Can be set to `true` if `at_period_end` is not set to `true`. Will generate a final invoice that invoices for any un-invoiced metered usage and new/pending proration invoice items.", + "type": "boolean" + }, + "prorate": { + "description": "Can be set to `true` if `at_period_end` is not set to `true`. Will generate a proration invoice item that credits remaining unused time until the subscription period end.", + "type": "boolean" + } + }, "type": "object" } } @@ -32814,7 +73440,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_person" + "$ref": "#/components/schemas/subscription" } } }, @@ -32833,12 +73459,12 @@ } }, "get": { - "description": "

Retrieves an existing person.

", - "operationId": "GetAccountsAccountPeoplePerson", + "description": "

Retrieves the subscription with the given ID.

", + "operationId": "GetCustomersCustomerSubscriptionsSubscriptionExposedId", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -32863,7 +73489,7 @@ }, { "in": "path", - "name": "person", + "name": "subscription_exposed_id", "required": true, "schema": { "maxLength": 5000, @@ -32877,6 +73503,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -32889,7 +73516,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/subscription" } } }, @@ -32908,12 +73535,12 @@ } }, "post": { - "description": "

Updates an existing person.

", - "operationId": "PostAccountsAccountPeoplePerson", + "description": "

Updates an existing subscription on a customer to match the specified parameters. When changing plans or quantities, we will optionally prorate the price we charge next month to make up for any price changes. To preview how the proration will be calculated, use the upcoming invoice endpoint.

", + "operationId": "PostCustomersCustomerSubscriptionsSubscriptionExposedId", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -32923,7 +73550,7 @@ }, { "in": "path", - "name": "person", + "name": "subscription_exposed_id", "required": true, "schema": { "maxLength": 5000, @@ -32936,19 +73563,39 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "address": { + "add_invoice_items": { "explode": true, "style": "deepObject" }, - "address_kana": { + "application_fee_percent": { "explode": true, "style": "deepObject" }, - "address_kanji": { + "automatic_tax": { "explode": true, "style": "deepObject" }, - "dob": { + "billing_thresholds": { + "explode": true, + "style": "deepObject" + }, + "cancel_at": { + "explode": true, + "style": "deepObject" + }, + "cancellation_details": { + "explode": true, + "style": "deepObject" + }, + "default_source": { + "explode": true, + "style": "deepObject" + }, + "default_tax_rates": { + "explode": true, + "style": "deepObject" + }, + "discounts": { "explode": true, "style": "deepObject" }, @@ -32956,150 +73603,316 @@ "explode": true, "style": "deepObject" }, + "invoice_settings": { + "explode": true, + "style": "deepObject" + }, + "items": { + "explode": true, + "style": "deepObject" + }, "metadata": { "explode": true, "style": "deepObject" }, - "relationship": { + "pause_collection": { "explode": true, "style": "deepObject" }, - "verification": { + "payment_settings": { + "explode": true, + "style": "deepObject" + }, + "pending_invoice_item_interval": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { + "explode": true, + "style": "deepObject" + }, + "trial_end": { + "explode": true, + "style": "deepObject" + }, + "trial_settings": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "address": { - "description": "The person's address.", - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" + "add_invoice_items": { + "description": "A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.", + "items": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } }, - "line2": { - "maxLength": 200, - "type": "string" + "title": "add_invoice_item_entry", + "type": "object" + }, + "type": "array" + }, + "application_fee_percent": { + "anyOf": [ + { + "type": "number" }, - "postal_code": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ], + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions)." + }, + "automatic_tax": { + "description": "Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.", + "properties": { + "enabled": { + "type": "boolean" }, - "state": { - "maxLength": 5000, - "type": "string" + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" } }, - "title": "address_specs", + "required": ["enabled"], + "title": "automatic_tax_config", "type": "object" }, - "address_kana": { - "description": "The Kana variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" + "billing_cycle_anchor": { + "description": "Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", + "enum": ["now", "unchanged"], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" }, - "line1": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." + }, + "cancel_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" }, - "line2": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ], + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period." + }, + "cancel_at_period_end": { + "description": "Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.", + "type": "boolean" + }, + "cancellation_details": { + "description": "Details about why this subscription was cancelled", + "properties": { + "comment": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "postal_code": { - "maxLength": 5000, + "feedback": { + "enum": [ + "", + "customer_service", + "low_quality", + "missing_features", + "other", + "switched_service", + "too_complex", + "too_expensive", + "unused" + ], "type": "string" - }, - "state": { + } + }, + "title": "cancellation_details_param", + "type": "object" + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "coupon": { + "description": "The ID of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "days_until_due": { + "description": "Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.", + "type": "integer" + }, + "default_payment_method": { + "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "maxLength": 5000, + "type": "string" + }, + "default_source": { + "anyOf": [ + { "maxLength": 5000, "type": "string" }, - "town": { - "maxLength": 5000, + { + "enum": [""], "type": "string" } - }, - "title": "japan_address_kana_specs", - "type": "object" + ], + "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source)." }, - "address_kanji": { - "description": "The Kanji variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "town": { - "maxLength": 5000, + { + "enum": [""], "type": "string" } - }, - "title": "japan_address_kanji_specs", - "type": "object" + ], + "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates." }, - "dob": { + "discounts": { "anyOf": [ { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } }, - "year": { - "type": "integer" - } + "title": "discounts_data_param", + "type": "object" }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" + "type": "array" }, { "enum": [""], "type": "string" } ], - "description": "The person's date of birth." - }, - "email": { - "description": "The person's email address.", - "type": "string" + "description": "The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer." }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -33109,56 +73922,554 @@ }, "type": "array" }, - "first_name": { - "description": "The person's first name.", - "maxLength": 5000, - "type": "string" - }, - "first_name_kana": { - "description": "The Kana variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "description": "The Kanji variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" + "invoice_settings": { + "description": "All invoices will be billed using the specified settings.", + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings_param", + "type": "object" }, - "gender": { - "description": "The person's gender (International regulations require either \"male\" or \"female\").", - "type": "string" + "items": { + "description": "A list of up to 20 subscription items, each with an attached price.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "clear_usage": { + "type": "boolean" + }, + "deleted": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "id": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "subscription_item_update_params", + "type": "object" + }, + "type": "array" }, - "id_number": { - "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://stripe.com/docs/stripe.js#collecting-pii-data).", - "maxLength": 5000, - "type": "string" + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "last_name": { - "description": "The person's last name.", - "maxLength": 5000, - "type": "string" + "off_session": { + "description": "Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).", + "type": "boolean" }, - "last_name_kana": { - "description": "The Kana variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" + "pause_collection": { + "anyOf": [ + { + "properties": { + "behavior": { + "enum": [ + "keep_as_draft", + "mark_uncollectible", + "void" + ], + "type": "string" + }, + "resumes_at": { + "format": "unix-time", + "type": "integer" + } + }, + "required": ["behavior"], + "title": "pause_collection_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](/billing/subscriptions/pause-payment)." }, - "last_name_kanji": { - "description": "The Kanji variation of the person's last name (Japan only).", - "maxLength": 5000, + "payment_behavior": { + "description": "Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.\n\nUse `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.", + "enum": [ + "allow_incomplete", + "default_incomplete", + "error_if_incomplete", + "pending_if_incomplete" + ], "type": "string" }, - "maiden_name": { - "description": "The person's maiden name.", - "maxLength": 5000, - "type": "string" + "payment_settings": { + "description": "Payment settings to pass to invoices created by the subscription.", + "properties": { + "payment_method_options": { + "properties": { + "acss_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bancontact": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": ["de", "en", "fr", "nl"], + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string" + } + }, + "title": "subscription_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "customer_balance": { + "anyOf": [ + { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_param", + "type": "object" + }, + "type": { + "type": "string" + } + }, + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "konbini": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "type": "string" + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_method_options", + "type": "object" + }, + "payment_method_types": { + "anyOf": [ + { + "items": { + "enum": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "konbini", + "link", + "multibanco", + "p24", + "paynow", + "paypal", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "us_bank_account", + "wechat_pay" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "save_default_payment_method": { + "enum": ["off", "on_subscription"], + "type": "string" + } + }, + "title": "payment_settings", + "type": "object" }, - "metadata": { + "pending_invoice_item_interval": { "anyOf": [ { - "additionalProperties": { - "type": "string" + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } }, + "required": ["interval"], + "title": "pending_invoice_item_interval_params", "type": "object" }, { @@ -33166,98 +74477,80 @@ "type": "string" } ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "nationality": { - "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", - "maxLength": 5000, - "type": "string" + "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval." }, - "person_token": { - "description": "A [person token](https://stripe.com/docs/connect/account-tokens), used to securely provide details to the person.", + "promotion_code": { + "description": "The promotion code to apply to this subscription. A promotion code applied to a subscription will only affect invoices created for that particular subscription. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", "maxLength": 5000, "type": "string" }, - "phone": { - "description": "The person's phone number.", + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], "type": "string" }, - "political_exposure": { - "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", - "maxLength": 5000, - "type": "string" + "proration_date": { + "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same proration that was previewed with [upcoming invoice](https://stripe.com/docs/api#upcoming_invoice) endpoint. It can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.", + "format": "unix-time", + "type": "integer" }, - "relationship": { - "description": "The relationship that this person has with the account's legal entity.", - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "percent_ownership": { - "anyOf": [ - { + "transfer_data": { + "anyOf": [ + { + "properties": { + "amount_percent": { "type": "number" }, - { - "enum": [""], + "destination": { "type": "string" } - ] - }, - "representative": { - "type": "boolean" + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" }, - "title": { + { + "enum": [""], + "type": "string" + } + ], + "description": "If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value." + }, + "trial_end": { + "anyOf": [ + { + "enum": ["now"], "maxLength": 5000, "type": "string" + }, + { + "format": "unix-time", + "type": "integer" } - }, - "title": "relationship_specs", - "type": "object" + ], + "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`." }, - "ssn_last_4": { - "description": "The last four digits of the person's Social Security number (U.S. only).", - "type": "string" + "trial_from_plan": { + "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.", + "type": "boolean" }, - "verification": { - "description": "The person's verification status.", + "trial_settings": { + "description": "Settings related to subscription trials.", "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { + "end_behavior": { "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, + "missing_payment_method": { + "enum": ["cancel", "create_invoice", "pause"], "type": "string" } }, - "title": "person_verification_document_specs", + "required": ["missing_payment_method"], + "title": "end_behavior", "type": "object" } }, - "title": "person_verification_specs", + "required": ["end_behavior"], + "title": "trial_settings_config", "type": "object" } }, @@ -33272,7 +74565,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/subscription" } } }, @@ -33291,14 +74584,14 @@ } } }, - "/v1/accounts/{account}/persons": { - "get": { - "description": "

Returns a list of people associated with the account’s legal entity. The people are returned sorted by creation date, with the most recent people appearing first.

", - "operationId": "GetAccountsAccountPersons", + "/v1/customers/{customer}/subscriptions/{subscription_exposed_id}/discount": { + "delete": { + "description": "

Removes the currently applied discount on a customer.

", + "operationId": "DeleteCustomersCustomerSubscriptionsSubscriptionExposedIdDiscount", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -33307,15 +74600,65 @@ "style": "simple" }, { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, + "in": "path", + "name": "subscription_exposed_id", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_discount" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "", + "operationId": "GetCustomersCustomerSubscriptionsSubscriptionExposedIdDiscount", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" }, { "description": "Specifies which fields in the response should be expanded.", @@ -33333,41 +74676,104 @@ "style": "deepObject" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "path", + "name": "subscription_exposed_id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/discount" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/customers/{customer}/tax_ids": { + "get": { + "description": "

Returns a list of tax IDs for a customer.

", + "operationId": "GetCustomersCustomerTaxIds", + "parameters": [ + { + "in": "path", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", - "name": "limit", + "name": "ending_before", "required": false, "schema": { - "type": "integer" + "maxLength": 5000, + "type": "string" }, "style": "form" }, { - "description": "Filters on the list of people returned based on the person's relationship to the account's company.", + "description": "Specifies which fields in the response should be expanded.", "explode": true, "in": "query", - "name": "relationship", + "name": "expand", "required": false, "schema": { - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "representative": { - "type": "boolean" - } + "items": { + "maxLength": 5000, + "type": "string" }, - "title": "all_people_relationship_specs", - "type": "object" + "type": "array" }, "style": "deepObject" }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -33385,6 +74791,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -33400,8 +74807,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/tax_id" }, "type": "array" }, @@ -33421,6 +74829,7 @@ } }, "required": ["data", "has_more", "object", "url"], + "title": "TaxIDsList", "type": "object", "x-expandableFields": ["data"] } @@ -33441,12 +74850,12 @@ } }, "post": { - "description": "

Creates a new person.

", - "operationId": "PostAccountsAccountPersons", + "description": "

Creates a new tax_id object for a customer.

", + "operationId": "PostCustomersCustomerTaxIds", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -33459,343 +74868,122 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "address": { - "explode": true, - "style": "deepObject" - }, - "address_kana": { - "explode": true, - "style": "deepObject" - }, - "address_kanji": { - "explode": true, - "style": "deepObject" - }, - "dob": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "relationship": { - "explode": true, - "style": "deepObject" - }, - "verification": { - "explode": true, - "style": "deepObject" } }, "schema": { - "properties": { - "address": { - "description": "The person's address.", - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "description": "The Kana variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "description": "The Kanji variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kanji_specs", - "type": "object" - }, - "dob": { - "anyOf": [ - { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" - }, - "year": { - "type": "integer" - } - }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The person's date of birth." - }, - "email": { - "description": "The person's email address.", - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "first_name": { - "description": "The person's first name.", - "maxLength": 5000, - "type": "string" - }, - "first_name_kana": { - "description": "The Kana variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "description": "The Kanji variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "gender": { - "description": "The person's gender (International regulations require either \"male\" or \"female\").", - "type": "string" - }, - "id_number": { - "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://stripe.com/docs/stripe.js#collecting-pii-data).", - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "description": "The person's last name.", - "maxLength": 5000, - "type": "string" - }, - "last_name_kana": { - "description": "The Kana variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "last_name_kanji": { - "description": "The Kanji variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "maiden_name": { - "description": "The person's maiden name.", - "maxLength": 5000, - "type": "string" + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } + "type": { + "description": "Type of the tax ID, one of `ad_nrt`, `ae_trn`, `ar_cuit`, `au_abn`, `au_arn`, `bg_uic`, `bh_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `ch_uid`, `ch_vat`, `cl_tin`, `cn_tin`, `co_nit`, `cr_tin`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kr_brn`, `kz_bin`, `li_uid`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sv_nit`, `th_vat`, `tr_tin`, `tw_vat`, `ua_vat`, `us_ein`, `uy_ruc`, `ve_rif`, `vn_tin`, or `za_vat`", + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "nationality": { - "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", - "maxLength": 5000, - "type": "string" - }, - "person_token": { - "description": "A [person token](https://stripe.com/docs/connect/account-tokens), used to securely provide details to the person.", - "maxLength": 5000, - "type": "string" - }, - "phone": { - "description": "The person's phone number.", - "type": "string" - }, - "political_exposure": { - "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", "maxLength": 5000, - "type": "string" - }, - "relationship": { - "description": "The relationship that this person has with the account's legal entity.", - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "percent_ownership": { - "anyOf": [ - { - "type": "number" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "representative": { - "type": "boolean" - }, - "title": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "relationship_specs", - "type": "object" + "type": "string", + "x-stripeBypassValidation": true }, - "ssn_last_4": { - "description": "The last four digits of the person's Social Security number (U.S. only).", + "value": { + "description": "Value of the tax ID.", "type": "string" - }, - "verification": { - "description": "The person's verification status.", - "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - } - }, - "title": "person_verification_specs", - "type": "object" } }, + "required": ["type", "value"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/tax_id" } } }, @@ -33814,14 +75002,14 @@ } } }, - "/v1/accounts/{account}/persons/{person}": { + "/v1/customers/{customer}/tax_ids/{id}": { "delete": { - "description": "

Deletes an existing person’s relationship to the account’s legal entity. Any person with a relationship for an account can be deleted through the API, except if the person is the account_opener. If your integration is using the executive parameter, you cannot delete the only verified executive on file.

", - "operationId": "DeleteAccountsAccountPersonsPerson", + "description": "

Deletes an existing tax_id object.

", + "operationId": "DeleteCustomersCustomerTaxIdsId", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -33831,10 +75019,9 @@ }, { "in": "path", - "name": "person", + "name": "id", "required": true, "schema": { - "maxLength": 5000, "type": "string" }, "style": "simple" @@ -33845,6 +75032,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -33857,7 +75045,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_person" + "$ref": "#/components/schemas/deleted_tax_id" } } }, @@ -33876,12 +75064,12 @@ } }, "get": { - "description": "

Retrieves an existing person.

", - "operationId": "GetAccountsAccountPersonsPerson", + "description": "

Retrieves the tax_id object with the given identifier.

", + "operationId": "GetCustomersCustomerTaxIdsId", "parameters": [ { "in": "path", - "name": "account", + "name": "customer", "required": true, "schema": { "maxLength": 5000, @@ -33906,10 +75094,9 @@ }, { "in": "path", - "name": "person", + "name": "id", "required": true, "schema": { - "maxLength": 5000, "type": "string" }, "style": "simple" @@ -33920,6 +75107,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -33932,7 +75120,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/tax_id" } } }, @@ -33949,14 +75137,188 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates an existing person.

", - "operationId": "PostAccountsAccountPersonsPerson", + } + }, + "/v1/disputes": { + "get": { + "description": "

Returns a list of your disputes.

", + "operationId": "GetDisputes", + "parameters": [ + { + "description": "Only return disputes associated to the charge specified by this charge ID.", + "in": "query", + "name": "charge", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return disputes that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Only return disputes associated to the PaymentIntent specified by this PaymentIntent ID.", + "in": "query", + "name": "payment_intent", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/dispute" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/disputes", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "DisputeList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/disputes/{dispute}": { + "get": { + "description": "

Retrieves the dispute with the given ID.

", + "operationId": "GetDisputesDispute", "parameters": [ { "in": "path", - "name": "account", + "name": "dispute", "required": true, "schema": { "maxLength": 5000, @@ -33964,9 +75326,65 @@ }, "style": "simple" }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/dispute" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

When you get a dispute, contacting your customer is always the best first step. If that doesn’t work, you can submit evidence to help us resolve the dispute in your favor. You can do this in your dashboard, but if you prefer, you can use the API to submit evidence programmatically.

\n\n

Depending on your dispute type, different evidence fields will give you a better chance of winning your dispute. To figure out which evidence fields to provide, see our guide to dispute types.

", + "operationId": "PostDisputesDispute", + "parameters": [ { "in": "path", - "name": "person", + "name": "dispute", "required": true, "schema": { "maxLength": 5000, @@ -33979,19 +75397,7 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "address": { - "explode": true, - "style": "deepObject" - }, - "address_kana": { - "explode": true, - "style": "deepObject" - }, - "address_kanji": { - "explode": true, - "style": "deepObject" - }, - "dob": { + "evidence": { "explode": true, "style": "deepObject" }, @@ -34002,147 +75408,116 @@ "metadata": { "explode": true, "style": "deepObject" - }, - "relationship": { - "explode": true, - "style": "deepObject" - }, - "verification": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "address": { - "description": "The person's address.", + "evidence": { + "description": "Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.", "properties": { - "city": { - "maxLength": 100, + "access_activity_log": { + "maxLength": 20000, "type": "string" }, - "country": { + "billing_address": { "maxLength": 5000, "type": "string" }, - "line1": { - "maxLength": 200, + "cancellation_policy": { "type": "string" }, - "line2": { - "maxLength": 200, + "cancellation_policy_disclosure": { + "maxLength": 20000, "type": "string" }, - "postal_code": { - "maxLength": 5000, + "cancellation_rebuttal": { + "maxLength": 20000, "type": "string" }, - "state": { - "maxLength": 5000, + "customer_communication": { "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "description": "The Kana variation of the person's address (Japan only).", - "properties": { - "city": { + }, + "customer_email_address": { "maxLength": 5000, "type": "string" }, - "country": { + "customer_name": { "maxLength": 5000, "type": "string" }, - "line1": { + "customer_purchase_ip": { "maxLength": 5000, "type": "string" }, - "line2": { - "maxLength": 5000, + "customer_signature": { "type": "string" }, - "postal_code": { - "maxLength": 5000, + "duplicate_charge_documentation": { "type": "string" }, - "state": { - "maxLength": 5000, + "duplicate_charge_explanation": { + "maxLength": 20000, "type": "string" }, - "town": { + "duplicate_charge_id": { "maxLength": 5000, "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "description": "The Kanji variation of the person's address (Japan only).", - "properties": { - "city": { - "maxLength": 5000, + }, + "product_description": { + "maxLength": 20000, + "type": "string" + }, + "receipt": { + "type": "string" + }, + "refund_policy": { + "type": "string" + }, + "refund_policy_disclosure": { + "maxLength": 20000, + "type": "string" + }, + "refund_refusal_explanation": { + "maxLength": 20000, "type": "string" }, - "country": { + "service_date": { "maxLength": 5000, "type": "string" }, - "line1": { - "maxLength": 5000, + "service_documentation": { "type": "string" }, - "line2": { + "shipping_address": { "maxLength": 5000, "type": "string" }, - "postal_code": { + "shipping_carrier": { "maxLength": 5000, "type": "string" }, - "state": { + "shipping_date": { "maxLength": 5000, "type": "string" }, - "town": { + "shipping_documentation": { + "type": "string" + }, + "shipping_tracking_number": { "maxLength": 5000, "type": "string" - } - }, - "title": "japan_address_kanji_specs", - "type": "object" - }, - "dob": { - "anyOf": [ - { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" - }, - "year": { - "type": "integer" - } - }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" }, - { - "enum": [""], + "uncategorized_file": { + "type": "string" + }, + "uncategorized_text": { + "maxLength": 20000, "type": "string" } - ], - "description": "The person's date of birth." - }, - "email": { - "description": "The person's email address.", - "type": "string" + }, + "title": "dispute_evidence_params", + "type": "object" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -34152,50 +75527,6 @@ }, "type": "array" }, - "first_name": { - "description": "The person's first name.", - "maxLength": 5000, - "type": "string" - }, - "first_name_kana": { - "description": "The Kana variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "description": "The Kanji variation of the person's first name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "gender": { - "description": "The person's gender (International regulations require either \"male\" or \"female\").", - "type": "string" - }, - "id_number": { - "description": "The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://stripe.com/docs/stripe.js#collecting-pii-data).", - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "description": "The person's last name.", - "maxLength": 5000, - "type": "string" - }, - "last_name_kana": { - "description": "The Kana variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "last_name_kanji": { - "description": "The Kanji variation of the person's last name (Japan only).", - "maxLength": 5000, - "type": "string" - }, - "maiden_name": { - "description": "The person's maiden name.", - "maxLength": 5000, - "type": "string" - }, "metadata": { "anyOf": [ { @@ -34211,97 +75542,9 @@ ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "nationality": { - "description": "The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or \"XX\" if unavailable.", - "maxLength": 5000, - "type": "string" - }, - "person_token": { - "description": "A [person token](https://stripe.com/docs/connect/account-tokens), used to securely provide details to the person.", - "maxLength": 5000, - "type": "string" - }, - "phone": { - "description": "The person's phone number.", - "type": "string" - }, - "political_exposure": { - "description": "Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.", - "maxLength": 5000, - "type": "string" - }, - "relationship": { - "description": "The relationship that this person has with the account's legal entity.", - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "percent_ownership": { - "anyOf": [ - { - "type": "number" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "representative": { - "type": "boolean" - }, - "title": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "relationship_specs", - "type": "object" - }, - "ssn_last_4": { - "description": "The last four digits of the person's Social Security number (U.S. only).", - "type": "string" - }, - "verification": { - "description": "The person's verification status.", - "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - } - }, - "title": "person_verification_specs", - "type": "object" + "submit": { + "description": "Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).", + "type": "boolean" } }, "type": "object" @@ -34315,7 +75558,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/person" + "$ref": "#/components/schemas/dispute" } } }, @@ -34334,14 +75577,14 @@ } } }, - "/v1/accounts/{account}/reject": { + "/v1/disputes/{dispute}/close": { "post": { - "description": "

With Connect, you may flag accounts as suspicious.

\n\n

Test-mode Custom and Express accounts can be rejected at any time. Accounts created using live-mode keys may only be rejected once all balances are zero.

", - "operationId": "PostAccountsAccountReject", + "description": "

Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute, acknowledging it as lost.

\n\n

The status of the dispute will change from needs_response to lost. Closing a dispute is irreversible.

", + "operationId": "PostDisputesDisputeClose", "parameters": [ { "in": "path", - "name": "account", + "name": "dispute", "required": true, "schema": { "maxLength": 5000, @@ -34360,6 +75603,7 @@ } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -34368,26 +75612,20 @@ "type": "string" }, "type": "array" - }, - "reason": { - "description": "The reason for rejecting the account. Can be `fraud`, `terms_of_service`, or `other`.", - "maxLength": 5000, - "type": "string" } }, - "required": ["reason"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/account" + "$ref": "#/components/schemas/dispute" } } }, @@ -34406,19 +75644,215 @@ } } }, - "/v1/apple_pay/domains": { + "/v1/entitlements/active_entitlements": { "get": { - "description": "

List apple pay domains.

", - "operationId": "GetApplePayDomains", + "description": "

Retrieve a list of active entitlements for a customer

", + "operationId": "GetEntitlementsActiveEntitlements", "parameters": [ { + "description": "The ID of the customer.", "in": "query", - "name": "domain_name", + "name": "customer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/entitlements.active_entitlement" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "EntitlementsResourceCustomerEntitlementList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/entitlements/active_entitlements/{id}": { + "get": { + "description": "

Retrieve an active entitlement

", + "operationId": "GetEntitlementsActiveEntitlementsId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "The ID of the entitlement.", + "in": "path", + "name": "id", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/entitlements.active_entitlement" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/entitlements/features": { + "get": { + "description": "

Retrieve a list of features

", + "operationId": "GetEntitlementsFeatures", + "parameters": [ + { + "description": "If set, filter results to only include features with the given archive status.", + "in": "query", + "name": "archived", + "required": false, + "schema": { + "type": "boolean" + }, "style": "form" }, { @@ -34457,6 +75891,17 @@ }, "style": "form" }, + { + "description": "If set, filter results to only include features with the given lookup_key.", + "in": "query", + "name": "lookup_key", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -34474,6 +75919,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -34490,7 +75936,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/apple_pay_domain" + "$ref": "#/components/schemas/entitlements.feature" }, "type": "array" }, @@ -34506,12 +75952,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/apple_pay/domains", + "pattern": "^/v1/entitlements/features", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "ApplePayDomainList", + "title": "EntitlementsResourceFeatureList", "type": "object", "x-expandableFields": ["data"] } @@ -34532,8 +75978,164 @@ } }, "post": { - "description": "

Create an apple pay domain.

", - "operationId": "PostApplePayDomains", + "description": "

Creates a feature

", + "operationId": "PostEntitlementsFeatures", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "lookup_key": { + "description": "A unique key you provide as your own system identifier. This may be up to 80 characters.", + "maxLength": 80, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.", + "type": "object" + }, + "name": { + "description": "The feature's name, for your own purpose, not meant to be displayable to the customer.", + "maxLength": 80, + "type": "string" + } + }, + "required": ["lookup_key", "name"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/entitlements.feature" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/entitlements/features/{id}": { + "get": { + "description": "

Retrieves a feature

", + "operationId": "GetEntitlementsFeaturesId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "The ID of the feature.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/entitlements.feature" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Update a feature’s metadata or permanently deactivate it.

", + "operationId": "PostEntitlementsFeaturesId", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -34541,12 +76143,18 @@ "expand": { "explode": true, "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "domain_name": { - "type": "string" + "active": { + "description": "Inactive features cannot be attached to new products and will not be returned from the features list endpoint.", + "type": "boolean" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -34555,21 +76163,40 @@ "type": "string" }, "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format." + }, + "name": { + "description": "The feature's name, for your own purpose, not meant to be displayable to the customer.", + "maxLength": 80, + "type": "string" } }, - "required": ["domain_name"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/apple_pay_domain" + "$ref": "#/components/schemas/entitlements.feature" } } }, @@ -34588,28 +76215,51 @@ } } }, - "/v1/apple_pay/domains/{domain}": { - "delete": { - "description": "

Delete an apple pay domain.

", - "operationId": "DeleteApplePayDomainsDomain", - "parameters": [ - { - "in": "path", - "name": "domain", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], + "/v1/ephemeral_keys": { + "post": { + "description": "

Creates a short-lived API key for a given resource.

", + "operationId": "PostEphemeralKeys", "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "customer": { + "description": "The ID of the Customer you'd like to modify using the resulting ephemeral key.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "issuing_card": { + "description": "The ID of the Issuing Card you'd like to access using the resulting ephemeral key.", + "maxLength": 5000, + "type": "string" + }, + "nonce": { + "description": "A single-use token, created by Stripe.js, used for creating ephemeral keys for Issuing Cards without exchanging sensitive information.", + "maxLength": 5000, + "type": "string" + }, + "verification_session": { + "description": "The ID of the Identity VerificationSession you'd like to access using the resulting ephemeral key", + "maxLength": 5000, + "type": "string" + } + }, "type": "object" } } @@ -34621,7 +76271,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_apple_pay_domain" + "$ref": "#/components/schemas/ephemeral_key" } } }, @@ -34638,43 +76288,45 @@ "description": "Error response." } } - }, - "get": { - "description": "

Retrieve an apple pay domain.

", - "operationId": "GetApplePayDomainsDomain", + } + }, + "/v1/ephemeral_keys/{key}": { + "delete": { + "description": "

Invalidates a short-lived API key for a given resource.

", + "operationId": "DeleteEphemeralKeysKey", "parameters": [ { "in": "path", - "name": "domain", + "name": "key", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -34686,7 +76338,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/apple_pay_domain" + "$ref": "#/components/schemas/ephemeral_key" } } }, @@ -34705,23 +76357,13 @@ } } }, - "/v1/application_fees": { + "/v1/events": { "get": { - "description": "

Returns a list of application fees you’ve previously collected. The application fees are returned in sorted order, with the most recent fees appearing first.

", - "operationId": "GetApplicationFees", + "description": "

List events, going back up to 30 days. Each event data is rendered according to Stripe API version at its creation time, specified in event object api_version attribute (not according to your current Stripe API version or Stripe-Version header).

", + "operationId": "GetEvents", "parameters": [ { - "description": "Only return application fees for the charge specified by this charge ID.", - "in": "query", - "name": "charge", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { + "description": "Only return events that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -34753,6 +76395,16 @@ }, "style": "deepObject" }, + { + "description": "Filter events by whether all webhooks were successfully delivered. If false, events which are still pending or have failed all delivery attempts to a webhook endpoint will be returned.", + "in": "query", + "name": "delivery_success", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -34799,6 +76451,32 @@ "type": "string" }, "style": "form" + }, + { + "description": "A string containing a specific event name, or group of events using * as a wildcard. The list will be filtered to include only events with a matching event property.", + "in": "query", + "name": "type", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "An array of up to 20 strings containing specific event names. The list will be filtered to include only events with a matching event property. You may pass either `type` or `types`, but not both.", + "explode": true, + "in": "query", + "name": "types", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" } ], "requestBody": { @@ -34806,6 +76484,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -34822,7 +76501,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/application_fee" + "$ref": "#/components/schemas/event" }, "type": "array" }, @@ -34838,11 +76517,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/application_fees", + "pattern": "^/v1/events", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "NotificationEventList", "type": "object", "x-expandableFields": ["data"] } @@ -34863,10 +76543,10 @@ } } }, - "/v1/application_fees/{fee}/refunds/{id}": { + "/v1/events/{id}": { "get": { - "description": "

By default, you can see the 10 most recent refunds stored directly on the application fee object, but you can also retrieve details about a specific refund stored on the application fee.

", - "operationId": "GetApplicationFeesFeeRefundsId", + "description": "

Retrieves the details of an event if it was created in the last 30 days. Supply the unique identifier of the event, which you might have received in a webhook.

", + "operationId": "GetEventsId", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -34883,16 +76563,6 @@ }, "style": "deepObject" }, - { - "in": "path", - "name": "fee", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, { "in": "path", "name": "id", @@ -34909,6 +76579,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -34921,7 +76592,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/fee_refund" + "$ref": "#/components/schemas/event" } } }, @@ -34938,71 +76609,68 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates the specified application fee refund by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

This request only accepts metadata as an argument.

", - "operationId": "PostApplicationFeesFeeRefundsId", + } + }, + "/v1/exchange_rates": { + "get": { + "description": "

Returns a list of objects that contain the rates at which foreign currencies are converted to one another. Only shows the currencies for which Stripe supports.

", + "operationId": "GetExchangeRates", "parameters": [ { - "in": "path", - "name": "fee", - "required": true, + "description": "A cursor for use in pagination. `ending_before` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with the exchange rate for currency X your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" }, { - "in": "path", - "name": "id", - "required": true, + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and total number of supported payout currencies, and the default is the max.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with the exchange rate for currency X, your subsequent call can include `starting_after=X` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -35014,7 +76682,34 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/fee_refund" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/exchange_rate" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/exchange_rates", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ExchangeRateList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -35033,10 +76728,10 @@ } } }, - "/v1/application_fees/{id}": { + "/v1/exchange_rates/{rate_id}": { "get": { - "description": "

Retrieves the details of an application fee that your account has collected. The same information is returned when refunding the application fee.

", - "operationId": "GetApplicationFeesId", + "description": "

Retrieves the exchange rates from the given currency to every supported currency.

", + "operationId": "GetExchangeRatesRateId", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -35055,7 +76750,7 @@ }, { "in": "path", - "name": "id", + "name": "rate_id", "required": true, "schema": { "maxLength": 5000, @@ -35069,6 +76764,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -35081,7 +76777,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/application_fee" + "$ref": "#/components/schemas/exchange_rate" } } }, @@ -35100,91 +76796,50 @@ } } }, - "/v1/application_fees/{id}/refund": { - "post": { - "description": "", - "operationId": "PostApplicationFeesIdRefund", + "/v1/file_links": { + "get": { + "description": "

Returns a list of file links.

", + "operationId": "GetFileLinks", "parameters": [ { - "in": "path", - "name": "id", - "required": true, + "description": "Only return links that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "amount": { - "type": "integer" - }, - "directive": { - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" }, - "type": "array" - } + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/application_fee" + { + "type": "integer" } - } + ] }, - "description": "Successful response." + "style": "deepObject" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/application_fees/{id}/refunds": { - "get": { - "description": "

You can see a list of the refunds belonging to a specific application fee. Note that the 10 most recent refunds are always available by default on the application fee object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional refunds.

", - "operationId": "GetApplicationFeesIdRefunds", - "parameters": [ { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", "name": "ending_before", "required": false, "schema": { - "maxLength": 5000, "type": "string" }, "style": "form" @@ -35205,14 +76860,25 @@ "style": "deepObject" }, { - "in": "path", - "name": "id", - "required": true, + "description": "Filter links by their expiration status. By default, Stripe returns all links.", + "in": "query", + "name": "expired", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "Only return links for the given file.", + "in": "query", + "name": "file", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" }, { "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", @@ -35230,7 +76896,6 @@ "name": "starting_after", "required": false, "schema": { - "maxLength": 5000, "type": "string" }, "style": "form" @@ -35241,6 +76906,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -35258,7 +76924,7 @@ "data": { "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/fee_refund" + "$ref": "#/components/schemas/file_link" }, "type": "array" }, @@ -35274,11 +76940,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, + "pattern": "^/v1/file_links", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "FeeRefundList", + "title": "FileResourceFileLinkList", "type": "object", "x-expandableFields": ["data"] } @@ -35294,25 +76961,13 @@ } } }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Refunds an application fee that has previously been collected but not yet refunded.\nFunds will be refunded to the Stripe account from which the fee was originally collected.

\n\n

You can optionally refund only part of an application fee.\nYou can do so multiple times, until the entire fee has been refunded.

\n\n

Once entirely refunded, an application fee can’t be refunded again.\nThis method will raise an error when called on an already-refunded application fee,\nor when trying to refund more money than is left on an application fee.

", - "operationId": "PostApplicationFeesIdRefunds", - "parameters": [ - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" + "description": "Error response." } - ], + } + }, + "post": { + "description": "

Creates a new file link object.

", + "operationId": "PostFileLinks", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -35327,11 +76982,8 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "amount": { - "description": "A positive integer, in _%s_, representing how much of this fee to refund. Can refund only up to the remaining unrefunded amount of the fee.", - "type": "integer" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -35340,26 +76992,45 @@ }, "type": "array" }, + "expires_at": { + "description": "The link isn't usable after this future timestamp.", + "format": "unix-time", + "type": "integer" + }, + "file": { + "description": "The ID of the file. The file's `purpose` must be one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `identity_document_downloadable`, `issuing_regulatory_reporting`, `pci_document`, `selfie`, `sigma_scheduled_query`, `tax_document_user_upload`, or `terminal_reader_splashscreen`.", + "maxLength": 5000, + "type": "string" + }, "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." } }, + "required": ["file"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/fee_refund" + "$ref": "#/components/schemas/file_link" } } }, @@ -35378,10 +77049,10 @@ } } }, - "/v1/balance": { + "/v1/file_links/{link}": { "get": { - "description": "

Retrieves the current account balance, based on the authentication that was used to make the request.\n For a sample request, see Accounting for negative balances.

", - "operationId": "GetBalance", + "description": "

Retrieves the file link with the given ID.

", + "operationId": "GetFileLinksLink", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -35397,6 +77068,15 @@ "type": "array" }, "style": "deepObject" + }, + { + "in": "path", + "name": "link", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" } ], "requestBody": { @@ -35404,6 +77084,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -35416,7 +77097,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/balance" + "$ref": "#/components/schemas/file_link" } } }, @@ -35433,46 +77114,120 @@ "description": "Error response." } } - } - }, - "/v1/balance/history": { - "get": { - "description": "

Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.

\n\n

Note that this endpoint was previously called “Balance history” and used the path /v1/balance/history.

", - "operationId": "GetBalanceHistory", + }, + "post": { + "description": "

Updates an existing file link object. Expired links can no longer be updated.

", + "operationId": "PostFileLinksLink", "parameters": [ { - "explode": true, - "in": "query", - "name": "available_on", - "required": false, + "in": "path", + "name": "link", + "required": true, "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "expires_at": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "lte": { - "type": "integer" - } + "type": "array" }, - "title": "range_query_specs", - "type": "object" + "expires_at": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A future timestamp after which the link will no longer be usable, or `now` to expire the link immediately." + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } }, - { - "type": "integer" + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/file_link" } - ] + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/files": { + "get": { + "description": "

Returns a list of the files that your account has access to. Stripe sorts and returns the files by their creation dates, placing the most recently created files at the top.

", + "operationId": "GetFiles", + "parameters": [ { + "description": "Only return files that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -35504,16 +77259,6 @@ }, "style": "deepObject" }, - { - "description": "Only return transactions in a certain currency. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "in": "query", - "name": "currency", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -35551,24 +77296,32 @@ "style": "form" }, { - "description": "For automatic Stripe payouts only, only returns transactions that were paid out on the specified payout ID.", - "in": "query", - "name": "payout", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only returns the original transaction.", + "description": "Filter queries by the file purpose. If you don't provide a purpose, the queries return unfiltered files.", "in": "query", - "name": "source", + "name": "purpose", "required": false, "schema": { + "enum": [ + "account_requirement", + "additional_verification", + "business_icon", + "business_logo", + "customer_signature", + "dispute_evidence", + "document_provider_identity_document", + "finance_report_run", + "identity_document", + "identity_document_downloadable", + "issuing_regulatory_reporting", + "pci_document", + "selfie", + "sigma_scheduled_query", + "tax_document_user_upload", + "terminal_reader_splashscreen" + ], "maxLength": 5000, - "type": "string" + "type": "string", + "x-stripeBypassValidation": true }, "style": "form" }, @@ -35582,17 +77335,6 @@ "type": "string" }, "style": "form" - }, - { - "description": "Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.", - "in": "query", - "name": "type", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" } ], "requestBody": { @@ -35600,6 +77342,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -35616,7 +77359,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/file" }, "type": "array" }, @@ -35632,12 +77375,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/balance_transactions", + "pattern": "^/v1/files", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "BalanceTransactionsList", + "title": "FileResourceFileList", "type": "object", "x-expandableFields": ["data"] } @@ -35656,12 +77399,127 @@ "description": "Error response." } } + }, + "post": { + "description": "

To upload a file to Stripe, you need to send a request of type multipart/form-data. Include the file you want to upload in the request, and the parameters for creating a file.

\n\n

All of Stripe’s officially supported Client libraries support sending multipart/form-data.

", + "operationId": "PostFiles", + "requestBody": { + "content": { + "multipart/form-data": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "file_link_data": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "file": { + "description": "A file to upload. Make sure that the specifications follow RFC 2388, which defines file transfers for the `multipart/form-data` protocol.", + "format": "binary", + "type": "string" + }, + "file_link_data": { + "description": "Optional parameters that automatically create a [file link](https://stripe.com/docs/api#file_links) for the newly created file.", + "properties": { + "create": { + "type": "boolean" + }, + "expires_at": { + "format": "unix-time", + "type": "integer" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "required": ["create"], + "title": "file_link_creation_params", + "type": "object" + }, + "purpose": { + "description": "The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.", + "enum": [ + "account_requirement", + "additional_verification", + "business_icon", + "business_logo", + "customer_signature", + "dispute_evidence", + "identity_document", + "issuing_regulatory_reporting", + "pci_document", + "tax_document_user_upload", + "terminal_reader_splashscreen" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["file", "purpose"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/file" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + }, + "servers": [ + { + "url": "https://files.stripe.com/" + } + ] } }, - "/v1/balance/history/{id}": { + "/v1/files/{file}": { "get": { - "description": "

Retrieves the balance transaction with the given ID.

\n\n

Note that this endpoint previously used the path /v1/balance/history/:id.

", - "operationId": "GetBalanceHistoryId", + "description": "

Retrieves the details of an existing file object. After you supply a unique file ID, Stripe returns the corresponding file object. Learn how to access file contents.

", + "operationId": "GetFilesFile", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -35680,7 +77538,7 @@ }, { "in": "path", - "name": "id", + "name": "file", "required": true, "schema": { "maxLength": 5000, @@ -35694,6 +77552,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -35706,7 +77565,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/file" } } }, @@ -35725,85 +77584,33 @@ } } }, - "/v1/balance_transactions": { + "/v1/financial_connections/accounts": { "get": { - "description": "

Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.

\n\n

Note that this endpoint was previously called “Balance history” and used the path /v1/balance/history.

", - "operationId": "GetBalanceTransactions", + "description": "

Returns a list of Financial Connections Account objects.

", + "operationId": "GetFinancialConnectionsAccounts", "parameters": [ { + "description": "If present, only return accounts that belong to the specified account holder. `account_holder[customer]` and `account_holder[account]` are mutually exclusive.", "explode": true, "in": "query", - "name": "available_on", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "explode": true, - "in": "query", - "name": "created", + "name": "account_holder", "required": false, "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" + "properties": { + "account": { + "maxLength": 5000, + "type": "string" }, - { - "type": "integer" + "customer": { + "maxLength": 5000, + "type": "string" } - ] + }, + "title": "accountholder_params", + "type": "object" }, "style": "deepObject" }, - { - "description": "Only return transactions in a certain currency. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "in": "query", - "name": "currency", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -35841,20 +77648,9 @@ "style": "form" }, { - "description": "For automatic Stripe payouts only, only returns transactions that were paid out on the specified payout ID.", - "in": "query", - "name": "payout", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only returns the original transaction.", + "description": "If present, only return accounts that were collected as part of the given session.", "in": "query", - "name": "source", + "name": "session", "required": false, "schema": { "maxLength": 5000, @@ -35872,17 +77668,6 @@ "type": "string" }, "style": "form" - }, - { - "description": "Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.", - "in": "query", - "name": "type", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" } ], "requestBody": { @@ -35890,6 +77675,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -35905,8 +77691,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/financial_connections.account" }, "type": "array" }, @@ -35922,12 +77709,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/balance_transactions", + "pattern": "^/v1/financial_connections/accounts", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "BalanceTransactionsList", + "title": "BankConnectionsResourceLinkedAccountList", "type": "object", "x-expandableFields": ["data"] } @@ -35948,11 +77735,21 @@ } } }, - "/v1/balance_transactions/{id}": { + "/v1/financial_connections/accounts/{account}": { "get": { - "description": "

Retrieves the balance transaction with the given ID.

\n\n

Note that this endpoint previously used the path /v1/balance/history/:id.

", - "operationId": "GetBalanceTransactionsId", + "description": "

Retrieves the details of an Financial Connections Account.

", + "operationId": "GetFinancialConnectionsAccountsAccount", "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -35967,10 +77764,53 @@ "type": "array" }, "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/financial_connections.account" + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/financial_connections/accounts/{account}/disconnect": { + "post": { + "description": "

Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions).

", + "operationId": "PostFinancialConnectionsAccountsAccountDisconnect", + "parameters": [ { "in": "path", - "name": "id", + "name": "account", "required": true, "schema": { "maxLength": 5000, @@ -35982,9 +77822,24 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -35996,7 +77851,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/balance_transaction" + "$ref": "#/components/schemas/financial_connections.account" } } }, @@ -36015,20 +77870,20 @@ } } }, - "/v1/billing_portal/configurations": { + "/v1/financial_connections/accounts/{account}/owners": { "get": { - "description": "

Returns a list of configurations that describe the functionality of the customer portal.

", - "operationId": "GetBillingPortalConfigurations", + "description": "

Lists all owners for a given Account

", + "operationId": "GetFinancialConnectionsAccountsAccountOwners", "parameters": [ { - "description": "Only return configurations that are active or inactive (e.g., pass `true` to only list active configurations).", - "in": "query", - "name": "active", - "required": false, + "in": "path", + "name": "account", + "required": true, "schema": { - "type": "boolean" + "maxLength": 5000, + "type": "string" }, - "style": "form" + "style": "simple" }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", @@ -36057,22 +77912,23 @@ "style": "deepObject" }, { - "description": "Only return the default or non-default configurations (e.g., pass `true` to only list the default configuration).", + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", - "name": "is_default", + "name": "limit", "required": false, "schema": { - "type": "boolean" + "type": "integer" }, "style": "form" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "description": "The ID of the ownership object to fetch owners from.", "in": "query", - "name": "limit", - "required": false, + "name": "ownership", + "required": true, "schema": { - "type": "integer" + "maxLength": 5000, + "type": "string" }, "style": "form" }, @@ -36093,6 +77949,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -36108,8 +77965,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/billing_portal.configuration" + "$ref": "#/components/schemas/financial_connections.account_owner" }, "type": "array" }, @@ -36125,11 +77983,11 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/billing_portal/configurations", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "BankConnectionsResourceOwnerList", "type": "object", "x-expandableFields": ["data"] } @@ -36148,22 +78006,28 @@ "description": "Error response." } } - }, + } + }, + "/v1/financial_connections/accounts/{account}/refresh": { "post": { - "description": "

Creates a configuration that describes the functionality and behavior of a PortalSession

", - "operationId": "PostBillingPortalConfigurations", + "description": "

Refreshes the data associated with a Financial Connections Account.

", + "operationId": "PostFinancialConnectionsAccountsAccountRefresh", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "business_profile": { - "explode": true, - "style": "deepObject" - }, - "default_return_url": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" @@ -36174,37 +78038,8 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "business_profile": { - "description": "The business information shown to customers in the portal.", - "properties": { - "headline": { - "maxLength": 60, - "type": "string" - }, - "privacy_policy_url": { - "type": "string" - }, - "terms_of_service_url": { - "type": "string" - } - }, - "required": ["privacy_policy_url", "terms_of_service_url"], - "title": "business_profile_create_param", - "type": "object" - }, - "default_return_url": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session." - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -36214,157 +78049,16 @@ "type": "array" }, "features": { - "description": "Information about the features available in the portal.", - "properties": { - "customer_update": { - "properties": { - "allowed_updates": { - "anyOf": [ - { - "items": { - "enum": [ - "address", - "email", - "phone", - "shipping", - "tax_id" - ], - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "enabled": { - "type": "boolean" - } - }, - "required": ["allowed_updates", "enabled"], - "title": "customer_update_creation_param", - "type": "object" - }, - "invoice_history": { - "properties": { - "enabled": { - "type": "boolean" - } - }, - "required": ["enabled"], - "title": "invoice_list_param", - "type": "object" - }, - "payment_method_update": { - "properties": { - "enabled": { - "type": "boolean" - } - }, - "required": ["enabled"], - "title": "payment_method_update_param", - "type": "object" - }, - "subscription_cancel": { - "properties": { - "enabled": { - "type": "boolean" - }, - "mode": { - "enum": ["at_period_end", "immediately"], - "type": "string" - }, - "proration_behavior": { - "enum": [ - "always_invoice", - "create_prorations", - "none" - ], - "type": "string" - } - }, - "required": ["enabled"], - "title": "subscription_cancel_creation_param", - "type": "object" - }, - "subscription_update": { - "properties": { - "default_allowed_updates": { - "anyOf": [ - { - "items": { - "enum": [ - "price", - "promotion_code", - "quantity" - ], - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "enabled": { - "type": "boolean" - }, - "products": { - "anyOf": [ - { - "items": { - "properties": { - "prices": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "product": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["prices", "product"], - "title": "subscription_update_product_param", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "proration_behavior": { - "enum": [ - "always_invoice", - "create_prorations", - "none" - ], - "type": "string" - } - }, - "required": [ - "default_allowed_updates", - "enabled", - "products" - ], - "title": "subscription_update_creation_param", - "type": "object" - } + "description": "The list of account features that you would like to refresh.", + "items": { + "enum": ["balance", "ownership", "transactions"], + "type": "string", + "x-stripeBypassValidation": true }, - "title": "features_creation_param", - "type": "object" + "type": "array" } }, - "required": ["business_profile", "features"], + "required": ["features"], "type": "object" } } @@ -36376,7 +78070,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/billing_portal.configuration" + "$ref": "#/components/schemas/financial_connections.account" } } }, @@ -36395,79 +78089,14 @@ } } }, - "/v1/billing_portal/configurations/{configuration}": { - "get": { - "description": "

Retrieves a configuration that describes the functionality of the customer portal.

", - "operationId": "GetBillingPortalConfigurationsConfiguration", - "parameters": [ - { - "in": "path", - "name": "configuration", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/billing_portal.configuration" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, + "/v1/financial_connections/accounts/{account}/subscribe": { "post": { - "description": "

Updates a configuration that describes the functionality of the customer portal.

", - "operationId": "PostBillingPortalConfigurationsConfiguration", + "description": "

Subscribes to periodic refreshes of data associated with a Financial Connections Account.

", + "operationId": "PostFinancialConnectionsAccountsAccountSubscribe", "parameters": [ { "in": "path", - "name": "configuration", + "name": "account", "required": true, "schema": { "maxLength": 5000, @@ -36480,14 +78109,6 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "business_profile": { - "explode": true, - "style": "deepObject" - }, - "default_return_url": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" @@ -36498,204 +78119,39 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Whether the configuration is active and can be used to create portal sessions.", - "type": "boolean" - }, - "business_profile": { - "description": "The business information shown to customers in the portal.", - "properties": { - "headline": { - "maxLength": 60, - "type": "string" - }, - "privacy_policy_url": { - "type": "string" - }, - "terms_of_service_url": { - "type": "string" - } - }, - "title": "business_profile_update_param", - "type": "object" - }, - "default_return_url": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session." - }, "expand": { "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "features": { - "description": "Information about the features available in the portal.", - "properties": { - "customer_update": { - "properties": { - "allowed_updates": { - "anyOf": [ - { - "items": { - "enum": [ - "address", - "email", - "phone", - "shipping", - "tax_id" - ], - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "enabled": { - "type": "boolean" - } - }, - "title": "customer_update_updating_param", - "type": "object" - }, - "invoice_history": { - "properties": { - "enabled": { - "type": "boolean" - } - }, - "required": ["enabled"], - "title": "invoice_list_param", - "type": "object" - }, - "payment_method_update": { - "properties": { - "enabled": { - "type": "boolean" - } - }, - "required": ["enabled"], - "title": "payment_method_update_param", - "type": "object" - }, - "subscription_cancel": { - "properties": { - "enabled": { - "type": "boolean" - }, - "mode": { - "enum": ["at_period_end", "immediately"], - "type": "string" - }, - "proration_behavior": { - "enum": [ - "always_invoice", - "create_prorations", - "none" - ], - "type": "string" - } - }, - "title": "subscription_cancel_updating_param", - "type": "object" - }, - "subscription_update": { - "properties": { - "default_allowed_updates": { - "anyOf": [ - { - "items": { - "enum": [ - "price", - "promotion_code", - "quantity" - ], - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "enabled": { - "type": "boolean" - }, - "products": { - "anyOf": [ - { - "items": { - "properties": { - "prices": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "product": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["prices", "product"], - "title": "subscription_update_product_param", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "proration_behavior": { - "enum": [ - "always_invoice", - "create_prorations", - "none" - ], - "type": "string" - } - }, - "title": "subscription_update_updating_param", - "type": "object" - } + "items": { + "maxLength": 5000, + "type": "string" }, - "title": "features_updating_param", - "type": "object" + "type": "array" + }, + "features": { + "description": "The list of account features to which you would like to subscribe.", + "items": { + "enum": ["transactions"], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" } }, + "required": ["features"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/billing_portal.configuration" + "$ref": "#/components/schemas/financial_connections.account" } } }, @@ -36714,10 +78170,22 @@ } } }, - "/v1/billing_portal/sessions": { + "/v1/financial_connections/accounts/{account}/unsubscribe": { "post": { - "description": "

Creates a session of the customer portal.

", - "operationId": "PostBillingPortalSessions", + "description": "

Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.

", + "operationId": "PostFinancialConnectionsAccountsAccountUnsubscribe", + "parameters": [ + { + "in": "path", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -36725,19 +78193,115 @@ "expand": { "explode": true, "style": "deepObject" + }, + "features": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "configuration": { - "description": "The [configuration](https://stripe.com/docs/api/customer_portal/configuration) to use for this session, describing its functionality and features. If not specified, the session uses the default configuration.", - "maxLength": 5000, - "type": "string" + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "customer": { - "description": "The ID of an existing customer.", - "maxLength": 5000, - "type": "string" + "features": { + "description": "The list of account features from which you would like to unsubscribe.", + "items": { + "enum": ["transactions"], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + } + }, + "required": ["features"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/financial_connections.account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/financial_connections/sessions": { + "post": { + "description": "

To launch the Financial Connections authorization flow, create a Session. The session’s client_secret can be used to launch the flow using Stripe.js.

", + "operationId": "PostFinancialConnectionsSessions", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "account_holder": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "filters": { + "explode": true, + "style": "deepObject" + }, + "permissions": { + "explode": true, + "style": "deepObject" + }, + "prefetch": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account_holder": { + "description": "The account holder to link accounts for.", + "properties": { + "account": { + "maxLength": 5000, + "type": "string" + }, + "customer": { + "maxLength": 5000, + "type": "string" + }, + "type": { + "enum": ["account", "customer"], + "type": "string" + } + }, + "required": ["type"], + "title": "accountholder_params", + "type": "object" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -36747,16 +78311,64 @@ }, "type": "array" }, - "on_behalf_of": { - "description": "The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/charges-transfers#on-behalf-of). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.", - "type": "string" + "filters": { + "description": "Filters to restrict the kinds of accounts to collect.", + "properties": { + "account_subcategories": { + "items": { + "enum": [ + "checking", + "credit_card", + "line_of_credit", + "mortgage", + "savings" + ], + "type": "string" + }, + "type": "array" + }, + "countries": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "title": "filters_params", + "type": "object" + }, + "permissions": { + "description": "List of data features that you would like to request access to.\n\nPossible values are `balances`, `transactions`, `ownership`, and `payment_method`.", + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "description": "List of data features that you would like to retrieve upon account creation.", + "items": { + "enum": ["balances", "ownership", "transactions"], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" }, "return_url": { - "description": "The default URL to redirect customers to when they click on the portal's link to return to your website.", + "description": "For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.", + "maxLength": 5000, "type": "string" } }, - "required": ["customer"], + "required": ["account_holder", "permissions"], "type": "object" } } @@ -36768,7 +78380,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/billing_portal.session" + "$ref": "#/components/schemas/financial_connections.session" } } }, @@ -36787,19 +78399,87 @@ } } }, - "/v1/bitcoin/receivers": { + "/v1/financial_connections/sessions/{session}": { "get": { - "deprecated": true, - "description": "

Returns a list of your receivers. Receivers are returned sorted by creation date, with the most recently created receivers appearing first.

", - "operationId": "GetBitcoinReceivers", + "description": "

Retrieves the details of a Financial Connections Session

", + "operationId": "GetFinancialConnectionsSessionsSession", "parameters": [ { - "description": "Filter for active receivers.", + "description": "Specifies which fields in the response should be expanded.", + "explode": true, "in": "query", - "name": "active", + "name": "expand", "required": false, "schema": { - "type": "boolean" + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "session", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/financial_connections.session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/financial_connections/transactions": { + "get": { + "description": "

Returns a list of Financial Connections Transaction objects.

", + "operationId": "GetFinancialConnectionsTransactions", + "parameters": [ + { + "description": "The ID of the Stripe account whose transactions will be retrieved.", + "in": "query", + "name": "account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" }, "style": "form" }, @@ -36829,16 +78509,6 @@ }, "style": "deepObject" }, - { - "description": "Filter for filled receivers.", - "in": "query", - "name": "filled", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, { "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", @@ -36861,14 +78531,56 @@ "style": "form" }, { - "description": "Filter for receivers with uncaptured funds.", + "description": "A filter on the list based on the object `transacted_at` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with the following options:", + "explode": true, "in": "query", - "name": "uncaptured_funds", + "name": "transacted_at", "required": false, "schema": { - "type": "boolean" + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] }, - "style": "form" + "style": "deepObject" + }, + { + "description": "A filter on the list based on the object `transaction_refresh` field. The value can be a dictionary with the following options:", + "explode": true, + "in": "query", + "name": "transaction_refresh", + "required": false, + "schema": { + "properties": { + "after": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["after"], + "title": "transaction_refresh_params", + "type": "object" + }, + "style": "deepObject" } ], "requestBody": { @@ -36876,6 +78588,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -36891,8 +78604,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/bitcoin_receiver" + "$ref": "#/components/schemas/financial_connections.transaction" }, "type": "array" }, @@ -36908,11 +78622,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/bitcoin/receivers", + "pattern": "^/v1/financial_connections/transactions", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "BankConnectionsResourceTransactionList", "type": "object", "x-expandableFields": ["data"] } @@ -36933,11 +78648,10 @@ } } }, - "/v1/bitcoin/receivers/{id}": { + "/v1/financial_connections/transactions/{transaction}": { "get": { - "deprecated": true, - "description": "

Retrieves the Bitcoin receiver with the given ID.

", - "operationId": "GetBitcoinReceiversId", + "description": "

Retrieves the details of a Financial Connections Transaction

", + "operationId": "GetFinancialConnectionsTransactionsTransaction", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -36956,7 +78670,7 @@ }, { "in": "path", - "name": "id", + "name": "transaction", "required": true, "schema": { "maxLength": 5000, @@ -36970,6 +78684,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -36982,7 +78697,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/bitcoin_receiver" + "$ref": "#/components/schemas/financial_connections.transaction" } } }, @@ -37001,25 +78716,39 @@ } } }, - "/v1/bitcoin/receivers/{receiver}/transactions": { + "/v1/forwarding/requests": { "get": { - "deprecated": true, - "description": "

List bitcoin transacitons for a given receiver.

", - "operationId": "GetBitcoinReceiversReceiverTransactions", + "description": "

Lists all ForwardingRequest objects.

", + "operationId": "GetForwardingRequests", "parameters": [ { - "description": "Only return transactions for the customer specified by this customer ID.", + "description": "Similar to other List endpoints, filters results based on created timestamp. You can pass gt, gte, lt, and lte timestamp values.", + "explode": true, "in": "query", - "name": "customer", + "name": "created", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "created_param", + "type": "object" }, - "style": "form" + "style": "deepObject" }, { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "description": "A pagination cursor to fetch the previous page of the list. The value must be a ForwardingRequest ID.", "in": "query", "name": "ending_before", "required": false, @@ -37055,17 +78784,7 @@ "style": "form" }, { - "in": "path", - "name": "receiver", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "A pagination cursor to fetch the next page of the list. The value must be a ForwardingRequest ID.", "in": "query", "name": "starting_after", "required": false, @@ -37081,6 +78800,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -37093,12 +78813,11 @@ "content": { "application/json": { "schema": { - "description": "", + "description": "List of ForwardingRequest data.", "properties": { "data": { - "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/bitcoin_transaction" + "$ref": "#/components/schemas/forwarding.request" }, "type": "array" }, @@ -37118,7 +78837,7 @@ } }, "required": ["data", "has_more", "object", "url"], - "title": "BitcoinTransactionList", + "title": "ForwardingRequestList", "type": "object", "x-expandableFields": ["data"] } @@ -37137,36 +78856,127 @@ "description": "Error response." } } + }, + "post": { + "description": "

Creates a ForwardingRequest object.

", + "operationId": "PostForwardingRequests", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "replacements": { + "explode": true, + "style": "deepObject" + }, + "request": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "payment_method": { + "description": "The PaymentMethod to insert into the forwarded request. Forwarding previously consumed PaymentMethods is allowed.", + "maxLength": 5000, + "type": "string" + }, + "replacements": { + "description": "The field kinds to be replaced in the forwarded request.", + "items": { + "enum": [ + "card_cvc", + "card_expiry", + "card_number", + "cardholder_name" + ], + "type": "string" + }, + "type": "array" + }, + "request": { + "description": "The request body and headers to be sent to the destination endpoint.", + "properties": { + "body": { + "maxLength": 5000, + "type": "string" + }, + "headers": { + "items": { + "properties": { + "name": { + "maxLength": 5000, + "type": "string" + }, + "value": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["name", "value"], + "title": "header_param", + "type": "object" + }, + "type": "array" + } + }, + "title": "request_param", + "type": "object" + }, + "url": { + "description": "The destination URL for the forwarded request. Must be supported by the config.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["payment_method", "replacements", "url"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/forwarding.request" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } } }, - "/v1/bitcoin/transactions": { + "/v1/forwarding/requests/{id}": { "get": { - "deprecated": true, - "description": "

List bitcoin transacitons for a given receiver.

", - "operationId": "GetBitcoinTransactions", + "description": "

Retrieves a ForwardingRequest object.

", + "operationId": "GetForwardingRequestsId", "parameters": [ - { - "description": "Only return transactions for the customer specified by this customer ID.", - "in": "query", - "name": "customer", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -37183,35 +78993,14 @@ "style": "deepObject" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "in": "query", - "name": "receiver", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, + "in": "path", + "name": "id", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" } ], "requestBody": { @@ -37219,6 +79008,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -37231,34 +79021,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/bitcoin_transaction" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "BitcoinTransactionList", - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/forwarding.request" } } }, @@ -37277,12 +79040,24 @@ } } }, - "/v1/charges": { + "/v1/identity/verification_reports": { "get": { - "description": "

Returns a list of charges you’ve previously created. The charges are returned in sorted order, with the most recent charges appearing first.

", - "operationId": "GetCharges", + "description": "

List all verification reports.

", + "operationId": "GetIdentityVerificationReports", "parameters": [ { + "description": "A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.", + "in": "query", + "name": "client_reference_id", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return VerificationReports that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -37314,23 +79089,13 @@ }, "style": "deepObject" }, - { - "description": "Only return charges for the customer specified by this customer ID.", - "in": "query", - "name": "customer", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", "name": "ending_before", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" @@ -37361,9 +79126,9 @@ "style": "form" }, { - "description": "Only return charges that were created by the PaymentIntent specified by this PaymentIntent ID.", + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", - "name": "payment_intent", + "name": "starting_after", "required": false, "schema": { "maxLength": 5000, @@ -37372,19 +79137,21 @@ "style": "form" }, { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "Only return VerificationReports of this type", "in": "query", - "name": "starting_after", + "name": "type", "required": false, "schema": { - "type": "string" + "enum": ["document", "id_number"], + "type": "string", + "x-stripeBypassValidation": true }, "style": "form" }, { - "description": "Only return charges for this transfer group.", + "description": "Only return VerificationReports created by this VerificationSession ID. It is allowed to provide a VerificationIntent ID.", "in": "query", - "name": "transfer_group", + "name": "verification_session", "required": false, "schema": { "maxLength": 5000, @@ -37398,6 +79165,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -37414,7 +79182,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/identity.verification_report" }, "type": "array" }, @@ -37430,11 +79198,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/charges", + "pattern": "^/v1/identity/verification_reports", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "GelatoVerificationReportList", "type": "object", "x-expandableFields": ["data"] } @@ -37453,329 +79222,13 @@ "description": "Error response." } } - }, - "post": { - "description": "

To charge a credit card or other payment source, you create a Charge object. If your API key is in test mode, the supplied payment source (e.g., card) won’t actually be charged, although everything else will occur as if in live mode. (Stripe assumes that the charge would have completed successfully).

", - "operationId": "PostCharges", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "card": { - "explode": true, - "style": "deepObject" - }, - "destination": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "shipping": { - "explode": true, - "style": "deepObject" - }, - "transfer_data": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "amount": { - "description": "Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", - "type": "integer" - }, - "application_fee": { - "type": "integer" - }, - "application_fee_amount": { - "description": "A fee in %s that will be applied to the charge and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the `Stripe-Account` header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/connect/direct-charges#collecting-fees).", - "type": "integer" - }, - "capture": { - "description": "Whether to immediately capture the charge. Defaults to `true`. When `false`, the charge issues an authorization (or pre-authorization), and will need to be [captured](https://stripe.com/docs/api#capture_charge) later. Uncaptured charges expire in _seven days_. For more information, see the [authorizing charges and settling later](https://stripe.com/docs/charges/placing-a-hold) documentation.", - "type": "boolean" - }, - "card": { - "anyOf": [ - { - "properties": { - "address_city": { - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "maxLength": 5000, - "type": "string" - }, - "cvc": { - "maxLength": 5000, - "type": "string" - }, - "exp_month": { - "type": "integer" - }, - "exp_year": { - "type": "integer" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "number": { - "maxLength": 5000, - "type": "string" - }, - "object": { - "enum": ["card"], - "maxLength": 5000, - "type": "string" - } - }, - "required": ["exp_month", "exp_year", "number"], - "title": "customer_payment_source_card", - "type": "object" - }, - { - "maxLength": 5000, - "type": "string" - } - ], - "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js).", - "x-stripeBypassValidation": true - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "customer": { - "description": "The ID of an existing customer that will be charged in this request.", - "maxLength": 500, - "type": "string" - }, - "description": { - "description": "An arbitrary string which you can attach to a `Charge` object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.", - "maxLength": 40000, - "type": "string" - }, - "destination": { - "anyOf": [ - { - "properties": { - "account": { - "maxLength": 5000, - "type": "string" - }, - "amount": { - "type": "integer" - } - }, - "required": ["account"], - "title": "destination_specs", - "type": "object" - }, - { - "type": "string" - } - ] - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "on_behalf_of": { - "description": "The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/charges-transfers#on-behalf-of).", - "maxLength": 5000, - "type": "string" - }, - "receipt_email": { - "description": "The email address to which this charge's [receipt](https://stripe.com/docs/dashboard/receipts) will be sent. The receipt will not be sent until the charge is paid, and no receipts will be sent for test mode charges. If this charge is for a [Customer](https://stripe.com/docs/api/customers/object), the email address specified here will override the customer's email address. If `receipt_email` is specified for a charge in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).", - "type": "string" - }, - "shipping": { - "description": "Shipping information for the charge. Helps prevent fraud on charges for physical goods.", - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["line1"], - "title": "address", - "type": "object" - }, - "carrier": { - "maxLength": 5000, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - }, - "tracking_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["address", "name"], - "title": "shipping", - "type": "object" - }, - "source": { - "description": "A payment source to be charged. This can be the ID of a [card](https://stripe.com/docs/api#cards) (i.e., credit or debit card), a [bank account](https://stripe.com/docs/api#bank_accounts), a [source](https://stripe.com/docs/api#sources), a [token](https://stripe.com/docs/api#tokens), or a [connected account](https://stripe.com/docs/connect/account-debits#charging-a-connected-account). For certain sources---namely, [cards](https://stripe.com/docs/api#cards), [bank accounts](https://stripe.com/docs/api#bank_accounts), and attached [sources](https://stripe.com/docs/api#sources)---you must also pass the ID of the associated customer.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "statement_descriptor": { - "description": "For card charges, use `statement_descriptor_suffix` instead. Otherwise, you can use this value as the complete description of a charge on your customers’ statements. Must contain at least one letter, maximum 22 characters.", - "maxLength": 22, - "type": "string" - }, - "statement_descriptor_suffix": { - "description": "Provides information about the charge that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.", - "maxLength": 22, - "type": "string" - }, - "transfer_data": { - "description": "An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.", - "properties": { - "amount": { - "type": "integer" - }, - "destination": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["destination"], - "title": "transfer_data_specs", - "type": "object" - }, - "transfer_group": { - "description": "A string that identifies this transaction as part of a group. For details, see [Grouping transactions](https://stripe.com/docs/connect/charges-transfers#transfer-options).", - "type": "string" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/charge" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } } }, - "/v1/charges/{charge}": { + "/v1/identity/verification_reports/{report}": { "get": { - "description": "

Retrieves the details of a charge that has previously been created. Supply the unique charge ID that was returned from your previous request, and Stripe will return the corresponding charge information. The same information is returned when creating or refunding the charge.

", - "operationId": "GetChargesCharge", + "description": "

Retrieves an existing VerificationReport

", + "operationId": "GetIdentityVerificationReportsReport", "parameters": [ - { - "in": "path", - "name": "charge", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -37790,6 +79243,16 @@ "type": "array" }, "style": "deepObject" + }, + { + "in": "path", + "name": "report", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" } ], "requestBody": { @@ -37797,6 +79260,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -37809,7 +79273,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/identity.verification_report" } } }, @@ -37826,156 +79290,133 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostChargesCharge", + } + }, + "/v1/identity/verification_sessions": { + "get": { + "description": "

Returns a list of VerificationSessions

", + "operationId": "GetIdentityVerificationSessions", "parameters": [ { - "in": "path", - "name": "charge", - "required": true, + "description": "A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.", + "in": "query", + "name": "client_reference_id", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "fraud_details": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "shipping": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "customer": { - "description": "The ID of an existing customer that will be associated with this request. This field may only be updated if there is no existing associated customer with this charge.", - "maxLength": 5000, - "type": "string" - }, - "description": { - "description": "An arbitrary string which you can attach to a charge object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.", - "maxLength": 40000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" + "style": "form" + }, + { + "description": "Only return VerificationSessions that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" }, - "type": "array" - }, - "fraud_details": { - "description": "A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms.", - "properties": { - "user_report": { - "enum": ["", "fraudulent", "safe"], - "maxLength": 5000, - "type": "string" - } + "gte": { + "type": "integer" }, - "required": ["user_report"], - "title": "fraud_details", - "type": "object" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "receipt_email": { - "description": "This is the email address that the receipt for this charge will be sent to. If this field is updated, then a new email receipt will be sent to the updated address.", - "maxLength": 5000, - "type": "string" - }, - "shipping": { - "description": "Shipping information for the charge. Helps prevent fraud on charges for physical goods.", - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["line1"], - "title": "address", - "type": "object" - }, - "carrier": { - "maxLength": 5000, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - }, - "tracking_number": { - "maxLength": 5000, - "type": "string" - } + "lt": { + "type": "integer" }, - "required": ["address", "name"], - "title": "shipping", - "type": "object" + "lte": { + "type": "integer" + } }, - "transfer_group": { - "description": "A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details.", - "type": "string" - } + "title": "range_query_specs", + "type": "object" }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "in": "query", + "name": "related_customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return VerificationSessions with this status. [Learn more about the lifecycle of sessions](https://stripe.com/docs/identity/how-sessions-work).", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["canceled", "processing", "requires_input", "verified"], + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -37987,7 +79428,34 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/charge" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/identity.verification_session" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/identity/verification_sessions", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "GelatoVerificationSessionList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -38004,24 +79472,10 @@ "description": "Error response." } } - } - }, - "/v1/charges/{charge}/capture": { + }, "post": { - "description": "

Capture the payment of an existing, uncaptured, charge. This is the second half of the two-step payment flow, where first you created a charge with the capture option set to false.

\n\n

Uncaptured payments expire exactly seven days after they are created. If they are not captured by that point in time, they will be marked as refunded and will no longer be capturable.

", - "operationId": "PostChargesChargeCapture", - "parameters": [ - { - "in": "path", - "name": "charge", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], + "description": "

Creates a VerificationSession object.

\n\n

After the VerificationSession is created, display a verification modal using the session client_secret or send your users to the session’s url.

\n\n

If your API key is in test mode, verification checks won’t actually process, though everything else will occur as if in live mode.

\n\n

Related guide: Verify your users’ identity documents

", + "operationId": "PostIdentityVerificationSessions", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -38030,24 +79484,26 @@ "explode": true, "style": "deepObject" }, - "transfer_data": { + "metadata": { + "explode": true, + "style": "deepObject" + }, + "options": { + "explode": true, + "style": "deepObject" + }, + "provided_details": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "amount": { - "description": "The amount to capture, which must be less than or equal to the original amount. Any additional amount will be automatically refunded.", - "type": "integer" - }, - "application_fee": { - "description": "An application fee to add on to this charge.", - "type": "integer" - }, - "application_fee_amount": { - "description": "An application fee amount to add on to this charge, which must be less than or equal to the original amount.", - "type": "integer" + "client_reference_id": { + "description": "A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.", + "maxLength": 5000, + "type": "string" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -38057,32 +79513,85 @@ }, "type": "array" }, - "receipt_email": { - "description": "The email address to send this charge's receipt to. This will override the previously-specified email address for this charge, if one was set. Receipts will not be sent in test mode.", - "type": "string" - }, - "statement_descriptor": { - "description": "For card charges, use `statement_descriptor_suffix` instead. Otherwise, you can use this value as the complete description of a charge on your customers’ statements. Must contain at least one letter, maximum 22 characters.", - "maxLength": 22, - "type": "string" + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" }, - "statement_descriptor_suffix": { - "description": "Provides information about the charge that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.", - "maxLength": 22, - "type": "string" + "options": { + "description": "A set of options for the session’s verification checks.", + "properties": { + "document": { + "anyOf": [ + { + "properties": { + "allowed_types": { + "items": { + "enum": [ + "driving_license", + "id_card", + "passport" + ], + "type": "string" + }, + "type": "array" + }, + "require_id_number": { + "type": "boolean" + }, + "require_live_capture": { + "type": "boolean" + }, + "require_matching_selfie": { + "type": "boolean" + } + }, + "title": "document_options", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "session_options_param", + "type": "object" }, - "transfer_data": { - "description": "An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.", + "provided_details": { + "description": "Details provided about the user being verified. These details may be shown to the user.", "properties": { - "amount": { - "type": "integer" + "email": { + "type": "string" + }, + "phone": { + "type": "string" } }, - "title": "transfer_data_specs", + "title": "provided_details_param", "type": "object" }, - "transfer_group": { - "description": "A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details.", + "related_customer": { + "description": "Token referencing a Customer resource.", + "maxLength": 5000, + "type": "string" + }, + "return_url": { + "description": "The URL that the user will be redirected to upon completing the verification flow.", + "type": "string" + }, + "type": { + "description": "The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed. You must provide a `type` if not passing `verification_flow`.", + "enum": ["document", "id_number"], + "type": "string", + "x-stripeBypassValidation": true + }, + "verification_flow": { + "description": "The ID of a Verification Flow from the Dashboard. See https://docs.stripe.com/identity/verification-flows.", + "maxLength": 5000, "type": "string" } }, @@ -38097,7 +79606,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/identity.verification_session" } } }, @@ -38116,21 +79625,11 @@ } } }, - "/v1/charges/{charge}/dispute": { + "/v1/identity/verification_sessions/{session}": { "get": { - "description": "

Retrieve a dispute for a specified charge.

", - "operationId": "GetChargesChargeDispute", + "description": "

Retrieves the details of a VerificationSession that was previously created.

\n\n

When the session status is requires_input, you can use this method to retrieve a valid\nclient_secret or url to allow re-submission.

", + "operationId": "GetIdentityVerificationSessionsSession", "parameters": [ - { - "in": "path", - "name": "charge", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -38145,6 +79644,16 @@ "type": "array" }, "style": "deepObject" + }, + { + "in": "path", + "name": "session", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" } ], "requestBody": { @@ -38152,6 +79661,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -38164,7 +79674,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/dispute" + "$ref": "#/components/schemas/identity.verification_session" } } }, @@ -38183,12 +79693,12 @@ } }, "post": { - "description": "", - "operationId": "PostChargesChargeDispute", + "description": "

Updates a VerificationSession object.

\n\n

When the session status is requires_input, you can use this method to update the\nverification check and options.

", + "operationId": "PostIdentityVerificationSessionsSession", "parameters": [ { "in": "path", - "name": "charge", + "name": "session", "required": true, "schema": { "maxLength": 5000, @@ -38201,127 +79711,26 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "evidence": { + "expand": { "explode": true, "style": "deepObject" }, - "expand": { + "metadata": { "explode": true, "style": "deepObject" }, - "metadata": { + "options": { + "explode": true, + "style": "deepObject" + }, + "provided_details": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "evidence": { - "description": "Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.", - "properties": { - "access_activity_log": { - "maxLength": 20000, - "type": "string" - }, - "billing_address": { - "maxLength": 5000, - "type": "string" - }, - "cancellation_policy": { - "type": "string" - }, - "cancellation_policy_disclosure": { - "maxLength": 20000, - "type": "string" - }, - "cancellation_rebuttal": { - "maxLength": 20000, - "type": "string" - }, - "customer_communication": { - "type": "string" - }, - "customer_email_address": { - "maxLength": 5000, - "type": "string" - }, - "customer_name": { - "maxLength": 5000, - "type": "string" - }, - "customer_purchase_ip": { - "maxLength": 5000, - "type": "string" - }, - "customer_signature": { - "type": "string" - }, - "duplicate_charge_documentation": { - "type": "string" - }, - "duplicate_charge_explanation": { - "maxLength": 20000, - "type": "string" - }, - "duplicate_charge_id": { - "maxLength": 5000, - "type": "string" - }, - "product_description": { - "maxLength": 20000, - "type": "string" - }, - "receipt": { - "type": "string" - }, - "refund_policy": { - "type": "string" - }, - "refund_policy_disclosure": { - "maxLength": 20000, - "type": "string" - }, - "refund_refusal_explanation": { - "maxLength": 20000, - "type": "string" - }, - "service_date": { - "maxLength": 5000, - "type": "string" - }, - "service_documentation": { - "type": "string" - }, - "shipping_address": { - "maxLength": 5000, - "type": "string" - }, - "shipping_carrier": { - "maxLength": 5000, - "type": "string" - }, - "shipping_date": { - "maxLength": 5000, - "type": "string" - }, - "shipping_documentation": { - "type": "string" - }, - "shipping_tracking_number": { - "maxLength": 5000, - "type": "string" - }, - "uncategorized_file": { - "type": "string" - }, - "uncategorized_text": { - "maxLength": 20000, - "type": "string" - } - }, - "title": "dispute_evidence_params", - "type": "object" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -38331,23 +79740,71 @@ "type": "array" }, "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "options": { + "description": "A set of options for the session’s verification checks.", + "properties": { + "document": { + "anyOf": [ + { + "properties": { + "allowed_types": { + "items": { + "enum": [ + "driving_license", + "id_card", + "passport" + ], + "type": "string" + }, + "type": "array" + }, + "require_id_number": { + "type": "boolean" + }, + "require_live_capture": { + "type": "boolean" + }, + "require_matching_selfie": { + "type": "boolean" + } + }, + "title": "document_options", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "session_options_param", + "type": "object" + }, + "provided_details": { + "description": "Details provided about the user being verified. These details may be shown to the user.", + "properties": { + "email": { + "type": "string" }, - { - "enum": [""], + "phone": { "type": "string" } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "title": "provided_details_param", + "type": "object" }, - "submit": { - "description": "Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).", - "type": "boolean" + "type": { + "description": "The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.", + "enum": ["document", "id_number"], + "type": "string", + "x-stripeBypassValidation": true } }, "type": "object" @@ -38361,7 +79818,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/dispute" + "$ref": "#/components/schemas/identity.verification_session" } } }, @@ -38380,14 +79837,14 @@ } } }, - "/v1/charges/{charge}/dispute/close": { + "/v1/identity/verification_sessions/{session}/cancel": { "post": { - "description": "", - "operationId": "PostChargesChargeDisputeClose", + "description": "

A VerificationSession object can be canceled when it is in requires_input status.

\n\n

Once canceled, future submission attempts are disabled. This cannot be undone. Learn more.

", + "operationId": "PostIdentityVerificationSessionsSessionCancel", "parameters": [ { "in": "path", - "name": "charge", + "name": "session", "required": true, "schema": { "maxLength": 5000, @@ -38406,6 +79863,7 @@ } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -38427,7 +79885,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/dispute" + "$ref": "#/components/schemas/identity.verification_session" } } }, @@ -38446,14 +79904,14 @@ } } }, - "/v1/charges/{charge}/refund": { + "/v1/identity/verification_sessions/{session}/redact": { "post": { - "description": "

When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.

\n\n

Creating a new refund will refund a charge that has previously been created but not yet refunded.\nFunds will be refunded to the credit or debit card that was originally charged.

\n\n

You can optionally refund only part of a charge.\nYou can do so multiple times, until the entire charge has been refunded.

\n\n

Once entirely refunded, a charge can’t be refunded again.\nThis method will raise an error when called on an already-refunded charge,\nor when trying to refund more money than is left on a charge.

", - "operationId": "PostChargesChargeRefund", + "description": "

Redact a VerificationSession to remove all collected information from Stripe. This will redact\nthe VerificationSession and all objects related to it, including VerificationReports, Events,\nrequest logs, etc.

\n\n

A VerificationSession object can be redacted when it is in requires_input or verified\nstatus. Redacting a VerificationSession in requires_action\nstate will automatically cancel it.

\n\n

The redaction process may take up to four days. When the redaction process is in progress, the\nVerificationSession’s redaction.status field will be set to processing; when the process is\nfinished, it will change to redacted and an identity.verification_session.redacted event\nwill be emitted.

\n\n

Redaction is irreversible. Redacted objects are still accessible in the Stripe API, but all the\nfields that contain personal data will be replaced by the string [redacted] or a similar\nplaceholder. The metadata field will also be erased. Redacted objects cannot be updated or\nused for any purpose.

\n\n

Learn more.

", + "operationId": "PostIdentityVerificationSessionsSessionRedact", "parameters": [ { "in": "path", - "name": "charge", + "name": "session", "required": true, "schema": { "maxLength": 5000, @@ -38469,17 +79927,11 @@ "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "amount": { - "type": "integer" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -38487,40 +79939,6 @@ "type": "string" }, "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "payment_intent": { - "maxLength": 5000, - "type": "string" - }, - "reason": { - "enum": [ - "duplicate", - "fraudulent", - "requested_by_customer" - ], - "maxLength": 5000, - "type": "string" - }, - "refund_application_fee": { - "type": "boolean" - }, - "reverse_transfer": { - "type": "boolean" } }, "type": "object" @@ -38534,7 +79952,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/charge" + "$ref": "#/components/schemas/identity.verification_session" } } }, @@ -38553,19 +79971,54 @@ } } }, - "/v1/charges/{charge}/refunds": { + "/v1/invoiceitems": { "get": { - "description": "

You can see a list of the refunds belonging to a specific charge. Note that the 10 most recent refunds are always available by default on the charge object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional refunds.

", - "operationId": "GetChargesChargeRefunds", + "description": "

Returns a list of your invoice items. Invoice items are returned sorted by creation date, with the most recently created invoice items appearing first.

", + "operationId": "GetInvoiceitems", "parameters": [ { - "in": "path", - "name": "charge", - "required": true, + "description": "Only return invoice items that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "The identifier of the customer whose invoice items to return. If none is provided, all invoice items will be returned.", + "in": "query", + "name": "customer", + "required": false, "schema": { + "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", @@ -38573,6 +80026,7 @@ "name": "ending_before", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" @@ -38590,15 +80044,36 @@ }, "type": "array" }, - "style": "deepObject" + "style": "deepObject" + }, + { + "description": "Only return invoice items belonging to this invoice. If none is provided, all invoice items will be returned. If specifying an invoice, no customer identifier is needed.", + "in": "query", + "name": "invoice", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "description": "Set to `true` to only show pending invoice items, which are not yet attached to any invoices. Set to `false` to only show invoice items already attached to invoices. If unspecified, no filter is applied.", "in": "query", - "name": "limit", + "name": "pending", "required": false, "schema": { - "type": "integer" + "type": "boolean" }, "style": "form" }, @@ -38608,6 +80083,7 @@ "name": "starting_after", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" @@ -38618,6 +80094,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -38633,9 +80110,8 @@ "description": "", "properties": { "data": { - "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/refund" + "$ref": "#/components/schemas/invoiceitem" }, "type": "array" }, @@ -38651,11 +80127,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, + "pattern": "^/v1/invoiceitems", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "RefundList", + "title": "InvoicesItemsList", "type": "object", "x-expandableFields": ["data"] } @@ -38676,24 +80153,16 @@ } }, "post": { - "description": "

Create a refund.

", - "operationId": "PostChargesChargeRefunds", - "parameters": [ - { - "in": "path", - "name": "charge", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], + "description": "

Creates an item to be added to a draft invoice (up to 250 items per invoice). If no invoice is specified, the item will be on the next invoice created for the customer specified.

", + "operationId": "PostInvoiceitems", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { + "discounts": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" @@ -38701,13 +80170,79 @@ "metadata": { "explode": true, "style": "deepObject" + }, + "period": { + "explode": true, + "style": "deepObject" + }, + "price_data": { + "explode": true, + "style": "deepObject" + }, + "tax_code": { + "explode": true, + "style": "deepObject" + }, + "tax_rates": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "amount": { + "description": "The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. Passing in a negative `amount` will reduce the `amount_due` on the invoice.", "type": "integer" }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "The ID of the customer who will be billed when this invoice item is billed.", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.", + "maxLength": 5000, + "type": "string" + }, + "discountable": { + "description": "Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items.", + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The coupons and promotion codes to redeem into discounts for the invoice item or invoice line item." + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -38716,6 +80251,11 @@ }, "type": "array" }, + "invoice": { + "description": "The ID of an existing invoice to add this invoice item to. When left blank, the invoice item will be added to the next upcoming scheduled invoice. This is useful when adding invoice items in response to an invoice.created webhook. You can only add invoice items to draft invoices and there is a maximum of 250 items per invoice.", + "maxLength": 5000, + "type": "string" + }, "metadata": { "anyOf": [ { @@ -38731,38 +80271,110 @@ ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "payment_intent": { + "period": { + "description": "The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.", + "properties": { + "end": { + "format": "unix-time", + "type": "integer" + }, + "start": { + "format": "unix-time", + "type": "integer" + } + }, + "required": ["end", "start"], + "title": "period", + "type": "object" + }, + "price": { + "description": "The ID of the price object. One of `price` or `price_data` is required.", "maxLength": 5000, "type": "string" }, - "reason": { - "enum": [ - "duplicate", - "fraudulent", - "requested_by_customer" - ], + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.", + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data", + "type": "object" + }, + "quantity": { + "description": "Non-negative integer. The quantity of units for the invoice item.", + "type": "integer" + }, + "subscription": { + "description": "The ID of a subscription to add this invoice item to. When left blank, the invoice item is added to the next upcoming scheduled invoice. When set, scheduled invoices for subscriptions other than the specified subscription will ignore the invoice item. Use this when you want to express that an invoice item has been accrued within the context of a particular subscription.", "maxLength": 5000, "type": "string" }, - "refund_application_fee": { - "type": "boolean" + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" }, - "reverse_transfer": { - "type": "boolean" + "tax_code": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A [tax code](https://stripe.com/docs/tax/tax-categories) ID." + }, + "tax_rates": { + "description": "The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "unit_amount": { + "description": "The integer unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount` will reduce the `amount_due` on the invoice.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" } }, + "required": ["customer"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/refund" + "$ref": "#/components/schemas/invoiceitem" } } }, @@ -38781,20 +80393,62 @@ } } }, - "/v1/charges/{charge}/refunds/{refund}": { - "get": { - "description": "

Retrieves the details of an existing refund.

", - "operationId": "GetChargesChargeRefundsRefund", + "/v1/invoiceitems/{invoiceitem}": { + "delete": { + "description": "

Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they’re not attached to invoices, or if it’s attached to a draft invoice.

", + "operationId": "DeleteInvoiceitemsInvoiceitem", "parameters": [ { "in": "path", - "name": "charge", + "name": "invoiceitem", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_invoiceitem" + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves the invoice item with the given ID.

", + "operationId": "GetInvoiceitemsInvoiceitem", + "parameters": [ { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -38812,9 +80466,10 @@ }, { "in": "path", - "name": "refund", + "name": "invoiceitem", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" @@ -38825,6 +80480,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -38837,7 +80493,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/refund" + "$ref": "#/components/schemas/invoiceitem" } } }, @@ -38856,23 +80512,15 @@ } }, "post": { - "description": "

Update a specified refund.

", - "operationId": "PostChargesChargeRefundsRefund", + "description": "

Updates the amount or description of an invoice item on an upcoming invoice. Updating an invoice item is only possible before the invoice it’s attached to is closed.

", + "operationId": "PostInvoiceitemsInvoiceitem", "parameters": [ { "in": "path", - "name": "charge", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "refund", + "name": "invoiceitem", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" @@ -38882,6 +80530,10 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { + "discounts": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" @@ -38889,68 +80541,309 @@ "metadata": { "explode": true, "style": "deepObject" + }, + "period": { + "explode": true, + "style": "deepObject" + }, + "price_data": { + "explode": true, + "style": "deepObject" + }, + "tax_code": { + "explode": true, + "style": "deepObject" + }, + "tax_rates": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { + "amount": { + "description": "The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.", + "type": "integer" + }, + "description": { + "description": "An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.", + "maxLength": 5000, + "type": "string" + }, + "discountable": { + "description": "Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items. Cannot be set to true for prorations.", + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The coupons, promotion codes & existing discounts which apply to the invoice item or invoice line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts." + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { "maxLength": 5000, "type": "string" }, - "type": "array" + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "period": { + "description": "The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.", + "properties": { + "end": { + "format": "unix-time", + "type": "integer" + }, + "start": { + "format": "unix-time", + "type": "integer" + } + }, + "required": ["end", "start"], + "title": "period", + "type": "object" + }, + "price": { + "description": "The ID of the price object. One of `price` or `price_data` is required.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.", + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data", + "type": "object" + }, + "quantity": { + "description": "Non-negative integer. The quantity of units for the invoice item.", + "type": "integer" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tax_code": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A [tax code](https://stripe.com/docs/tax/tax-categories) ID." + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item. Pass an empty string to remove previously-defined tax rates." + }, + "unit_amount": { + "description": "The integer unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This unit_amount will be multiplied by the quantity to get the full amount. If you want to apply a credit to the customer's account, pass a negative unit_amount.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/invoiceitem" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/invoices": { + "get": { + "description": "

You can list all invoices, or list the invoices for a specific customer. The invoices are returned sorted by creation date, with the most recently created invoices appearing first.

", + "operationId": "GetInvoices", + "parameters": [ + { + "description": "The collection method of the invoice to retrieve. Either `charge_automatically` or `send_invoice`.", + "in": "query", + "name": "collection_method", + "required": false, + "schema": { + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return invoices that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return invoices for the customer specified by this customer ID.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "explode": true, + "in": "query", + "name": "due_date", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - } + "title": "range_query_specs", + "type": "object" }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/refund" + { + "type": "integer" } - } + ] }, - "description": "Successful response." + "style": "deepObject" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/checkout/sessions": { - "get": { - "description": "

Returns a list of Checkout Sessions.

", - "operationId": "GetCheckoutSessions", - "parameters": [ { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -38988,9 +80881,9 @@ "style": "form" }, { - "description": "Only return the Checkout Session for the PaymentIntent specified.", + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", - "name": "payment_intent", + "name": "starting_after", "required": false, "schema": { "maxLength": 5000, @@ -38999,18 +80892,19 @@ "style": "form" }, { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)", "in": "query", - "name": "starting_after", + "name": "status", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "enum": ["draft", "open", "paid", "uncollectible", "void"], + "type": "string", + "x-stripeBypassValidation": true }, "style": "form" }, { - "description": "Only return the Checkout Session for the subscription specified.", + "description": "Only return invoices for the subscription specified by this subscription ID.", "in": "query", "name": "subscription", "required": false, @@ -39026,6 +80920,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -39042,7 +80937,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/checkout.session" + "$ref": "#/components/schemas/invoice" }, "type": "array" }, @@ -39058,11 +80953,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, + "pattern": "^/v1/invoices", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "PaymentPagesCheckoutSessionList", + "title": "InvoicesResourceList", "type": "object", "x-expandableFields": ["data"] } @@ -39083,12 +80979,28 @@ } }, "post": { - "description": "

Creates a Session object.

", - "operationId": "PostCheckoutSessions", + "description": "

This endpoint creates a draft invoice for a given customer. The invoice remains a draft until you finalize the invoice, which allows you to pay or send the invoice to your customers.

", + "operationId": "PostInvoices", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { + "account_tax_ids": { + "explode": true, + "style": "deepObject" + }, + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "custom_fields": { + "explode": true, + "style": "deepObject" + }, + "default_tax_rates": { + "explode": true, + "style": "deepObject" + }, "discounts": { "explode": true, "style": "deepObject" @@ -39097,7 +81009,11 @@ "explode": true, "style": "deepObject" }, - "line_items": { + "from_invoice": { + "explode": true, + "style": "deepObject" + }, + "issuer": { "explode": true, "style": "deepObject" }, @@ -39105,1122 +81021,788 @@ "explode": true, "style": "deepObject" }, - "payment_intent_data": { + "payment_settings": { "explode": true, "style": "deepObject" }, - "payment_method_types": { + "rendering": { "explode": true, "style": "deepObject" }, - "setup_intent_data": { + "shipping_cost": { "explode": true, "style": "deepObject" }, - "shipping_address_collection": { + "shipping_details": { "explode": true, "style": "deepObject" }, - "subscription_data": { + "transfer_data": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "allow_promotion_codes": { - "description": "Enables user redeemable promotion codes.", - "type": "boolean" - }, - "billing_address_collection": { - "description": "Specify whether Checkout should collect the customer's billing address.", - "enum": ["auto", "required"], - "type": "string" - }, - "cancel_url": { - "description": "The URL the customer will be directed to if they decide to cancel payment and return to your website.", - "maxLength": 5000, - "type": "string" - }, - "client_reference_id": { - "description": "A unique string to reference the Checkout Session. This can be a\ncustomer ID, a cart ID, or similar, and can be used to reconcile the\nsession with your internal systems.", - "maxLength": 200, - "type": "string" - }, - "customer": { - "description": "ID of an existing customer, if one exists. The email stored on the\ncustomer will be used to prefill the email field on the Checkout page.\nIf the customer changes their email on the Checkout page, the Customer\nobject will be updated with the new email.\nIf blank for Checkout Sessions in `payment` or `subscription` mode,\nCheckout will create a new customer object based on information\nprovided during the payment flow.", - "maxLength": 5000, - "type": "string" - }, - "customer_email": { - "description": "If provided, this value will be used when the Customer object is created.\nIf not provided, customers will be asked to enter their email address.\nUse this parameter to prefill customer data if you already have an email\non file. To access information about the customer once a session is\ncomplete, use the `customer` field.", - "type": "string" - }, - "discounts": { - "description": "The coupon or promotion code to apply to this Session. Currently, only up to one may be specified.", - "items": { - "properties": { - "coupon": { + "account_tax_ids": { + "anyOf": [ + { + "items": { "maxLength": 5000, "type": "string" }, - "promotion_code": { - "maxLength": 5000, - "type": "string" - } + "type": "array" }, - "title": "discount_params", - "type": "object" - }, - "type": "array" + { + "enum": [""], + "type": "string" + } + ], + "description": "The account tax IDs associated with the invoice. Only editable when the invoice is a draft." }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "application_fee_amount": { + "description": "A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).", + "type": "integer" }, - "line_items": { - "description": "A list of items the customer is purchasing. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).\nOne-time Prices in `subscription` mode will be on the initial invoice only.\n\nThere is a maximum of 100 line items, however it is recommended to\nconsolidate line items if there are more than a few dozen.", - "items": { - "properties": { - "adjustable_quantity": { - "properties": { - "enabled": { - "type": "boolean" - }, - "maximum": { - "type": "integer" - }, - "minimum": { - "type": "integer" - } - }, - "required": ["enabled"], - "title": "adjustable_quantity_params", - "type": "object" - }, - "amount": { - "type": "integer" - }, - "currency": { - "type": "string" - }, - "description": { - "maxLength": 5000, - "type": "string" - }, - "dynamic_tax_rates": { - "items": { - "maxLength": 5000, + "auto_advance": { + "description": "Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice. If `false`, the invoice's state doesn't automatically advance without an explicit action.", + "type": "boolean" + }, + "automatic_tax": { + "description": "Settings for automatic tax lookup for this invoice.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { "type": "string" }, - "type": "array" - }, - "images": { - "items": { - "maxLength": 5000, + "type": { + "enum": ["account", "self"], "type": "string" - }, - "type": "array" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "price": { - "maxLength": 5000, - "type": "string" + } }, - "price_data": { + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_param", + "type": "object" + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "currency": { + "description": "The currency to create this invoice in. Defaults to that of `customer` if not specified.", + "type": "string" + }, + "custom_fields": { + "anyOf": [ + { + "items": { "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, + "name": { + "maxLength": 40, "type": "string" }, - "product_data": { - "properties": { - "description": { - "maxLength": 40000, - "type": "string" - }, - "images": { - "items": { - "type": "string" - }, - "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "name": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["name"], - "title": "product_data", - "type": "object" - }, - "recurring": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", + "value": { + "maxLength": 140, "type": "string" } }, - "required": ["currency"], - "title": "price_data_with_product_data", + "required": ["name", "value"], + "title": "custom_field_params", "type": "object" }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } + "type": "array" }, - "title": "line_item_params", - "type": "object" - }, - "type": "array" - }, - "locale": { - "description": "The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.", - "enum": [ - "auto", - "bg", - "cs", - "da", - "de", - "el", - "en", - "en-GB", - "es", - "es-419", - "et", - "fi", - "fr", - "fr-CA", - "hu", - "id", - "it", - "ja", - "lt", - "lv", - "ms", - "mt", - "nb", - "nl", - "pl", - "pt", - "pt-BR", - "ro", - "ru", - "sk", - "sl", - "sv", - "tr", - "zh", - "zh-HK", - "zh-TW" + { + "enum": [""], + "type": "string" + } ], - "type": "string", - "x-stripeBypassValidation": true + "description": "A list of up to 4 custom fields to be displayed on the invoice." }, - "metadata": { - "additionalProperties": { + "customer": { + "description": "The ID of the customer who will be billed.", + "maxLength": 5000, + "type": "string" + }, + "days_until_due": { + "description": "The number of days from when the invoice is created until it is due. Valid only for invoices where `collection_method=send_invoice`.", + "type": "integer" + }, + "default_payment_method": { + "description": "ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.", + "maxLength": 5000, + "type": "string" + }, + "default_source": { + "description": "ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.", + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "description": "The tax rates that will apply to any line item that does not have `tax_rates` set.", + "items": { + "maxLength": 5000, "type": "string" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" + "type": "array" }, - "mode": { - "description": "The mode of the Checkout Session. Required when using prices or `setup` mode. Pass `subscription` if the Checkout Session includes at least one recurring item.", - "enum": ["payment", "setup", "subscription"], + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.", + "maxLength": 1500, "type": "string" }, - "payment_intent_data": { - "description": "A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.", - "properties": { - "application_fee_amount": { - "type": "integer" - }, - "capture_method": { - "enum": ["automatic", "manual"], - "type": "string" - }, - "description": { - "maxLength": 1000, - "type": "string" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "on_behalf_of": { - "type": "string" - }, - "receipt_email": { - "maxLength": 5000, - "type": "string" - }, - "setup_future_usage": { - "enum": ["off_session", "on_session"], - "type": "string" - }, - "shipping": { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" }, - "required": ["line1"], - "title": "address", - "type": "object" - }, - "carrier": { - "maxLength": 5000, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - }, - "tracking_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["address", "name"], - "title": "shipping", - "type": "object" - }, - "statement_descriptor": { - "maxLength": 22, - "type": "string" - }, - "statement_descriptor_suffix": { - "maxLength": 22, - "type": "string" - }, - "transfer_data": { - "properties": { - "amount": { - "type": "integer" - }, - "destination": { - "type": "string" - } + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" }, - "required": ["destination"], - "title": "transfer_data_params", - "type": "object" + "type": "array" }, - "transfer_group": { + { + "enum": [""], "type": "string" } - }, - "title": "payment_intent_data_params", - "type": "object" + ], + "description": "The coupons and promotion codes to redeem into discounts for the invoice. If not specified, inherits the discount from the invoice's customer. Pass an empty string to avoid inheriting any discounts." }, - "payment_method_types": { - "description": "A list of the types of payment methods (e.g., `card`) this Checkout Session can accept.\n\nRead more about the supported payment methods and their requirements in our [payment\nmethod details guide](/docs/payments/checkout/payment-methods).\n\nIf multiple payment methods are passed, Checkout will dynamically reorder them to\nprioritize the most relevant payment methods based on the customer's location and\nother characteristics.", + "due_date": { + "description": "The date on which payment for this invoice is due. Valid only for invoices where `collection_method=send_invoice`.", + "format": "unix-time", + "type": "integer" + }, + "effective_at": { + "description": "The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.", + "format": "unix-time", + "type": "integer" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", "items": { - "enum": [ - "afterpay_clearpay", - "alipay", - "bacs_debit", - "bancontact", - "card", - "eps", - "fpx", - "giropay", - "grabpay", - "ideal", - "p24", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true + "maxLength": 5000, + "type": "string" }, "type": "array" }, - "setup_intent_data": { - "description": "A subset of parameters to be passed to SetupIntent creation for Checkout Sessions in `setup` mode.", + "footer": { + "description": "Footer to be displayed on the invoice.", + "maxLength": 5000, + "type": "string" + }, + "from_invoice": { + "description": "Revise an existing invoice. The new invoice will be created in `status=draft`. See the [revision documentation](https://stripe.com/docs/invoicing/invoice-revisions) for more details.", "properties": { - "description": { - "maxLength": 1000, + "action": { + "enum": ["revision"], + "maxLength": 5000, "type": "string" }, - "metadata": { + "invoice": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["action", "invoice"], + "title": "from_invoice", + "type": "object" + }, + "issuer": { + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + }, + "metadata": { + "anyOf": [ + { "additionalProperties": { "type": "string" }, "type": "object" }, - "on_behalf_of": { + { + "enum": [""], "type": "string" } - }, - "title": "setup_intent_data_param", - "type": "object" + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "shipping_address_collection": { - "description": "When set, provides configuration for Checkout to collect a shipping address from a customer.", + "number": { + "description": "Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.", + "maxLength": 26, + "type": "string" + }, + "on_behalf_of": { + "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.", + "type": "string" + }, + "payment_settings": { + "description": "Configuration settings for the PaymentIntent that is generated when the invoice is finalized.", "properties": { - "allowed_countries": { - "items": { - "enum": [ - "AC", - "AD", - "AE", - "AF", - "AG", - "AI", - "AL", - "AM", - "AO", - "AQ", - "AR", - "AT", - "AU", - "AW", - "AX", - "AZ", - "BA", - "BB", - "BD", - "BE", - "BF", - "BG", - "BH", - "BI", - "BJ", - "BL", - "BM", - "BN", - "BO", - "BQ", - "BR", - "BS", - "BT", - "BV", - "BW", - "BY", - "BZ", - "CA", - "CD", - "CF", - "CG", - "CH", - "CI", - "CK", - "CL", - "CM", - "CN", - "CO", - "CR", - "CV", - "CW", - "CY", - "CZ", - "DE", - "DJ", - "DK", - "DM", - "DO", - "DZ", - "EC", - "EE", - "EG", - "EH", - "ER", - "ES", - "ET", - "FI", - "FJ", - "FK", - "FO", - "FR", - "GA", - "GB", - "GD", - "GE", - "GF", - "GG", - "GH", - "GI", - "GL", - "GM", - "GN", - "GP", - "GQ", - "GR", - "GS", - "GT", - "GU", - "GW", - "GY", - "HK", - "HN", - "HR", - "HT", - "HU", - "ID", - "IE", - "IL", - "IM", - "IN", - "IO", - "IQ", - "IS", - "IT", - "JE", - "JM", - "JO", - "JP", - "KE", - "KG", - "KH", - "KI", - "KM", - "KN", - "KR", - "KW", - "KY", - "KZ", - "LA", - "LB", - "LC", - "LI", - "LK", - "LR", - "LS", - "LT", - "LU", - "LV", - "LY", - "MA", - "MC", - "MD", - "ME", - "MF", - "MG", - "MK", - "ML", - "MM", - "MN", - "MO", - "MQ", - "MR", - "MS", - "MT", - "MU", - "MV", - "MW", - "MX", - "MY", - "MZ", - "NA", - "NC", - "NE", - "NG", - "NI", - "NL", - "NO", - "NP", - "NR", - "NU", - "NZ", - "OM", - "PA", - "PE", - "PF", - "PG", - "PH", - "PK", - "PL", - "PM", - "PN", - "PR", - "PS", - "PT", - "PY", - "QA", - "RE", - "RO", - "RS", - "RU", - "RW", - "SA", - "SB", - "SC", - "SE", - "SG", - "SH", - "SI", - "SJ", - "SK", - "SL", - "SM", - "SN", - "SO", - "SR", - "SS", - "ST", - "SV", - "SX", - "SZ", - "TA", - "TC", - "TD", - "TF", - "TG", - "TH", - "TJ", - "TK", - "TL", - "TM", - "TN", - "TO", - "TR", - "TT", - "TV", - "TW", - "TZ", - "UA", - "UG", - "US", - "UY", - "UZ", - "VA", - "VC", - "VE", - "VG", - "VN", - "VU", - "WF", - "WS", - "XK", - "YE", - "YT", - "ZA", - "ZM", - "ZW", - "ZZ" - ], - "type": "string" + "default_mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "payment_method_options": { + "properties": { + "acss_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bancontact": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": ["de", "en", "fr", "nl"], + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card": { + "anyOf": [ + { + "properties": { + "installments": { + "properties": { + "enabled": { + "type": "boolean" + }, + "plan": { + "anyOf": [ + { + "properties": { + "count": { + "type": "integer" + }, + "interval": { + "enum": ["month"], + "type": "string" + }, + "type": { + "enum": ["fixed_count"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "installment_plan", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "installments_param", + "type": "object" + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "customer_balance": { + "anyOf": [ + { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_param", + "type": "object" + }, + "type": { + "type": "string" + } + }, + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "konbini": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "type": "string" + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } }, - "type": "array" + "title": "payment_method_options", + "type": "object" + }, + "payment_method_types": { + "anyOf": [ + { + "items": { + "enum": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "konbini", + "link", + "multibanco", + "p24", + "paynow", + "paypal", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "us_bank_account", + "wechat_pay" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] } }, - "required": ["allowed_countries"], - "title": "shipping_address_collection_params", + "title": "payment_settings", "type": "object" }, - "submit_type": { - "description": "Describes the type of transaction being performed by Checkout in order to customize\nrelevant text on the page, such as the submit button. `submit_type` can only be\nspecified on Checkout Sessions in `payment` mode, but not Checkout Sessions\nin `subscription` or `setup` mode.", - "enum": ["auto", "book", "donate", "pay"], - "type": "string" + "pending_invoice_items_behavior": { + "description": "How to handle pending invoice items on invoice creation. Defaults to `exclude` if the parameter is omitted.", + "enum": ["exclude", "include"], + "type": "string", + "x-stripeBypassValidation": true }, - "subscription_data": { - "description": "A subset of parameters to be passed to subscription creation for Checkout Sessions in `subscription` mode.", + "rendering": { + "description": "The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.", "properties": { - "application_fee_percent": { - "type": "number" + "amount_tax_display": { + "enum": ["", "exclude_tax", "include_inclusive_tax"], + "type": "string" }, - "default_tax_rates": { - "items": { - "maxLength": 5000, - "type": "string" + "pdf": { + "properties": { + "page_size": { + "enum": ["a4", "auto", "letter"], + "type": "string" + } }, - "type": "array" + "title": "rendering_pdf_param", + "type": "object" + } + }, + "title": "rendering_param", + "type": "object" + }, + "shipping_cost": { + "description": "Settings for the cost of shipping for this invoice.", + "properties": { + "shipping_rate": { + "maxLength": 5000, + "type": "string" }, - "items": { - "items": { - "properties": { - "plan": { - "maxLength": 5000, - "type": "string" - }, - "quantity": { - "type": "integer" + "shipping_rate_data": { + "properties": { + "delivery_estimate": { + "properties": { + "maximum": { + "properties": { + "unit": { + "enum": [ + "business_day", + "day", + "hour", + "month", + "week" + ], + "type": "string" + }, + "value": { + "type": "integer" + } + }, + "required": ["unit", "value"], + "title": "delivery_estimate_bound", + "type": "object" + }, + "minimum": { + "properties": { + "unit": { + "enum": [ + "business_day", + "day", + "hour", + "month", + "week" + ], + "type": "string" + }, + "value": { + "type": "integer" + } + }, + "required": ["unit", "value"], + "title": "delivery_estimate_bound", + "type": "object" + } }, - "tax_rates": { - "items": { - "maxLength": 5000, + "title": "delivery_estimate", + "type": "object" + }, + "display_name": { + "maxLength": 100, + "type": "string" + }, + "fixed_amount": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { "type": "string" }, - "type": "array" - } + "currency_options": { + "additionalProperties": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + } + }, + "required": ["amount"], + "title": "currency_option", + "type": "object" + }, + "type": "object" + } + }, + "required": ["amount", "currency"], + "title": "fixed_amount", + "type": "object" }, - "required": ["plan"], - "title": "subscription_data_item_param", - "type": "object" - }, - "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tax_code": { + "type": "string" + }, + "type": { + "enum": ["fixed_amount"], + "type": "string" + } }, + "required": ["display_name"], + "title": "method_params", "type": "object" - }, - "trial_end": { - "format": "unix-time", - "type": "integer" - }, - "trial_period_days": { - "type": "integer" } }, - "title": "subscription_data_params", + "title": "shipping_cost", "type": "object" }, - "success_url": { - "description": "The URL to which Stripe should send customers when payment or setup\nis complete.\nIf you’d like access to the Checkout Session for the successful\npayment, read more about it in the guide on [fulfilling orders](https://stripe.com/docs/payments/checkout/fulfill-orders).", - "maxLength": 5000, - "type": "string" - } - }, - "required": [ - "cancel_url", - "payment_method_types", - "success_url" - ], - "type": "object" - } - } - }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/checkout.session" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/checkout/sessions/{session}": { - "get": { - "description": "

Retrieves a Session object.

", - "operationId": "GetCheckoutSessionsSession", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "session", - "required": true, - "schema": { - "maxLength": 66, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/checkout.session" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/checkout/sessions/{session}/line_items": { - "get": { - "description": "

When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", - "operationId": "GetCheckoutSessionsSessionLineItems", - "parameters": [ - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "in": "path", - "name": "session", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/item" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "PaymentPagesCheckoutSessionListLineItems", - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/country_specs": { - "get": { - "description": "

Lists all Country Spec objects available in the API.

", - "operationId": "GetCountrySpecs", - "parameters": [ - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/country_spec" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/country_specs", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/country_specs/{country}": { - "get": { - "description": "

Returns a Country Spec for a given Country code.

", - "operationId": "GetCountrySpecsCountry", - "parameters": [ - { - "in": "path", - "name": "country", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, + "shipping_details": { + "description": "Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "required": ["address", "name"], + "title": "recipient_shipping_with_optional_fields_address", + "type": "object" + }, + "statement_descriptor": { + "description": "Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.", + "maxLength": 22, + "type": "string" + }, + "subscription": { + "description": "The ID of the subscription to invoice, if any. If set, the created invoice will only include pending invoice items for that subscription. The subscription's billing cycle and regular subscription events won't be affected.", + "maxLength": 5000, + "type": "string" + }, + "transfer_data": { + "description": "If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge.", + "properties": { + "amount": { + "type": "integer" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + } + }, "type": "object" } } @@ -40232,7 +81814,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/country_spec" + "$ref": "#/components/schemas/invoice" } } }, @@ -40251,267 +81833,1255 @@ } } }, - "/v1/coupons": { - "get": { - "description": "

Returns a list of your coupons.

", - "operationId": "GetCoupons", - "parameters": [ - { - "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], + "/v1/invoices/create_preview": { + "post": { + "description": "

At any time, you can preview the upcoming invoice for a customer. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice.

\n\n

Note that when you are viewing an upcoming invoice, you are simply viewing a preview – the invoice has not yet been created. As such, the upcoming invoice will not show up in invoice listing calls, and you cannot use the API to pay or edit the invoice. If you want to change the amount that your customer will be billed, you can add, remove, or update pending invoice items, or update the customer’s discount.

\n\n

You can preview the effects of updating a subscription, including a preview of what proration will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass the subscription_details.proration_date parameter when doing the actual subscription update. The recommended way to get only the prorations being previewed is to consider only proration line items where period[start] is equal to the subscription_details.proration_date value passed in the request.

\n\n

Note: Currency conversion calculations use the latest exchange rates. Exchange rates may vary between the time of the preview and the time of the actual invoice creation. Learn more

", + "operationId": "PostInvoicesCreatePreview", "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "customer_details": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "invoice_items": { + "explode": true, + "style": "deepObject" + }, + "issuer": { + "explode": true, + "style": "deepObject" + }, + "on_behalf_of": { + "explode": true, + "style": "deepObject" + }, + "schedule_details": { + "explode": true, + "style": "deepObject" + }, + "subscription_details": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/coupon" + "additionalProperties": false, + "properties": { + "automatic_tax": { + "description": "Settings for automatic tax lookup for this invoice preview.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_param", + "type": "object" + }, + "coupon": { + "description": "The ID of the coupon to apply to this phase of the subscription schedule. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "The currency to preview this invoice in. Defaults to that of `customer` if not specified.", + "type": "string" + }, + "customer": { + "description": "The identifier of the customer whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.", + "maxLength": 5000, + "type": "string" + }, + "customer_details": { + "description": "Details about the customer you want to invoice or overrides for an existing customer. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.", + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "shipping": { + "anyOf": [ + { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["address", "name"], + "title": "customer_shipping", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "tax": { + "properties": { + "ip_address": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "tax_param", + "type": "object" + }, + "tax_exempt": { + "enum": ["", "exempt", "none", "reverse"], + "type": "string" + }, + "tax_ids": { + "items": { + "properties": { + "type": { + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "value": { + "type": "string" + } + }, + "required": ["type", "value"], + "title": "data_params", + "type": "object" + }, + "type": "array" + } + }, + "title": "customer_details_param", + "type": "object" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the subscription or customer. This works for both coupons directly applied to an invoice and coupons applied to a subscription. Pass an empty string to avoid inheriting any discounts." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "invoice_items": { + "description": "List of invoice items to add or update in the upcoming invoice preview.", + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "discountable": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "invoiceitem": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "period": { + "properties": { + "end": { + "format": "unix-time", + "type": "integer" + }, + "start": { + "format": "unix-time", + "type": "integer" + } + }, + "required": ["end", "start"], + "title": "period", + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tax_code": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" + "title": "invoice_item_preview_params", + "type": "object" }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/coupons", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

You can create coupons easily via the coupon management page of the Stripe dashboard. Coupon creation is also accessible via the API if you need to create coupons on the fly.

\n\n

A coupon has either a percent_off or an amount_off and currency. If you set an amount_off, that amount will be subtracted from any invoice’s subtotal. For example, an invoice with a subtotal of 100 will have a final total of 0 if a coupon with an amount_off of 200 is applied to it and an invoice with a subtotal of 300 will have a final total of 100 if a coupon with an amount_off of 200 is applied to it.

", - "operationId": "PostCoupons", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "applies_to": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "amount_off": { - "description": "A positive integer representing the amount to subtract from an invoice total (required if `percent_off` is not passed).", - "type": "integer" + "type": "array" }, - "applies_to": { - "description": "A hash containing directions for what this Coupon will apply discounts to.", + "issuer": { + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", "properties": { - "products": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" } }, - "required": ["products"], - "title": "applies_to_params", + "required": ["type"], + "title": "param", "type": "object" }, - "currency": { - "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed).", - "type": "string" + "on_behalf_of": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details." }, - "duration": { - "description": "Specifies how long the discount will be in effect. Can be `forever`, `once`, or `repeating`.", - "enum": ["forever", "once", "repeating"], + "preview_mode": { + "description": "Customizes the types of values to include when calculating the invoice. Defaults to `next` if unspecified.", + "enum": ["next", "recurring"], "type": "string" }, - "duration_in_months": { - "description": "Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect.", - "type": "integer" + "schedule": { + "description": "The identifier of the schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.", + "maxLength": 5000, + "type": "string" }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" + "schedule_details": { + "description": "The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.", + "properties": { + "end_behavior": { + "enum": ["cancel", "release"], + "type": "string" + }, + "phases": { + "items": { + "properties": { + "add_invoice_items": { + "items": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "add_invoice_item_entry", + "type": "object" + }, + "type": "array" + }, + "application_fee_percent": { + "type": "number" + }, + "automatic_tax": { + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "enum": ["automatic", "phase_start"], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "collection_method": { + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "default_payment_method": { + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "end_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + }, + "invoice_settings": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "days_until_due": { + "type": "integer" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings", + "type": "object" + }, + "items": { + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": [ + "day", + "month", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product", + "recurring" + ], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "configuration_item_params", + "type": "object" + }, + "type": "array" + }, + "iterations": { + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "on_behalf_of": { + "type": "string" + }, + "proration_behavior": { + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + }, + "start_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + }, + "transfer_data": { + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + "trial": { + "type": "boolean" + }, + "trial_end": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + } + }, + "required": ["items"], + "title": "phase_configuration_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + } }, - "type": "array" + "title": "schedule_details_params", + "type": "object" }, - "id": { - "description": "Unique string of your choice that will be used to identify this coupon when applying it to a customer. If you don't want to specify a particular code, you can leave the ID blank and we'll generate a random code for you.", + "subscription": { + "description": "The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_details.items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_details.items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.", "maxLength": 5000, "type": "string" }, - "max_redemptions": { - "description": "A positive integer specifying the number of times the coupon can be redeemed before it's no longer valid. For example, you might have a 50% off coupon that the first 20 readers of your blog can use.", - "type": "integer" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" + "subscription_details": { + "description": "The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.", + "properties": { + "billing_cycle_anchor": { + "anyOf": [ + { + "enum": ["now", "unchanged"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ] + }, + "cancel_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cancel_at_period_end": { + "type": "boolean" + }, + "cancel_now": { + "type": "boolean" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "items": { + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "clear_usage": { + "type": "boolean" + }, + "deleted": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "id": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "subscription_item_update_params", + "type": "object" }, - "type": "object" + "type": "array" }, - { - "enum": [""], + "proration_behavior": { + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "proration_date": { + "format": "unix-time", + "type": "integer" + }, + "resume_at": { + "enum": ["now"], + "maxLength": 5000, "type": "string" + }, + "start_date": { + "format": "unix-time", + "type": "integer" + }, + "trial_end": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ] } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "name": { - "description": "Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.", - "maxLength": 40, - "type": "string" - }, - "percent_off": { - "description": "A positive float larger than 0, and smaller or equal to 100, that represents the discount the coupon will apply (required if `amount_off` is not passed).", - "type": "number" - }, - "redeem_by": { - "description": "Unix timestamp specifying the last time at which the coupon can be redeemed. After the redeem_by date, the coupon can no longer be applied to new customers.", - "format": "unix-time", - "type": "integer" + }, + "title": "subscription_details_params", + "type": "object" } }, - "required": ["duration"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/coupon" + "$ref": "#/components/schemas/invoice" } } }, @@ -40530,20 +83100,57 @@ } } }, - "/v1/coupons/{coupon}": { - "delete": { - "description": "

You can delete coupons via the coupon management page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can’t redeem the coupon. You can also delete coupons via the API.

", - "operationId": "DeleteCouponsCoupon", + "/v1/invoices/search": { + "get": { + "description": "

Search for invoices you’ve previously created using Stripe’s Search Query Language.\nDon’t use search in read-after-write flows where strict consistency is necessary. Under normal operating\nconditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up\nto an hour behind during outages. Search functionality is not available to merchants in India.

", + "operationId": "GetInvoicesSearch", "parameters": [ { - "in": "path", - "name": "coupon", + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.", + "in": "query", + "name": "page", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for invoices](https://stripe.com/docs/search#query-fields-for-invoices).", + "in": "query", + "name": "query", "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" } ], "requestBody": { @@ -40551,6 +83158,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -40563,7 +83171,40 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_coupon" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/invoice" + }, + "type": "array" + }, + "has_more": { + "type": "boolean" + }, + "next_page": { + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["search_result"], + "type": "string" + }, + "total_count": { + "description": "The total number of objects that match the query, only accurate up to 10,000.", + "type": "integer" + }, + "url": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SearchResult", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -40580,20 +83221,333 @@ "description": "Error response." } } - }, + } + }, + "/v1/invoices/upcoming": { "get": { - "description": "

Retrieves the coupon with the given ID.

", - "operationId": "GetCouponsCoupon", + "description": "

At any time, you can preview the upcoming invoice for a customer. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice.

\n\n

Note that when you are viewing an upcoming invoice, you are simply viewing a preview – the invoice has not yet been created. As such, the upcoming invoice will not show up in invoice listing calls, and you cannot use the API to pay or edit the invoice. If you want to change the amount that your customer will be billed, you can add, remove, or update pending invoice items, or update the customer’s discount.

\n\n

You can preview the effects of updating a subscription, including a preview of what proration will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass the subscription_details.proration_date parameter when doing the actual subscription update. The recommended way to get only the prorations being previewed is to consider only proration line items where period[start] is equal to the subscription_details.proration_date value passed in the request.

\n\n

Note: Currency conversion calculations use the latest exchange rates. Exchange rates may vary between the time of the preview and the time of the actual invoice creation. Learn more

", + "operationId": "GetInvoicesUpcoming", "parameters": [ { - "in": "path", + "description": "Settings for automatic tax lookup for this invoice preview.", + "explode": true, + "in": "query", + "name": "automatic_tax", + "required": false, + "schema": { + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_param", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "The ID of the coupon to apply to this phase of the subscription schedule. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "in": "query", "name": "coupon", - "required": true, + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" + }, + { + "description": "The currency to preview this invoice in. Defaults to that of `customer` if not specified.", + "in": "query", + "name": "currency", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "The identifier of the customer whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Details about the customer you want to invoice or overrides for an existing customer. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.", + "explode": true, + "in": "query", + "name": "customer_details", + "required": false, + "schema": { + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "shipping": { + "anyOf": [ + { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["address", "name"], + "title": "customer_shipping", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "tax": { + "properties": { + "ip_address": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "tax_param", + "type": "object" + }, + "tax_exempt": { + "enum": ["", "exempt", "none", "reverse"], + "type": "string" + }, + "tax_ids": { + "items": { + "properties": { + "type": { + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "value": { + "type": "string" + } + }, + "required": ["type", "value"], + "title": "data_params", + "type": "object" + }, + "type": "array" + } + }, + "title": "customer_details_param", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the subscription or customer. This works for both coupons directly applied to an invoice and coupons applied to a subscription. Pass an empty string to avoid inheriting any discounts.", + "explode": true, + "in": "query", + "name": "discounts", + "required": false, + "schema": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "style": "deepObject" }, { "description": "Specifies which fields in the response should be expanded.", @@ -40609,499 +83563,1148 @@ "type": "array" }, "style": "deepObject" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/coupon" - } - } - }, - "description": "Successful response." }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates the metadata of a coupon. Other coupon details (currency, duration, amount_off) are, by design, not editable.

", - "operationId": "PostCouponsCoupon", - "parameters": [ { - "in": "path", - "name": "coupon", - "required": true, + "description": "List of invoice items to add or update in the upcoming invoice preview.", + "explode": true, + "in": "query", + "name": "invoice_items", + "required": false, "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { + "items": { "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "discountable": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "invoiceitem": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "period": { + "properties": { + "end": { + "format": "unix-time", + "type": "integer" + }, + "start": { + "format": "unix-time", + "type": "integer" + } }, - "type": "array" + "required": ["end", "start"], + "title": "period", + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tax_code": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "metadata": { + "tax_rates": { "anyOf": [ { - "additionalProperties": { + "items": { + "maxLength": 5000, "type": "string" }, - "type": "object" + "type": "array" }, { "enum": [""], "type": "string" } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + ] }, - "name": { - "description": "Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.", - "maxLength": 40, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", "type": "string" } }, + "title": "invoice_item_preview_params", "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/coupon" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/credit_notes": { - "get": { - "description": "

Returns a list of credit notes.

", - "operationId": "GetCreditNotes", - "parameters": [ - { - "description": "Only return credit notes for the customer specified by this customer ID.", - "in": "query", - "name": "customer", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" + }, + "type": "array" }, - "style": "form" + "style": "deepObject" }, { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", + "explode": true, "in": "query", - "name": "ending_before", + "name": "issuer", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" }, - "style": "form" + "style": "deepObject" }, { - "description": "Specifies which fields in the response should be expanded.", + "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.", "explode": true, "in": "query", - "name": "expand", + "name": "on_behalf_of", "required": false, "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] }, "style": "deepObject" }, { - "description": "Only return credit notes for the invoice specified by this invoice ID.", + "description": "Customizes the types of values to include when calculating the invoice. Defaults to `next` if unspecified.", "in": "query", - "name": "invoice", + "name": "preview_mode", "required": false, "schema": { - "maxLength": 5000, + "enum": ["next", "recurring"], "type": "string" }, "style": "form" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "description": "The identifier of the schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.", "in": "query", - "name": "limit", + "name": "schedule", "required": false, "schema": { - "type": "integer" + "maxLength": 5000, + "type": "string" }, "style": "form" }, { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.", + "explode": true, "in": "query", - "name": "starting_after", + "name": "schedule_details", "required": false, "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/credit_note" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "CreditNotesList", - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Issue a credit note to adjust the amount of a finalized invoice. For a status=open invoice, a credit note reduces\nits amount_due. For a status=paid invoice, a credit note does not affect its amount_due. Instead, it can result\nin any combination of the following:

\n\n
    \n
  • Refund: create a new refund (using refund_amount) or link an existing refund (using refund).
  • \n
  • Customer balance credit: credit the customer’s balance (using credit_amount) which will be automatically applied to their next invoice when it’s finalized.
  • \n
  • Outside of Stripe credit: record the amount that is or will be credited outside of Stripe (using out_of_band_amount).
  • \n
\n\n

For post-payment credit notes the sum of the refund, credit and outside of Stripe amounts must equal the credit note total.

\n\n

You may issue multiple credit notes for an invoice. Each credit note will increment the invoice’s pre_payment_credit_notes_amount\nor post_payment_credit_notes_amount depending on its status at the time of credit note creation.

", - "operationId": "PostCreditNotes", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "lines": { - "explode": true, - "style": "deepObject" + "properties": { + "end_behavior": { + "enum": ["cancel", "release"], + "type": "string" }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "amount": { - "description": "The integer amount in %s representing the total amount of the credit note.", - "type": "integer" - }, - "credit_amount": { - "description": "The integer amount in %s representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.", - "type": "integer" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "invoice": { - "description": "ID of the invoice.", - "maxLength": 5000, - "type": "string" - }, - "lines": { - "description": "Line items that make up the credit note.", - "items": { - "properties": { - "amount": { - "type": "integer" - }, - "description": { - "maxLength": 5000, - "type": "string" + "phases": { + "items": { + "properties": { + "add_invoice_items": { + "items": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "add_invoice_item_entry", + "type": "object" }, - "invoice_line_item": { - "maxLength": 5000, - "type": "string" + "type": "array" + }, + "application_fee_percent": { + "type": "number" + }, + "automatic_tax": { + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } }, - "quantity": { - "type": "integer" + "required": ["enabled"], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "enum": ["automatic", "phase_start"], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "collection_method": { + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "default_payment_method": { + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "end_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + }, + "invoice_settings": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "days_until_due": { + "type": "integer" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, + "title": "invoice_settings", + "type": "object" + }, + "items": { + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "metadata": { + "additionalProperties": { "type": "string" }, - "type": "array" + "type": "object" }, - { - "enum": [""], + "price": { + "maxLength": 5000, "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] } - ] + }, + "title": "configuration_item_params", + "type": "object" }, - "type": { - "enum": ["custom_line_item", "invoice_line_item"], + "type": "array" + }, + "iterations": { + "type": "integer" + }, + "metadata": { + "additionalProperties": { "type": "string" }, - "unit_amount": { - "type": "integer" + "type": "object" + }, + "on_behalf_of": { + "type": "string" + }, + "proration_behavior": { + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "start_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + }, + "transfer_data": { + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" }, - "required": ["type"], - "title": "credit_note_line_item_params", - "type": "object" - }, - "type": "array" - }, - "memo": { - "description": "The credit note's memo appears on the credit note PDF.", - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "additionalProperties": { - "type": "string" + "trial": { + "type": "boolean" + }, + "trial_end": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + } }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "required": ["items"], + "title": "phase_configuration_params", "type": "object" }, - "out_of_band_amount": { - "description": "The integer amount in %s representing the amount that is credited outside of Stripe.", - "type": "integer" - }, - "reason": { - "description": "Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`", - "enum": [ - "duplicate", - "fraudulent", - "order_change", - "product_unsatisfactory" - ], - "type": "string" - }, - "refund": { - "description": "ID of an existing refund to link this credit note to.", - "type": "string" - }, - "refund_amount": { - "description": "The integer amount in %s representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.", - "type": "integer" - } + "type": "array" }, - "required": ["invoice"], - "type": "object" - } - } + "proration_behavior": { + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + } + }, + "title": "schedule_details_params", + "type": "object" + }, + "style": "deepObject" }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/credit_note" + { + "description": "The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_details.items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_details.items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.", + "in": "query", + "name": "subscription", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.billing_cycle_anchor` instead.", + "explode": true, + "in": "query", + "name": "subscription_billing_cycle_anchor", + "required": false, + "schema": { + "anyOf": [ + { + "enum": ["now", "unchanged"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" } - } + ] }, - "description": "Successful response." + "style": "deepObject" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" + { + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_at` instead.", + "explode": true, + "in": "query", + "name": "subscription_cancel_at", + "required": false, + "schema": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" } - } + ] }, - "description": "Error response." - } - } - } - }, - "/v1/credit_notes/preview": { - "get": { - "description": "

Get a preview of a credit note without creating it.

", - "operationId": "GetCreditNotesPreview", - "parameters": [ + "style": "deepObject" + }, { - "description": "The integer amount in %s representing the total amount of the credit note.", + "description": "Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_at_period_end` instead.", "in": "query", - "name": "amount", + "name": "subscription_cancel_at_period_end", "required": false, "schema": { - "type": "integer" + "type": "boolean" }, "style": "form" }, { - "description": "The integer amount in %s representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.", + "description": "This simulates the subscription being canceled or expired immediately. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_now` instead.", "in": "query", - "name": "credit_amount", + "name": "subscription_cancel_now", "required": false, "schema": { - "type": "integer" + "type": "boolean" }, "style": "form" }, { - "description": "Specifies which fields in the response should be expanded.", + "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set. This field has been deprecated and will be removed in a future API version. Use `subscription_details.default_tax_rates` instead.", "explode": true, "in": "query", - "name": "expand", + "name": "subscription_default_tax_rates", "required": false, "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] }, "style": "deepObject" }, { - "description": "ID of the invoice.", + "description": "The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.", + "explode": true, "in": "query", - "name": "invoice", - "required": true, + "name": "subscription_details", + "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "properties": { + "billing_cycle_anchor": { + "anyOf": [ + { + "enum": ["now", "unchanged"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ] + }, + "cancel_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cancel_at_period_end": { + "type": "boolean" + }, + "cancel_now": { + "type": "boolean" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "items": { + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "clear_usage": { + "type": "boolean" + }, + "deleted": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "id": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "subscription_item_update_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "proration_date": { + "format": "unix-time", + "type": "integer" + }, + "resume_at": { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + "start_date": { + "format": "unix-time", + "type": "integer" + }, + "trial_end": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ] + } + }, + "title": "subscription_details_params", + "type": "object" }, - "style": "form" + "style": "deepObject" }, { - "description": "Line items that make up the credit note.", + "description": "A list of up to 20 subscription items, each with an attached price. This field has been deprecated and will be removed in a future API version. Use `subscription_details.items` instead.", "explode": true, "in": "query", - "name": "lines", + "name": "subscription_items", "required": false, "schema": { "items": { "properties": { - "amount": { - "type": "integer" + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "description": { + "clear_usage": { + "type": "boolean" + }, + "deleted": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "id": { "maxLength": 5000, "type": "string" }, - "invoice_line_item": { + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "price": { "maxLength": 5000, "type": "string" }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, "quantity": { "type": "integer" }, @@ -41119,21 +84722,9 @@ "type": "string" } ] - }, - "type": { - "enum": ["custom_line_item", "invoice_line_item"], - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" } }, - "required": ["type"], - "title": "credit_note_line_item_params", + "title": "subscription_item_update_params", "type": "object" }, "type": "array" @@ -41141,75 +84732,70 @@ "style": "deepObject" }, { - "description": "The credit note's memo appears on the credit note PDF.", + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.proration_behavior` instead.", "in": "query", - "name": "memo", + "name": "subscription_proration_behavior", "required": false, "schema": { - "maxLength": 5000, + "enum": ["always_invoice", "create_prorations", "none"], "type": "string" }, "style": "form" }, { - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "explode": true, - "in": "query", - "name": "metadata", - "required": false, - "schema": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "style": "deepObject" - }, - { - "description": "The integer amount in %s representing the amount that is credited outside of Stripe.", + "description": "If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'. This field has been deprecated and will be removed in a future API version. Use `subscription_details.proration_date` instead.", "in": "query", - "name": "out_of_band_amount", + "name": "subscription_proration_date", "required": false, "schema": { + "format": "unix-time", "type": "integer" }, "style": "form" }, { - "description": "Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`", + "description": "For paused subscriptions, setting `subscription_resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed. This field has been deprecated and will be removed in a future API version. Use `subscription_details.resume_at` instead.", "in": "query", - "name": "reason", + "name": "subscription_resume_at", "required": false, "schema": { - "enum": [ - "duplicate", - "fraudulent", - "order_change", - "product_unsatisfactory" - ], + "enum": ["now"], + "maxLength": 5000, "type": "string" }, "style": "form" }, { - "description": "ID of an existing refund to link this credit note to.", + "description": "Date a subscription is intended to start (can be future or past). This field has been deprecated and will be removed in a future API version. Use `subscription_details.start_date` instead.", "in": "query", - "name": "refund", + "name": "subscription_start_date", "required": false, "schema": { - "type": "string" + "format": "unix-time", + "type": "integer" }, "style": "form" }, { - "description": "The integer amount in %s representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.", + "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required. This field has been deprecated and will be removed in a future API version. Use `subscription_details.trial_end` instead.", + "explode": true, "in": "query", - "name": "refund_amount", + "name": "subscription_trial_end", "required": false, "schema": { - "type": "integer" + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ] }, - "style": "form" + "style": "deepObject" } ], "requestBody": { @@ -41217,6 +84803,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -41229,7 +84816,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/credit_note" + "$ref": "#/components/schemas/invoice" } } }, @@ -41248,35 +84835,68 @@ } } }, - "/v1/credit_notes/preview/lines": { + "/v1/invoices/upcoming/lines": { "get": { - "description": "

When retrieving a credit note preview, you’ll get a lines property containing the first handful of those items. This URL you can retrieve the full (paginated) list of line items.

", - "operationId": "GetCreditNotesPreviewLines", + "description": "

When retrieving an upcoming invoice, you’ll get a lines property containing the total count of line items and the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", + "operationId": "GetInvoicesUpcomingLines", "parameters": [ { - "description": "The integer amount in %s representing the total amount of the credit note.", + "description": "Settings for automatic tax lookup for this invoice preview.", + "explode": true, "in": "query", - "name": "amount", + "name": "automatic_tax", "required": false, "schema": { - "type": "integer" + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_param", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "The ID of the coupon to apply to this phase of the subscription schedule. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "in": "query", + "name": "coupon", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" }, "style": "form" }, { - "description": "The integer amount in %s representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.", + "description": "The currency to preview this invoice in. Defaults to that of `customer` if not specified.", "in": "query", - "name": "credit_amount", + "name": "currency", "required": false, "schema": { - "type": "integer" + "type": "string" }, "style": "form" }, { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "description": "The identifier of the customer whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.", "in": "query", - "name": "ending_before", + "name": "customer", "required": false, "schema": { "maxLength": 5000, @@ -41285,25 +84905,267 @@ "style": "form" }, { - "description": "Specifies which fields in the response should be expanded.", + "description": "Details about the customer you want to invoice or overrides for an existing customer. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.", "explode": true, "in": "query", - "name": "expand", + "name": "customer_details", "required": false, "schema": { - "items": { - "maxLength": 5000, - "type": "string" + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "shipping": { + "anyOf": [ + { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["address", "name"], + "title": "customer_shipping", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "tax": { + "properties": { + "ip_address": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "tax_param", + "type": "object" + }, + "tax_exempt": { + "enum": ["", "exempt", "none", "reverse"], + "type": "string" + }, + "tax_ids": { + "items": { + "properties": { + "type": { + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "value": { + "type": "string" + } + }, + "required": ["type", "value"], + "title": "data_params", + "type": "object" + }, + "type": "array" + } }, - "type": "array" + "title": "customer_details_param", + "type": "object" }, "style": "deepObject" }, { - "description": "ID of the invoice.", + "description": "The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the subscription or customer. This works for both coupons directly applied to an invoice and coupons applied to a subscription. Pass an empty string to avoid inheriting any discounts.", + "explode": true, "in": "query", - "name": "invoice", - "required": true, + "name": "discounts", + "required": false, + "schema": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, "schema": { "maxLength": 5000, "type": "string" @@ -41311,20 +85173,25 @@ "style": "form" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "description": "Specifies which fields in the response should be expanded.", + "explode": true, "in": "query", - "name": "limit", + "name": "expand", "required": false, "schema": { - "type": "integer" + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "style": "form" + "style": "deepObject" }, { - "description": "Line items that make up the credit note.", + "description": "List of invoice items to add or update in the upcoming invoice preview.", "explode": true, "in": "query", - "name": "lines", + "name": "invoice_items", "required": false, "schema": { "items": { @@ -41332,23 +85199,36 @@ "amount": { "type": "integer" }, - "description": { - "maxLength": 5000, + "currency": { "type": "string" }, - "invoice_line_item": { + "description": { "maxLength": 5000, "type": "string" }, - "quantity": { - "type": "integer" + "discountable": { + "type": "boolean" }, - "tax_rates": { + "discounts": { "anyOf": [ { "items": { - "maxLength": 5000, - "type": "string" + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" }, "type": "array" }, @@ -41358,605 +85238,1208 @@ } ] }, - "type": { - "enum": ["custom_line_item", "invoice_line_item"], + "invoiceitem": { + "maxLength": 5000, "type": "string" }, - "unit_amount": { - "type": "integer" + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["type"], - "title": "credit_note_line_item_params", - "type": "object" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "The credit note's memo appears on the credit note PDF.", - "in": "query", - "name": "memo", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "explode": true, - "in": "query", - "name": "metadata", - "required": false, - "schema": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "style": "deepObject" - }, - { - "description": "The integer amount in %s representing the amount that is credited outside of Stripe.", - "in": "query", - "name": "out_of_band_amount", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`", - "in": "query", - "name": "reason", - "required": false, - "schema": { - "enum": [ - "duplicate", - "fraudulent", - "order_change", - "product_unsatisfactory" - ], - "type": "string" - }, - "style": "form" - }, - { - "description": "ID of an existing refund to link this credit note to.", - "in": "query", - "name": "refund", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - }, - { - "description": "The integer amount in %s representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.", - "in": "query", - "name": "refund_amount", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/credit_note_line_item" + "period": { + "properties": { + "end": { + "format": "unix-time", + "type": "integer" }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" + "start": { + "format": "unix-time", + "type": "integer" + } }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" + "required": ["end", "start"], + "title": "period", + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } + "required": ["currency", "product"], + "title": "one_time_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tax_code": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "required": ["data", "has_more", "object", "url"], - "title": "CreditNoteLinesList", - "type": "object", - "x-expandableFields": ["data"] - } - } + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "invoice_item_preview_params", + "type": "object" + }, + "type": "array" }, - "description": "Successful response." + "style": "deepObject" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/credit_notes/{credit_note}/lines": { - "get": { - "description": "

When retrieving a credit note, you’ll get a lines property containing the the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", - "operationId": "GetCreditNotesCreditNoteLines", - "parameters": [ { - "in": "path", - "name": "credit_note", - "required": true, + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", + "explode": true, + "in": "query", + "name": "issuer", + "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" }, - "style": "simple" + "style": "deepObject" }, { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", - "name": "ending_before", + "name": "limit", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "type": "integer" }, "style": "form" }, { - "description": "Specifies which fields in the response should be expanded.", + "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.", "explode": true, "in": "query", - "name": "expand", + "name": "on_behalf_of", "required": false, "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] }, "style": "deepObject" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "description": "Customizes the types of values to include when calculating the invoice. Defaults to `next` if unspecified.", "in": "query", - "name": "limit", + "name": "preview_mode", "required": false, "schema": { - "type": "integer" + "enum": ["next", "recurring"], + "type": "string" }, "style": "form" }, { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "The identifier of the schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.", "in": "query", - "name": "starting_after", + "name": "schedule", "required": false, "schema": { "maxLength": 5000, "type": "string" }, "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "description": "Details about each object.", + { + "description": "The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.", + "explode": true, + "in": "query", + "name": "schedule_details", + "required": false, + "schema": { + "properties": { + "end_behavior": { + "enum": ["cancel", "release"], + "type": "string" + }, + "phases": { + "items": { + "properties": { + "add_invoice_items": { + "items": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "add_invoice_item_entry", + "type": "object" + }, + "type": "array" + }, + "application_fee_percent": { + "type": "number" + }, + "automatic_tax": { + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "enum": ["automatic", "phase_start"], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "collection_method": { + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "default_payment_method": { + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "end_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + }, + "invoice_settings": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "days_until_due": { + "type": "integer" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings", + "type": "object" + }, "items": { - "$ref": "#/components/schemas/credit_note_line_item" + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "configuration_item_params", + "type": "object" + }, + "type": "array" }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" + "iterations": { + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "on_behalf_of": { + "type": "string" + }, + "proration_behavior": { + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "start_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + }, + "transfer_data": { + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + "trial": { + "type": "boolean" + }, + "trial_end": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + } }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } + "required": ["items"], + "title": "phase_configuration_params", + "type": "object" }, - "required": ["data", "has_more", "object", "url"], - "title": "CreditNoteLinesList", - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" + "type": "array" + }, + "proration_behavior": { + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/credit_notes/{id}": { - "get": { - "description": "

Retrieves the credit note object with the given identifier.

", - "operationId": "GetCreditNotesId", - "parameters": [ + }, + "title": "schedule_details_params", + "type": "object" + }, + "style": "deepObject" + }, { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", - "name": "expand", + "name": "starting_after", "required": false, "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "form" }, { - "in": "path", - "name": "id", - "required": true, + "description": "The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_details.items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_details.items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.", + "in": "query", + "name": "subscription", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } + "style": "form" }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/credit_note" + { + "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.billing_cycle_anchor` instead.", + "explode": true, + "in": "query", + "name": "subscription_billing_cycle_anchor", + "required": false, + "schema": { + "anyOf": [ + { + "enum": ["now", "unchanged"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" } - } + ] }, - "description": "Successful response." + "style": "deepObject" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" + { + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_at` instead.", + "explode": true, + "in": "query", + "name": "subscription_cancel_at", + "required": false, + "schema": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" } - } + ] }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates an existing credit note.

", - "operationId": "PostCreditNotesId", - "parameters": [ + "style": "deepObject" + }, { - "in": "path", - "name": "id", - "required": true, + "description": "Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_at_period_end` instead.", + "in": "query", + "name": "subscription_cancel_at_period_end", + "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "type": "boolean" }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "memo": { - "description": "Credit note memo.", + "style": "form" + }, + { + "description": "This simulates the subscription being canceled or expired immediately. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_now` instead.", + "in": "query", + "name": "subscription_cancel_now", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set. This field has been deprecated and will be removed in a future API version. Use `subscription_details.default_tax_rates` instead.", + "explode": true, + "in": "query", + "name": "subscription_default_tax_rates", + "required": false, + "schema": { + "anyOf": [ + { + "items": { "maxLength": 5000, "type": "string" }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - } + "type": "array" }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/credit_note" + { + "enum": [""], + "type": "string" } - } + ] }, - "description": "Successful response." + "style": "deepObject" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/credit_notes/{id}/void": { - "post": { - "description": "

Marks a credit note as void. Learn more about voiding credit notes.

", - "operationId": "PostCreditNotesIdVoid", - "parameters": [ { - "in": "path", - "name": "id", - "required": true, + "description": "The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.", + "explode": true, + "in": "query", + "name": "subscription_details", + "required": false, "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { + "properties": { + "billing_cycle_anchor": { + "anyOf": [ + { + "enum": ["now", "unchanged"], "maxLength": 5000, "type": "string" }, - "type": "array" - } + { + "format": "unix-time", + "type": "integer" + } + ] }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/credit_note" + "cancel_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cancel_at_period_end": { + "type": "boolean" + }, + "cancel_now": { + "type": "boolean" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "items": { + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "clear_usage": { + "type": "boolean" + }, + "deleted": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "id": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "subscription_item_update_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "proration_date": { + "format": "unix-time", + "type": "integer" + }, + "resume_at": { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + "start_date": { + "format": "unix-time", + "type": "integer" + }, + "trial_end": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ] } - } + }, + "title": "subscription_details_params", + "type": "object" }, - "description": "Successful response." + "style": "deepObject" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/customers": { - "get": { - "description": "

Returns a list of your customers. The customers are returned sorted by creation date, with the most recent customers appearing first.

", - "operationId": "GetCustomers", - "parameters": [ { + "description": "A list of up to 20 subscription items, each with an attached price. This field has been deprecated and will be removed in a future API version. Use `subscription_details.items` instead.", "explode": true, "in": "query", - "name": "created", + "name": "subscription_items", "required": false, "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "clear_usage": { + "type": "boolean" + }, + "deleted": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "id": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } }, - "lte": { - "type": "integer" - } + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" }, - "title": "range_query_specs", - "type": "object" + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } }, - { - "type": "integer" - } - ] + "title": "subscription_item_update_params", + "type": "object" + }, + "type": "array" }, "style": "deepObject" }, { - "description": "A case-sensitive filter on the list based on the customer's `email` field. The value must be a string.", + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.proration_behavior` instead.", "in": "query", - "name": "email", + "name": "subscription_proration_behavior", "required": false, "schema": { - "maxLength": 512, + "enum": ["always_invoice", "create_prorations", "none"], "type": "string" }, "style": "form" }, { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "description": "If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'. This field has been deprecated and will be removed in a future API version. Use `subscription_details.proration_date` instead.", "in": "query", - "name": "ending_before", + "name": "subscription_proration_date", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "format": "unix-time", + "type": "integer" }, "style": "form" }, { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, + "description": "For paused subscriptions, setting `subscription_resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed. This field has been deprecated and will be removed in a future API version. Use `subscription_details.resume_at` instead.", "in": "query", - "name": "expand", + "name": "subscription_resume_at", "required": false, "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "enum": ["now"], + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "form" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "description": "Date a subscription is intended to start (can be future or past). This field has been deprecated and will be removed in a future API version. Use `subscription_details.start_date` instead.", "in": "query", - "name": "limit", + "name": "subscription_start_date", "required": false, "schema": { + "format": "unix-time", "type": "integer" }, "style": "form" }, { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required. This field has been deprecated and will be removed in a future API version. Use `subscription_details.trial_end` instead.", + "explode": true, "in": "query", - "name": "starting_after", + "name": "subscription_trial_end", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ] }, - "style": "form" + "style": "deepObject" } ], "requestBody": { @@ -41964,6 +86447,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -41979,8 +86463,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/line_item" }, "type": "array" }, @@ -41996,11 +86481,11 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/customers", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "InvoiceLinesList", "type": "object", "x-expandableFields": ["data"] } @@ -42019,360 +86504,16 @@ "description": "Error response." } } - }, - "post": { - "description": "

Creates a new customer object.

", - "operationId": "PostCustomers", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "address": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "invoice_settings": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "preferred_locales": { - "explode": true, - "style": "deepObject" - }, - "shipping": { - "explode": true, - "style": "deepObject" - }, - "tax_id_data": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "address": { - "anyOf": [ - { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "optional_fields_address", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The customer's address." - }, - "balance": { - "description": "An integer amount in %s that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.", - "type": "integer" - }, - "coupon": { - "maxLength": 5000, - "type": "string" - }, - "description": { - "description": "An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.", - "maxLength": 5000, - "type": "string" - }, - "email": { - "description": "Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.", - "maxLength": 512, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "invoice_prefix": { - "description": "The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.", - "maxLength": 5000, - "type": "string" - }, - "invoice_settings": { - "description": "Default invoice settings for this customer.", - "properties": { - "custom_fields": { - "anyOf": [ - { - "items": { - "properties": { - "name": { - "maxLength": 30, - "type": "string" - }, - "value": { - "maxLength": 30, - "type": "string" - } - }, - "required": ["name", "value"], - "title": "custom_field_params", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "default_payment_method": { - "maxLength": 5000, - "type": "string" - }, - "footer": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "customer_param", - "type": "object" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "name": { - "description": "The customer's full name or business name.", - "maxLength": 256, - "type": "string" - }, - "next_invoice_sequence": { - "description": "The sequence to be used on the customer's next invoice. Defaults to 1.", - "type": "integer" - }, - "payment_method": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "description": "The customer's phone number.", - "maxLength": 20, - "type": "string" - }, - "preferred_locales": { - "description": "Customer's preferred languages, ordered by preference.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "promotion_code": { - "description": "The API ID of a promotion code to apply to the customer. The customer will have a discount applied on all recurring payments. Charges you create through the API will not have the discount.", - "maxLength": 5000, - "type": "string" - }, - "shipping": { - "anyOf": [ - { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["line1"], - "title": "address", - "type": "object" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["address", "name"], - "title": "customer_shipping", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The customer's shipping information. Appears on invoices emailed to this customer." - }, - "source": { - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "tax_exempt": { - "description": "The customer's tax exemption. One of `none`, `exempt`, or `reverse`.", - "enum": ["", "exempt", "none", "reverse"], - "type": "string" - }, - "tax_id_data": { - "description": "The customer's tax IDs.", - "items": { - "properties": { - "type": { - "enum": [ - "ae_trn", - "au_abn", - "br_cnpj", - "br_cpf", - "ca_bn", - "ca_qst", - "ch_vat", - "cl_tin", - "es_cif", - "eu_vat", - "gb_vat", - "hk_br", - "id_npwp", - "in_gst", - "jp_cn", - "jp_rn", - "kr_brn", - "li_uid", - "mx_rfc", - "my_frp", - "my_itn", - "my_sst", - "no_vat", - "nz_gst", - "ru_inn", - "ru_kpp", - "sa_vat", - "sg_gst", - "sg_uen", - "th_vat", - "tw_vat", - "us_ein", - "za_vat" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "value": { - "type": "string" - } - }, - "required": ["type", "value"], - "title": "data_params", - "type": "object" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/customer" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } } }, - "/v1/customers/{customer}": { + "/v1/invoices/{invoice}": { "delete": { - "description": "

Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.

", - "operationId": "DeleteCustomersCustomer", + "description": "

Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be voided.

", + "operationId": "DeleteInvoicesInvoice", "parameters": [ { "in": "path", - "name": "customer", + "name": "invoice", "required": true, "schema": { "maxLength": 5000, @@ -42386,6 +86527,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -42398,7 +86540,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_customer" + "$ref": "#/components/schemas/deleted_invoice" } } }, @@ -42417,19 +86559,9 @@ } }, "get": { - "description": "

Retrieves the details of an existing customer. You need only supply the unique customer identifier that was returned upon customer creation.

", - "operationId": "GetCustomersCustomer", + "description": "

Retrieves the invoice with the given ID.

", + "operationId": "GetInvoicesInvoice", "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -42444,6 +86576,16 @@ "type": "array" }, "style": "deepObject" + }, + { + "in": "path", + "name": "invoice", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" } ], "requestBody": { @@ -42451,6 +86593,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -42463,14 +86606,7 @@ "content": { "application/json": { "schema": { - "anyOf": [ - { - "$ref": "#/components/schemas/customer" - }, - { - "$ref": "#/components/schemas/deleted_customer" - } - ] + "$ref": "#/components/schemas/invoice" } } }, @@ -42489,12 +86625,12 @@ } }, "post": { - "description": "

Updates the specified customer by setting the values of the parameters passed. Any parameters not provided will be left unchanged. For example, if you pass the source parameter, that becomes the customer’s active source (e.g., a card) to be used for all charges in the future. When you update a customer to a new valid card source by passing the source parameter: for each of the customer’s current subscriptions, if the subscription bills automatically and is in the past_due state, then the latest open invoice for the subscription with automatic collection enabled will be retried. This retry will not count as an automatic retry, and will not affect the next regularly scheduled payment for the invoice. Changing the default_source for a customer will not trigger this behavior.

\n\n

This request accepts mostly the same arguments as the customer creation call.

", - "operationId": "PostCustomersCustomer", + "description": "

Draft invoices are fully editable. Once an invoice is finalized,\nmonetary values, as well as collection_method, become uneditable.

\n\n

If you would like to stop the Stripe Billing engine from automatically finalizing, reattempting payments on,\nsending reminders for, or automatically reconciling invoices, pass\nauto_advance=false.

", + "operationId": "PostInvoicesInvoice", "parameters": [ { "in": "path", - "name": "customer", + "name": "invoice", "required": true, "schema": { "maxLength": 5000, @@ -42507,15 +86643,31 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "address": { + "account_tax_ids": { "explode": true, "style": "deepObject" }, - "bank_account": { + "automatic_tax": { "explode": true, "style": "deepObject" }, - "card": { + "custom_fields": { + "explode": true, + "style": "deepObject" + }, + "default_source": { + "explode": true, + "style": "deepObject" + }, + "default_tax_rates": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, + "effective_at": { "explode": true, "style": "deepObject" }, @@ -42523,7 +86675,7 @@ "explode": true, "style": "deepObject" }, - "invoice_settings": { + "issuer": { "explode": true, "style": "deepObject" }, @@ -42531,212 +86683,209 @@ "explode": true, "style": "deepObject" }, - "preferred_locales": { + "number": { "explode": true, "style": "deepObject" }, - "shipping": { + "on_behalf_of": { "explode": true, "style": "deepObject" }, - "trial_end": { + "payment_settings": { + "explode": true, + "style": "deepObject" + }, + "rendering": { + "explode": true, + "style": "deepObject" + }, + "shipping_cost": { + "explode": true, + "style": "deepObject" + }, + "shipping_details": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "address": { + "account_tax_ids": { "anyOf": [ { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } + "items": { + "maxLength": 5000, + "type": "string" }, - "title": "optional_fields_address", - "type": "object" + "type": "array" }, { "enum": [""], "type": "string" } ], - "description": "The customer's address." + "description": "The account tax IDs associated with the invoice. Only editable when the invoice is a draft." }, - "balance": { - "description": "An integer amount in %s that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.", + "application_fee_amount": { + "description": "A fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).", "type": "integer" }, - "bank_account": { - "anyOf": [ - { + "auto_advance": { + "description": "Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice.", + "type": "boolean" + }, + "automatic_tax": { + "description": "Settings for automatic tax lookup for this invoice.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { "properties": { - "account_holder_name": { - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "type": "string" - }, - "object": { - "enum": ["bank_account"], - "maxLength": 5000, + "account": { "type": "string" }, - "routing_number": { - "maxLength": 5000, + "type": { + "enum": ["account", "self"], "type": "string" } }, - "required": ["account_number", "country"], - "title": "customer_payment_source_bank_account", + "required": ["type"], + "title": "param", "type": "object" - }, - { - "maxLength": 5000, - "type": "string" } - ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." + }, + "required": ["enabled"], + "title": "automatic_tax_param", + "type": "object" }, - "card": { + "collection_method": { + "description": "Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "custom_fields": { "anyOf": [ { - "properties": { - "address_city": { - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "maxLength": 5000, - "type": "string" - }, - "cvc": { - "maxLength": 5000, - "type": "string" - }, - "exp_month": { - "type": "integer" - }, - "exp_year": { - "type": "integer" - }, - "metadata": { - "additionalProperties": { + "items": { + "properties": { + "name": { + "maxLength": 40, "type": "string" }, - "type": "object" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "number": { - "maxLength": 5000, - "type": "string" + "value": { + "maxLength": 140, + "type": "string" + } }, - "object": { - "enum": ["card"], - "maxLength": 5000, - "type": "string" - } + "required": ["name", "value"], + "title": "custom_field_params", + "type": "object" }, - "required": ["exp_month", "exp_year", "number"], - "title": "customer_payment_source_card", - "type": "object" + "type": "array" }, { - "maxLength": 5000, + "enum": [""], "type": "string" } ], - "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js).", - "x-stripeBypassValidation": true + "description": "A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields." }, - "coupon": { + "days_until_due": { + "description": "The number of days from which the invoice is created until it is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.", + "type": "integer" + }, + "default_payment_method": { + "description": "ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.", "maxLength": 5000, "type": "string" }, - "default_alipay_account": { - "description": "ID of Alipay account to make the customer's new default for invoice payments.", - "maxLength": 500, - "type": "string" + "default_source": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source." }, - "default_bank_account": { - "description": "ID of bank account to make the customer's new default for invoice payments.", - "maxLength": 500, - "type": "string" + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The tax rates that will apply to any line item that does not have `tax_rates` set. Pass an empty string to remove previously-defined tax rates." }, - "default_card": { - "description": "ID of card to make the customer's new default for invoice payments.", - "maxLength": 500, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.", + "maxLength": 1500, "type": "string" }, - "default_source": { - "description": "If you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method) parameter.\n\nProvide the ID of a payment source already attached to this customer to make it this customer's default payment source.\n\nIf you want to add a new payment source and make it the default, see the [source](https://stripe.com/docs/api/customers/update#update_customer-source) property.", - "maxLength": 500, - "type": "string" + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The discounts that will apply to the invoice. Pass an empty string to remove previously-defined discounts." }, - "description": { - "description": "An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.", - "maxLength": 5000, - "type": "string" + "due_date": { + "description": "The date on which payment for this invoice is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.", + "format": "unix-time", + "type": "integer" }, - "email": { - "description": "Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.", - "maxLength": 512, - "type": "string" + "effective_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt." }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -42746,31 +86895,360 @@ }, "type": "array" }, - "invoice_prefix": { - "description": "The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.", + "footer": { + "description": "Footer to be displayed on the invoice.", "maxLength": 5000, "type": "string" }, - "invoice_settings": { - "description": "Default invoice settings for this customer.", + "issuer": { + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", "properties": { - "custom_fields": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "number": { + "anyOf": [ + { + "maxLength": 26, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically." + }, + "on_behalf_of": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details." + }, + "payment_settings": { + "description": "Configuration settings for the PaymentIntent that is generated when the invoice is finalized.", + "properties": { + "default_mandate": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "payment_method_options": { + "properties": { + "acss_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bancontact": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": ["de", "en", "fr", "nl"], + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card": { + "anyOf": [ + { + "properties": { + "installments": { + "properties": { + "enabled": { + "type": "boolean" + }, + "plan": { + "anyOf": [ + { + "properties": { + "count": { + "type": "integer" + }, + "interval": { + "enum": ["month"], + "type": "string" + }, + "type": { + "enum": ["fixed_count"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "installment_plan", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "installments_param", + "type": "object" + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "customer_balance": { + "anyOf": [ + { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_param", + "type": "object" + }, + "type": { + "type": "string" + } + }, + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "konbini": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "type": "string" + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_method_options", + "type": "object" + }, + "payment_method_types": { "anyOf": [ { "items": { - "properties": { - "name": { - "maxLength": 30, - "type": "string" - }, - "value": { - "maxLength": 30, - "type": "string" - } - }, - "required": ["name", "value"], - "title": "custom_field_params", - "type": "object" + "enum": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "konbini", + "link", + "multibanco", + "p24", + "paynow", + "paypal", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "us_bank_account", + "wechat_pay" + ], + "type": "string", + "x-stripeBypassValidation": true }, "type": "array" }, @@ -42779,25 +87257,154 @@ "type": "string" } ] - }, - "default_payment_method": { - "maxLength": 5000, + } + }, + "title": "payment_settings", + "type": "object" + }, + "rendering": { + "description": "The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.", + "properties": { + "amount_tax_display": { + "enum": ["", "exclude_tax", "include_inclusive_tax"], "type": "string" }, - "footer": { - "maxLength": 5000, - "type": "string" + "pdf": { + "properties": { + "page_size": { + "enum": ["a4", "auto", "letter"], + "type": "string" + } + }, + "title": "rendering_pdf_param", + "type": "object" } }, - "title": "customer_param", + "title": "rendering_param", "type": "object" }, - "metadata": { + "shipping_cost": { "anyOf": [ { - "additionalProperties": { - "type": "string" + "properties": { + "shipping_rate": { + "maxLength": 5000, + "type": "string" + }, + "shipping_rate_data": { + "properties": { + "delivery_estimate": { + "properties": { + "maximum": { + "properties": { + "unit": { + "enum": [ + "business_day", + "day", + "hour", + "month", + "week" + ], + "type": "string" + }, + "value": { + "type": "integer" + } + }, + "required": ["unit", "value"], + "title": "delivery_estimate_bound", + "type": "object" + }, + "minimum": { + "properties": { + "unit": { + "enum": [ + "business_day", + "day", + "hour", + "month", + "week" + ], + "type": "string" + }, + "value": { + "type": "integer" + } + }, + "required": ["unit", "value"], + "title": "delivery_estimate_bound", + "type": "object" + } + }, + "title": "delivery_estimate", + "type": "object" + }, + "display_name": { + "maxLength": 100, + "type": "string" + }, + "fixed_amount": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + }, + "currency_options": { + "additionalProperties": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + } + }, + "required": ["amount"], + "title": "currency_option", + "type": "object" + }, + "type": "object" + } + }, + "required": ["amount", "currency"], + "title": "fixed_amount", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "tax_code": { + "type": "string" + }, + "type": { + "enum": ["fixed_amount"], + "type": "string" + } + }, + "required": ["display_name"], + "title": "method_params", + "type": "object" + } }, + "title": "shipping_cost", "type": "object" }, { @@ -42805,36 +87412,9 @@ "type": "string" } ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "name": { - "description": "The customer's full name or business name.", - "maxLength": 256, - "type": "string" - }, - "next_invoice_sequence": { - "description": "The sequence to be used on the customer's next invoice. Defaults to 1.", - "type": "integer" + "description": "Settings for the cost of shipping for this invoice." }, - "phone": { - "description": "The customer's phone number.", - "maxLength": 20, - "type": "string" - }, - "preferred_locales": { - "description": "Customer's preferred languages, ordered by preference.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "promotion_code": { - "description": "The API ID of a promotion code to apply to the customer. The customer will have a discount applied on all recurring payments. Charges you create through the API will not have the discount.", - "maxLength": 5000, - "type": "string" - }, - "shipping": { + "shipping_details": { "anyOf": [ { "properties": { @@ -42865,8 +87445,7 @@ "type": "string" } }, - "required": ["line1"], - "title": "address", + "title": "optional_fields_address", "type": "object" }, "name": { @@ -42874,12 +87453,20 @@ "type": "string" }, "phone": { - "maxLength": 5000, - "type": "string" + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] } }, "required": ["address", "name"], - "title": "customer_shipping", + "title": "recipient_shipping_with_optional_fields_address", "type": "object" }, { @@ -42887,31 +87474,439 @@ "type": "string" } ], - "description": "The customer's shipping information. Appears on invoices emailed to this customer." - }, - "source": { - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "description": "Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer." }, - "tax_exempt": { - "description": "The customer's tax exemption. One of `none`, `exempt`, or `reverse`.", - "enum": ["", "exempt", "none", "reverse"], + "statement_descriptor": { + "description": "Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.", + "maxLength": 22, "type": "string" }, - "trial_end": { - "anyOf": [ - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - }, - { - "format": "unix-time", - "type": "integer" - } - ], - "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`." + "transfer_data": { + "anyOf": [ + { + "properties": { + "amount": { + "type": "integer" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge. This will be unset if you POST an empty value." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/invoice" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/invoices/{invoice}/add_lines": { + "post": { + "description": "

Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.

", + "operationId": "PostInvoicesInvoiceAddLines", + "parameters": [ + { + "in": "path", + "name": "invoice", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "invoice_metadata": { + "explode": true, + "style": "deepObject" + }, + "lines": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "invoice_metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "lines": { + "description": "The line items to add.", + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "discountable": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "invoice_item": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "period": { + "properties": { + "end": { + "format": "unix-time", + "type": "integer" + }, + "start": { + "format": "unix-time", + "type": "integer" + } + }, + "required": ["end", "start"], + "title": "period", + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "product_data": { + "properties": { + "description": { + "maxLength": 40000, + "type": "string" + }, + "images": { + "items": { + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "tax_code": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["name"], + "title": "product_data", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency"], + "title": "one_time_price_data_with_product_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_amounts": { + "anyOf": [ + { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_rate_data": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "display_name": { + "maxLength": 50, + "type": "string" + }, + "inclusive": { + "type": "boolean" + }, + "jurisdiction": { + "maxLength": 200, + "type": "string" + }, + "percentage": { + "type": "number" + }, + "state": { + "maxLength": 2, + "type": "string" + }, + "tax_type": { + "enum": [ + "amusement_tax", + "communications_tax", + "gst", + "hst", + "igst", + "jct", + "lease_tax", + "pst", + "qst", + "rst", + "sales_tax", + "vat" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "display_name", + "inclusive", + "percentage" + ], + "title": "tax_rate_data_param", + "type": "object" + }, + "taxable_amount": { + "type": "integer" + } + }, + "required": [ + "amount", + "tax_rate_data", + "taxable_amount" + ], + "title": "tax_amount_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "lines_data_param", + "type": "object" + }, + "type": "array" + } + }, + "required": ["lines"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/invoice" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/invoices/{invoice}/finalize": { + "post": { + "description": "

Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you’d like to finalize a draft invoice manually, you can do so using this method.

", + "operationId": "PostInvoicesInvoiceFinalize", + "parameters": [ + { + "in": "path", + "name": "invoice", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "auto_advance": { + "description": "Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice. If `false`, the invoice's state doesn't automatically advance without an explicit action.", + "type": "boolean" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" } }, "type": "object" @@ -42925,7 +87920,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/customer" + "$ref": "#/components/schemas/invoice" } } }, @@ -42944,21 +87939,11 @@ } } }, - "/v1/customers/{customer}/balance_transactions": { + "/v1/invoices/{invoice}/lines": { "get": { - "description": "

Returns a list of transactions that updated the customer’s balances.

", - "operationId": "GetCustomersCustomerBalanceTransactions", + "description": "

When retrieving an invoice, you’ll get a lines property containing the total count of line items and the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", + "operationId": "GetInvoicesInvoiceLines", "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -42985,6 +87970,16 @@ }, "style": "deepObject" }, + { + "in": "path", + "name": "invoice", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, { "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", @@ -43012,6 +88007,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -43029,7 +88025,7 @@ "data": { "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/customer_balance_transaction" + "$ref": "#/components/schemas/line_item" }, "type": "array" }, @@ -43049,7 +88045,7 @@ } }, "required": ["data", "has_more", "object", "url"], - "title": "CustomerBalanceTransactionList", + "title": "InvoiceLinesList", "type": "object", "x-expandableFields": ["data"] } @@ -43068,14 +88064,28 @@ "description": "Error response." } } - }, + } + }, + "/v1/invoices/{invoice}/lines/{line_item_id}": { "post": { - "description": "

Creates an immutable transaction that updates the customer’s credit balance.

", - "operationId": "PostCustomersCustomerBalanceTransactions", + "description": "

Updates an invoice’s line item. Some fields, such as tax_amounts, only live on the invoice line item,\nso they can only be updated through this endpoint. Other fields, such as amount, live on both the invoice\nitem and the invoice line item, so updates on this endpoint will propagate to the invoice item as well.\nUpdating an invoice’s line item is only possible before the invoice is finalized.

", + "operationId": "PostInvoicesInvoiceLinesLineItemId", "parameters": [ { + "description": "Invoice ID of line item", "in": "path", - "name": "customer", + "name": "invoice", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Invoice line item ID", + "in": "path", + "name": "line_item_id", "required": true, "schema": { "maxLength": 5000, @@ -43088,6 +88098,10 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { + "discounts": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" @@ -43095,23 +88109,70 @@ "metadata": { "explode": true, "style": "deepObject" + }, + "period": { + "explode": true, + "style": "deepObject" + }, + "price_data": { + "explode": true, + "style": "deepObject" + }, + "tax_amounts": { + "explode": true, + "style": "deepObject" + }, + "tax_rates": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "amount": { - "description": "The integer amount in **%s** to apply to the customer's credit balance.", + "description": "The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). If the customer's [`currency`](https://stripe.com/docs/api/customers/object#customer_object-currency) is set, this value must match it. If the customer's `currency` is not set, it will be updated to this value.", - "type": "string" - }, "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 350, + "description": "An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.", + "maxLength": 5000, "type": "string" }, + "discountable": { + "description": "Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.", + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts." + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -43133,22 +88194,203 @@ "type": "string" } ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data." + }, + "period": { + "description": "The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.", + "properties": { + "end": { + "format": "unix-time", + "type": "integer" + }, + "start": { + "format": "unix-time", + "type": "integer" + } + }, + "required": ["end", "start"], + "title": "period", + "type": "object" + }, + "price": { + "description": "The ID of the price object. One of `price` or `price_data` is required.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.", + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "product_data": { + "properties": { + "description": { + "maxLength": 40000, + "type": "string" + }, + "images": { + "items": { + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "tax_code": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["name"], + "title": "product_data", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency"], + "title": "one_time_price_data_with_product_data", + "type": "object" + }, + "quantity": { + "description": "Non-negative integer. The quantity of units for the line item.", + "type": "integer" + }, + "tax_amounts": { + "anyOf": [ + { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_rate_data": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "display_name": { + "maxLength": 50, + "type": "string" + }, + "inclusive": { + "type": "boolean" + }, + "jurisdiction": { + "maxLength": 200, + "type": "string" + }, + "percentage": { + "type": "number" + }, + "state": { + "maxLength": 2, + "type": "string" + }, + "tax_type": { + "enum": [ + "amusement_tax", + "communications_tax", + "gst", + "hst", + "igst", + "jct", + "lease_tax", + "pst", + "qst", + "rst", + "sales_tax", + "vat" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "display_name", + "inclusive", + "percentage" + ], + "title": "tax_rate_data_param", + "type": "object" + }, + "taxable_amount": { + "type": "integer" + } + }, + "required": [ + "amount", + "tax_rate_data", + "taxable_amount" + ], + "title": "tax_amount_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts." + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates." } }, - "required": ["amount", "currency"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/customer_balance_transaction" + "$ref": "#/components/schemas/line_item" } } }, @@ -43167,98 +88409,14 @@ } } }, - "/v1/customers/{customer}/balance_transactions/{transaction}": { - "get": { - "description": "

Retrieves a specific customer balance transaction that updated the customer’s balances.

", - "operationId": "GetCustomersCustomerBalanceTransactionsTransaction", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "transaction", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/customer_balance_transaction" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, + "/v1/invoices/{invoice}/mark_uncollectible": { "post": { - "description": "

Most credit balance transaction fields are immutable, but you may update its description and metadata.

", - "operationId": "PostCustomersCustomerBalanceTransactionsTransaction", + "description": "

Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes.

", + "operationId": "PostInvoicesInvoiceMarkUncollectible", "parameters": [ { "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "transaction", + "name": "invoice", "required": true, "schema": { "maxLength": 5000, @@ -43274,19 +88432,11 @@ "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 350, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -43294,21 +88444,6 @@ "type": "string" }, "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." } }, "type": "object" @@ -43322,7 +88457,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/customer_balance_transaction" + "$ref": "#/components/schemas/invoice" } } }, @@ -43341,137 +88476,14 @@ } } }, - "/v1/customers/{customer}/bank_accounts": { - "get": { - "deprecated": true, - "description": "

You can see a list of the bank accounts belonging to a Customer. Note that the 10 most recent sources are always available by default on the Customer. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional bank accounts.

", - "operationId": "GetCustomersCustomerBankAccounts", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/bank_account" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "BankAccountList", - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, + "/v1/invoices/{invoice}/pay": { "post": { - "description": "

When you create a new credit card, you must specify a customer or recipient on which to create it.

\n\n

If the card’s owner has no default card, then the new card will become the default.\nHowever, if the owner already has a default, then it will not change.\nTo change the default, you should update the customer to have a new default_source.

", - "operationId": "PostCustomersCustomerBankAccounts", + "description": "

Stripe automatically creates and then attempts to collect payment on invoices for customers on subscriptions according to your subscriptions settings. However, if you’d like to attempt payment on an invoice out of the normal collection schedule or for some other reason, you can do so.

", + "operationId": "PostInvoicesInvoicePay", "parameters": [ { "in": "path", - "name": "customer", + "name": "invoice", "required": true, "schema": { "maxLength": 5000, @@ -43484,165 +88496,60 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "bank_account": { - "explode": true, - "style": "deepObject" - }, - "card": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" }, - "metadata": { + "mandate": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "alipay_account": { - "description": "A token returned by [Stripe.js](https://stripe.com/docs/stripe.js) representing the user’s Alipay account details.", - "maxLength": 5000, - "type": "string" + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "bank_account": { + "forgive": { + "description": "In cases where the source used to pay the invoice has insufficient funds, passing `forgive=true` controls whether a charge should be attempted for the full amount available on the source, up to the amount to fully pay the invoice. This effectively forgives the difference between the amount available on the source and the amount due. \n\nPassing `forgive=false` will fail the charge if the source hasn't been pre-funded with the right amount. An example for this case is with ACH Credit Transfers and wires: if the amount wired is less than the amount due by a small amount, you might want to forgive the difference. Defaults to `false`.", + "type": "boolean" + }, + "mandate": { "anyOf": [ - { - "properties": { - "account_holder_name": { - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "type": "string" - }, - "object": { - "enum": ["bank_account"], - "maxLength": 5000, - "type": "string" - }, - "routing_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "country"], - "title": "customer_payment_source_bank_account", - "type": "object" - }, { "maxLength": 5000, "type": "string" - } - ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." - }, - "card": { - "anyOf": [ - { - "properties": { - "address_city": { - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "maxLength": 5000, - "type": "string" - }, - "cvc": { - "maxLength": 5000, - "type": "string" - }, - "exp_month": { - "type": "integer" - }, - "exp_year": { - "type": "integer" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "number": { - "maxLength": 5000, - "type": "string" - }, - "object": { - "enum": ["card"], - "maxLength": 5000, - "type": "string" - } - }, - "required": ["exp_month", "exp_year", "number"], - "title": "customer_payment_source_card", - "type": "object" }, { - "maxLength": 5000, + "enum": [""], "type": "string" } ], - "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js).", - "x-stripeBypassValidation": true + "description": "ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the payment_method param or the invoice's default_payment_method or default_source, if set." }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "off_session": { + "description": "Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `true` (off-session).", + "type": "boolean" }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" + "paid_out_of_band": { + "description": "Boolean representing whether an invoice is paid outside of Stripe. This will result in no charge being made. Defaults to `false`.", + "type": "boolean" + }, + "payment_method": { + "description": "A PaymentMethod to be charged. The PaymentMethod must be the ID of a PaymentMethod belonging to the customer associated with the invoice being paid.", + "maxLength": 5000, + "type": "string" }, "source": { - "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", + "description": "A payment source to be charged. The source must be the ID of a source belonging to the customer associated with the invoice being paid.", "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" } }, "type": "object" @@ -43656,7 +88563,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_source" + "$ref": "#/components/schemas/invoice" } } }, @@ -43675,29 +88582,20 @@ } } }, - "/v1/customers/{customer}/bank_accounts/{id}": { - "delete": { - "description": "

Delete a specified source for a given customer.

", - "operationId": "DeleteCustomersCustomerBankAccountsId", + "/v1/invoices/{invoice}/remove_lines": { + "post": { + "description": "

Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.

", + "operationId": "PostInvoicesInvoiceRemoveLines", "parameters": [ { "in": "path", - "name": "customer", + "name": "invoice", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" } ], "requestBody": { @@ -43707,9 +88605,18 @@ "expand": { "explode": true, "style": "deepObject" + }, + "invoice_metadata": { + "explode": true, + "style": "deepObject" + }, + "lines": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -43718,27 +88625,55 @@ "type": "string" }, "type": "array" + }, + "invoice_metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "lines": { + "description": "The line items to remove.", + "items": { + "properties": { + "behavior": { + "enum": ["delete", "unassign"], + "type": "string" + }, + "id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["behavior", "id"], + "title": "lines_data_param", + "type": "object" + }, + "type": "array" } }, + "required": ["lines"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "anyOf": [ - { - "$ref": "#/components/schemas/payment_source" - }, - { - "$ref": "#/components/schemas/deleted_payment_source" - } - ] + "$ref": "#/components/schemas/invoice" } } }, @@ -43755,40 +88690,16 @@ "description": "Error response." } } - }, - "get": { - "deprecated": true, - "description": "

By default, you can see the 10 most recent sources stored on a Customer directly on the object, but you can also retrieve details about a specific bank account stored on the Stripe account.

", - "operationId": "GetCustomersCustomerBankAccountsId", + } + }, + "/v1/invoices/{invoice}/send": { + "post": { + "description": "

Stripe will automatically send invoices to customers according to your subscriptions settings. However, if you’d like to manually send an invoice to your customer out of the normal schedule, you can do so. When sending invoices that have already been paid, there will be no reference to the payment in the email.

\n\n

Requests made in test-mode result in no emails being sent, despite sending an invoice.sent event.

", + "operationId": "PostInvoicesInvoiceSend", "parameters": [ { "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "id", + "name": "invoice", "required": true, "schema": { "maxLength": 5000, @@ -43800,9 +88711,24 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -43814,7 +88740,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/bank_account" + "$ref": "#/components/schemas/invoice" } } }, @@ -43831,24 +88757,16 @@ "description": "Error response." } } - }, + } + }, + "/v1/invoices/{invoice}/update_lines": { "post": { - "description": "

Update a specified source for a given customer.

", - "operationId": "PostCustomersCustomerBankAccountsId", + "description": "

Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.

", + "operationId": "PostInvoicesInvoiceUpdateLines", "parameters": [ { "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "id", + "name": "invoice", "required": true, "schema": { "maxLength": 5000, @@ -43865,68 +88783,18 @@ "explode": true, "style": "deepObject" }, - "metadata": { + "invoice_metadata": { "explode": true, "style": "deepObject" }, - "owner": { + "lines": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "account_holder_name": { - "description": "The name of the person or business that owns the bank account.", - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "description": "The type of entity that holds the account. This can be either `individual` or `company`.", - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "address_city": { - "description": "City/District/Suburb/Town/Village.", - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "description": "Billing address country, if provided when creating card.", - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "description": "Address line 1 (Street address/PO Box/Company name).", - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "description": "Address line 2 (Apartment/Suite/Unit/Building).", - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "description": "State/County/Province/Region.", - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "description": "ZIP or postal code.", - "maxLength": 5000, - "type": "string" - }, - "exp_month": { - "description": "Two digit number representing the card’s expiration month.", - "maxLength": 5000, - "type": "string" - }, - "exp_year": { - "description": "Four digit number representing the card’s expiration year.", - "maxLength": 5000, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -43935,7 +88803,7 @@ }, "type": "array" }, - "metadata": { + "invoice_metadata": { "anyOf": [ { "additionalProperties": { @@ -43948,83 +88816,266 @@ "type": "string" } ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "name": { - "description": "Cardholder name.", - "maxLength": 5000, - "type": "string" + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data." }, - "owner": { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" + "lines": { + "description": "The line items to update.", + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "discountable": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "id": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "period": { + "properties": { + "end": { + "format": "unix-time", + "type": "integer" + }, + "start": { + "format": "unix-time", + "type": "integer" + } }, - "postal_code": { - "maxLength": 5000, - "type": "string" + "required": ["end", "start"], + "title": "period", + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "product_data": { + "properties": { + "description": { + "maxLength": 40000, + "type": "string" + }, + "images": { + "items": { + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "tax_code": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["name"], + "title": "product_data", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } }, - "state": { - "maxLength": 5000, - "type": "string" - } + "required": ["currency"], + "title": "one_time_price_data_with_product_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_amounts": { + "anyOf": [ + { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_rate_data": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "display_name": { + "maxLength": 50, + "type": "string" + }, + "inclusive": { + "type": "boolean" + }, + "jurisdiction": { + "maxLength": 200, + "type": "string" + }, + "percentage": { + "type": "number" + }, + "state": { + "maxLength": 2, + "type": "string" + }, + "tax_type": { + "enum": [ + "amusement_tax", + "communications_tax", + "gst", + "hst", + "igst", + "jct", + "lease_tax", + "pst", + "qst", + "rst", + "sales_tax", + "vat" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "display_name", + "inclusive", + "percentage" + ], + "title": "tax_rate_data_param", + "type": "object" + }, + "taxable_amount": { + "type": "integer" + } + }, + "required": [ + "amount", + "tax_rate_data", + "taxable_amount" + ], + "title": "tax_amount_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "title": "source_address", - "type": "object" - }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } }, - "phone": { - "maxLength": 5000, - "type": "string" - } + "required": ["id"], + "title": "lines_data_param", + "type": "object" }, - "title": "owner", - "type": "object" + "type": "array" } }, + "required": ["lines"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "anyOf": [ - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/source" - } - ] + "$ref": "#/components/schemas/invoice" } } }, @@ -44043,24 +89094,14 @@ } } }, - "/v1/customers/{customer}/bank_accounts/{id}/verify": { + "/v1/invoices/{invoice}/void": { "post": { - "description": "

Verify a specified bank account for a given customer.

", - "operationId": "PostCustomersCustomerBankAccountsIdVerify", + "description": "

Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to deletion, however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.

\n\n

Consult with local regulations to determine whether and how an invoice might be amended, canceled, or voided in the jurisdiction you’re doing business in. You might need to issue another invoice or credit note instead. Stripe recommends that you consult with your legal counsel for advice specific to your business.

", + "operationId": "PostInvoicesInvoiceVoid", "parameters": [ { "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "id", + "name": "invoice", "required": true, "schema": { "maxLength": 5000, @@ -44073,24 +89114,14 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "amounts": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "amounts": { - "description": "Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.", - "items": { - "type": "integer" - }, - "type": "array" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -44111,7 +89142,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/bank_account" + "$ref": "#/components/schemas/invoice" } } }, @@ -44130,21 +89161,65 @@ } } }, - "/v1/customers/{customer}/cards": { + "/v1/issuing/authorizations": { "get": { - "deprecated": true, - "description": "

You can see a list of the cards belonging to a customer.\nNote that the 10 most recent sources are always available on the Customer object.\nIf you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional cards.

", - "operationId": "GetCustomersCustomerCards", + "description": "

Returns a list of Issuing Authorization objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetIssuingAuthorizations", "parameters": [ { - "in": "path", - "name": "customer", - "required": true, + "description": "Only return authorizations that belong to the given card.", + "in": "query", + "name": "card", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" + }, + { + "description": "Only return authorizations that belong to the given cardholder.", + "in": "query", + "name": "cardholder", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return authorizations that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", @@ -44152,6 +89227,7 @@ "name": "ending_before", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" @@ -44187,6 +89263,18 @@ "name": "starting_after", "required": false, "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return authorizations with the given status. One of `pending`, `closed`, or `reversed`.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["closed", "pending", "reversed"], "type": "string" }, "style": "form" @@ -44197,6 +89285,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -44213,7 +89302,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/card" + "$ref": "#/components/schemas/issuing.authorization" }, "type": "array" }, @@ -44229,11 +89318,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, + "pattern": "^/v1/issuing/authorizations", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "CardList", + "title": "IssuingAuthorizationList", "type": "object", "x-expandableFields": ["data"] } @@ -44252,306 +89342,16 @@ "description": "Error response." } } - }, - "post": { - "description": "

When you create a new credit card, you must specify a customer or recipient on which to create it.

\n\n

If the card’s owner has no default card, then the new card will become the default.\nHowever, if the owner already has a default, then it will not change.\nTo change the default, you should update the customer to have a new default_source.

", - "operationId": "PostCustomersCustomerCards", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "bank_account": { - "explode": true, - "style": "deepObject" - }, - "card": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "alipay_account": { - "description": "A token returned by [Stripe.js](https://stripe.com/docs/stripe.js) representing the user’s Alipay account details.", - "maxLength": 5000, - "type": "string" - }, - "bank_account": { - "anyOf": [ - { - "properties": { - "account_holder_name": { - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "type": "string" - }, - "object": { - "enum": ["bank_account"], - "maxLength": 5000, - "type": "string" - }, - "routing_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "country"], - "title": "customer_payment_source_bank_account", - "type": "object" - }, - { - "maxLength": 5000, - "type": "string" - } - ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." - }, - "card": { - "anyOf": [ - { - "properties": { - "address_city": { - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "maxLength": 5000, - "type": "string" - }, - "cvc": { - "maxLength": 5000, - "type": "string" - }, - "exp_month": { - "type": "integer" - }, - "exp_year": { - "type": "integer" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "number": { - "maxLength": 5000, - "type": "string" - }, - "object": { - "enum": ["card"], - "maxLength": 5000, - "type": "string" - } - }, - "required": ["exp_month", "exp_year", "number"], - "title": "customer_payment_source_card", - "type": "object" - }, - { - "maxLength": 5000, - "type": "string" - } - ], - "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js).", - "x-stripeBypassValidation": true - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "source": { - "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/payment_source" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } } }, - "/v1/customers/{customer}/cards/{id}": { - "delete": { - "description": "

Delete a specified source for a given customer.

", - "operationId": "DeleteCustomersCustomerCardsId", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "anyOf": [ - { - "$ref": "#/components/schemas/payment_source" - }, - { - "$ref": "#/components/schemas/deleted_payment_source" - } - ] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, + "/v1/issuing/authorizations/{authorization}": { "get": { - "deprecated": true, - "description": "

You can always see the 10 most recent cards directly on a customer; this method lets you retrieve details about a specific card stored on the customer.

", - "operationId": "GetCustomersCustomerCardsId", + "description": "

Retrieves an Issuing Authorization object.

", + "operationId": "GetIssuingAuthorizationsAuthorization", "parameters": [ { "in": "path", - "name": "customer", + "name": "authorization", "required": true, "schema": { "maxLength": 5000, @@ -44573,16 +89373,6 @@ "type": "array" }, "style": "deepObject" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" } ], "requestBody": { @@ -44590,6 +89380,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -44602,7 +89393,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/card" + "$ref": "#/components/schemas/issuing.authorization" } } }, @@ -44621,22 +89412,12 @@ } }, "post": { - "description": "

Update a specified source for a given customer.

", - "operationId": "PostCustomersCustomerCardsId", + "description": "

Updates the specified Issuing Authorization object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", + "operationId": "PostIssuingAuthorizationsAuthorization", "parameters": [ { "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "id", + "name": "authorization", "required": true, "schema": { "maxLength": 5000, @@ -44656,65 +89437,11 @@ "metadata": { "explode": true, "style": "deepObject" - }, - "owner": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "account_holder_name": { - "description": "The name of the person or business that owns the bank account.", - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "description": "The type of entity that holds the account. This can be either `individual` or `company`.", - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "address_city": { - "description": "City/District/Suburb/Town/Village.", - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "description": "Billing address country, if provided when creating card.", - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "description": "Address line 1 (Street address/PO Box/Company name).", - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "description": "Address line 2 (Apartment/Suite/Unit/Building).", - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "description": "State/County/Province/Region.", - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "description": "ZIP or postal code.", - "maxLength": 5000, - "type": "string" - }, - "exp_month": { - "description": "Two digit number representing the card’s expiration month.", - "maxLength": 5000, - "type": "string" - }, - "exp_year": { - "description": "Four digit number representing the card’s expiration year.", - "maxLength": 5000, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -44737,58 +89464,6 @@ } ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "name": { - "description": "Cardholder name.", - "maxLength": 5000, - "type": "string" - }, - "owner": { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "source_address", - "type": "object" - }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "owner", - "type": "object" } }, "type": "object" @@ -44802,17 +89477,7 @@ "content": { "application/json": { "schema": { - "anyOf": [ - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/source" - } - ] + "$ref": "#/components/schemas/issuing.authorization" } } }, @@ -44831,14 +89496,15 @@ } } }, - "/v1/customers/{customer}/discount": { - "delete": { - "description": "

Removes the currently applied discount on a customer.

", - "operationId": "DeleteCustomersCustomerDiscount", + "/v1/issuing/authorizations/{authorization}/approve": { + "post": { + "deprecated": true, + "description": "

[Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the real-time authorization flow. \nThis method is deprecated. Instead, respond directly to the webhook request to approve an authorization.

", + "operationId": "PostIssuingAuthorizationsAuthorizationApprove", "parameters": [ { "in": "path", - "name": "customer", + "name": "authorization", "required": true, "schema": { "maxLength": 5000, @@ -44850,9 +89516,47 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "amount": { + "description": "If the authorization's `pending_request.is_amount_controllable` property is `true`, you may provide this value to control how much to hold for the authorization. Must be positive (use [`decline`](https://stripe.com/docs/api/issuing/authorizations/decline) to decline an authorization request).", + "type": "integer" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, "type": "object" } } @@ -44864,7 +89568,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_discount" + "$ref": "#/components/schemas/issuing.authorization" } } }, @@ -44881,43 +89585,65 @@ "description": "Error response." } } - }, - "get": { - "description": "", - "operationId": "GetCustomersCustomerDiscount", + } + }, + "/v1/issuing/authorizations/{authorization}/decline": { + "post": { + "deprecated": true, + "description": "

[Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the real time authorization flow.\nThis method is deprecated. Instead, respond directly to the webhook request to decline an authorization.

", + "operationId": "PostIssuingAuthorizationsAuthorizationDecline", "parameters": [ { "in": "path", - "name": "customer", + "name": "authorization", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, "type": "object" } } @@ -44929,7 +89655,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/discount" + "$ref": "#/components/schemas/issuing.authorization" } } }, @@ -44948,20 +89674,53 @@ } } }, - "/v1/customers/{customer}/sources": { + "/v1/issuing/cardholders": { "get": { - "description": "

List sources for a specified customer.

", - "operationId": "GetCustomersCustomerSources", + "description": "

Returns a list of Issuing Cardholder objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetIssuingCardholders", "parameters": [ { - "in": "path", - "name": "customer", - "required": true, + "description": "Only return cardholders that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return cardholders that have the given email address.", + "in": "query", + "name": "email", + "required": false, "schema": { - "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", @@ -44969,6 +89728,7 @@ "name": "ending_before", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" @@ -44999,12 +89759,11 @@ "style": "form" }, { - "description": "Filter sources according to a particular object type.", + "description": "Only return cardholders that have the given phone number.", "in": "query", - "name": "object", + "name": "phone_number", "required": false, "schema": { - "maxLength": 5000, "type": "string" }, "style": "form" @@ -45015,9 +89774,33 @@ "name": "starting_after", "required": false, "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return cardholders that have the given status. One of `active`, `inactive`, or `blocked`.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["active", "blocked", "inactive"], "type": "string" }, "style": "form" + }, + { + "description": "Only return cardholders that have the given type. One of `individual` or `company`.", + "in": "query", + "name": "type", + "required": false, + "schema": { + "enum": ["company", "individual"], + "type": "string", + "x-stripeBypassValidation": true + }, + "style": "form" } ], "requestBody": { @@ -45025,6 +89808,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -45040,26 +89824,8 @@ "description": "", "properties": { "data": { - "description": "Details about each object.", "items": { - "anyOf": [ - { - "$ref": "#/components/schemas/alipay_account" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/bitcoin_receiver" - }, - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/source" - } - ], - "title": "Polymorphic" + "$ref": "#/components/schemas/issuing.cardholder" }, "type": "array" }, @@ -45075,11 +89841,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, + "pattern": "^/v1/issuing/cardholders", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "ApmsSourcesSourceList", + "title": "IssuingCardholderList", "type": "object", "x-expandableFields": ["data"] } @@ -45100,29 +89867,17 @@ } }, "post": { - "description": "

When you create a new credit card, you must specify a customer or recipient on which to create it.

\n\n

If the card’s owner has no default card, then the new card will become the default.\nHowever, if the owner already has a default, then it will not change.\nTo change the default, you should update the customer to have a new default_source.

", - "operationId": "PostCustomersCustomerSources", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], + "description": "

Creates a new Issuing Cardholder object that can be issued cards.

", + "operationId": "PostIssuingCardholders", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "bank_account": { + "billing": { "explode": true, "style": "deepObject" }, - "card": { + "company": { "explode": true, "style": "deepObject" }, @@ -45130,621 +89885,1176 @@ "explode": true, "style": "deepObject" }, + "individual": { + "explode": true, + "style": "deepObject" + }, "metadata": { "explode": true, "style": "deepObject" + }, + "preferred_locales": { + "explode": true, + "style": "deepObject" + }, + "spending_controls": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "alipay_account": { - "description": "A token returned by [Stripe.js](https://stripe.com/docs/stripe.js) representing the user’s Alipay account details.", - "maxLength": 5000, - "type": "string" - }, - "bank_account": { - "anyOf": [ - { + "billing": { + "description": "The cardholder's billing address.", + "properties": { + "address": { "properties": { - "account_holder_name": { + "city": { "maxLength": 5000, "type": "string" }, - "account_holder_type": { - "enum": ["company", "individual"], + "country": { "maxLength": 5000, "type": "string" }, - "account_number": { + "line1": { "maxLength": 5000, "type": "string" }, - "country": { + "line2": { "maxLength": 5000, "type": "string" }, - "currency": { - "type": "string" - }, - "object": { - "enum": ["bank_account"], + "postal_code": { "maxLength": 5000, "type": "string" }, - "routing_number": { + "state": { "maxLength": 5000, "type": "string" } }, - "required": ["account_number", "country"], - "title": "customer_payment_source_bank_account", + "required": ["city", "country", "line1", "postal_code"], + "title": "required_address", "type": "object" - }, - { + } + }, + "required": ["address"], + "title": "billing_specs", + "type": "object" + }, + "company": { + "description": "Additional information about a `company` cardholder.", + "properties": { + "tax_id": { "maxLength": 5000, "type": "string" } - ], - "description": "Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js), or a dictionary containing a user's bank account details." + }, + "title": "company_param", + "type": "object" }, - "card": { - "anyOf": [ - { + "email": { + "description": "The cardholder's email address.", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "individual": { + "description": "Additional information about an `individual` cardholder.", + "properties": { + "card_issuing": { "properties": { - "address_city": { - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "maxLength": 5000, - "type": "string" - }, - "cvc": { - "maxLength": 5000, - "type": "string" - }, - "exp_month": { + "user_terms_acceptance": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "terms_acceptance_param", + "type": "object" + } + }, + "title": "card_issuing_param", + "type": "object" + }, + "dob": { + "properties": { + "day": { "type": "integer" }, - "exp_year": { + "month": { "type": "integer" }, - "metadata": { - "additionalProperties": { - "type": "string" + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", + "type": "object" + }, + "first_name": { + "type": "string" + }, + "last_name": { + "type": "string" + }, + "verification": { + "properties": { + "document": { + "properties": { + "back": { + "maxLength": 5000, + "type": "string" + }, + "front": { + "maxLength": 5000, + "type": "string" + } }, + "title": "person_verification_document_param", "type": "object" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "number": { - "maxLength": 5000, - "type": "string" - }, - "object": { - "enum": ["card"], - "maxLength": 5000, - "type": "string" } }, - "required": ["exp_month", "exp_year", "number"], - "title": "customer_payment_source_card", - "type": "object" + "title": "person_verification_param", + "type": "object" + } + }, + "title": "individual_param", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "name": { + "description": "The cardholder's name. This will be printed on cards issued to them. The maximum length of this field is 24 characters. This field cannot contain any special characters or numbers.", + "type": "string" + }, + "phone_number": { + "description": "The cardholder's phone number. This will be transformed to [E.164](https://en.wikipedia.org/wiki/E.164) if it is not provided in that format already. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure#when-is-3d-secure-applied) for more details.", + "type": "string" + }, + "preferred_locales": { + "description": "The cardholder’s preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.\n This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.", + "items": { + "enum": ["de", "en", "es", "fr", "it"], + "type": "string" + }, + "type": "array" + }, + "spending_controls": { + "description": "Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", + "properties": { + "allowed_categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "allowed_merchant_countries": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "blocked_categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - { - "maxLength": 5000, - "type": "string" - } - ], - "description": "A token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe.js).", - "x-stripeBypassValidation": true - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "source": { - "description": "Please refer to full [documentation](https://stripe.com/docs/api) instead.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/payment_source" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/customers/{customer}/sources/{id}": { - "delete": { - "description": "

Delete a specified source for a given customer.

", - "operationId": "DeleteCustomersCustomerSourcesId", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "anyOf": [ - { - "$ref": "#/components/schemas/payment_source" - }, - { - "$ref": "#/components/schemas/deleted_payment_source" - } - ] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "get": { - "description": "

Retrieve a specified source for a given customer.

", - "operationId": "GetCustomersCustomerSourcesId", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "maxLength": 500, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/payment_source" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Update a specified source for a given customer.

", - "operationId": "PostCustomersCustomerSourcesId", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "owner": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "account_holder_name": { - "description": "The name of the person or business that owns the bank account.", - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "description": "The type of entity that holds the account. This can be either `individual` or `company`.", - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "address_city": { - "description": "City/District/Suburb/Town/Village.", - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "description": "Billing address country, if provided when creating card.", - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "description": "Address line 1 (Street address/PO Box/Company name).", - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "description": "Address line 2 (Apartment/Suite/Unit/Building).", - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "description": "State/County/Province/Region.", - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "description": "ZIP or postal code.", - "maxLength": 5000, - "type": "string" - }, - "exp_month": { - "description": "Two digit number representing the card’s expiration month.", - "maxLength": 5000, - "type": "string" - }, - "exp_year": { - "description": "Four digit number representing the card’s expiration year.", - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { + "blocked_merchant_countries": { + "items": { + "maxLength": 5000, "type": "string" }, - "type": "object" + "type": "array" }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "name": { - "description": "Cardholder name.", - "maxLength": 5000, - "type": "string" - }, - "owner": { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" + "spending_limits": { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "interval": { + "enum": [ + "all_time", + "daily", + "monthly", + "per_authorization", + "weekly", + "yearly" + ], + "type": "string" + } }, - "state": { - "maxLength": 5000, - "type": "string" - } + "required": ["amount", "interval"], + "title": "spending_limits_param", + "type": "object" }, - "title": "source_address", - "type": "object" - }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" + "type": "array" }, - "phone": { - "maxLength": 5000, + "spending_limits_currency": { "type": "string" } }, - "title": "owner", + "title": "authorization_controls_param_v2", "type": "object" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "anyOf": [ - { - "$ref": "#/components/schemas/card" - }, - { - "$ref": "#/components/schemas/bank_account" - }, - { - "$ref": "#/components/schemas/source" - } - ] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/customers/{customer}/sources/{id}/verify": { - "post": { - "description": "

Verify a specified bank account for a given customer.

", - "operationId": "PostCustomersCustomerSourcesIdVerify", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "amounts": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "amounts": { - "description": "Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.", - "items": { - "type": "integer" - }, - "type": "array" }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "status": { + "description": "Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`.", + "enum": ["active", "inactive"], + "type": "string" + }, + "type": { + "description": "One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details.", + "enum": ["company", "individual"], + "type": "string", + "x-stripeBypassValidation": true } }, + "required": ["billing", "name"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/bank_account" + "$ref": "#/components/schemas/issuing.cardholder" } } }, @@ -45763,14 +91073,14 @@ } } }, - "/v1/customers/{customer}/subscriptions": { + "/v1/issuing/cardholders/{cardholder}": { "get": { - "description": "

You can see a list of the customer’s active subscriptions. Note that the 10 most recent active subscriptions are always available by default on the customer object. If you need more than those 10, you can use the limit and starting_after parameters to page through additional subscriptions.

", - "operationId": "GetCustomersCustomerSubscriptions", + "description": "

Retrieves an Issuing Cardholder object.

", + "operationId": "GetIssuingCardholdersCardholder", "parameters": [ { "in": "path", - "name": "customer", + "name": "cardholder", "required": true, "schema": { "maxLength": 5000, @@ -45778,17 +91088,6 @@ }, "style": "simple" }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -45803,27 +91102,6 @@ "type": "array" }, "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" } ], "requestBody": { @@ -45831,6 +91109,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -45840,37 +91119,10 @@ }, "responses": { "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/subscription" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "SubscriptionList", - "type": "object", - "x-expandableFields": ["data"] + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.cardholder" } } }, @@ -45889,12 +91141,12 @@ } }, "post": { - "description": "

Creates a new subscription on an existing customer.

", - "operationId": "PostCustomersCustomerSubscriptions", + "description": "

Updates the specified Issuing Cardholder object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", + "operationId": "PostIssuingCardholdersCardholder", "parameters": [ { "in": "path", - "name": "customer", + "name": "cardholder", "required": true, "schema": { "maxLength": 5000, @@ -45907,15 +91159,11 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "add_invoice_items": { - "explode": true, - "style": "deepObject" - }, - "billing_thresholds": { + "billing": { "explode": true, "style": "deepObject" }, - "default_tax_rates": { + "company": { "explode": true, "style": "deepObject" }, @@ -45923,7 +91171,7 @@ "explode": true, "style": "deepObject" }, - "items": { + "individual": { "explode": true, "style": "deepObject" }, @@ -45931,1078 +91179,1145 @@ "explode": true, "style": "deepObject" }, - "pending_invoice_item_interval": { - "explode": true, - "style": "deepObject" - }, - "transfer_data": { + "preferred_locales": { "explode": true, "style": "deepObject" }, - "trial_end": { + "spending_controls": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "add_invoice_items": { - "description": "A list of prices and quantities that will generate invoice items appended to the first invoice for this subscription. You may pass up to 10 items.", - "items": { - "properties": { - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } + "billing": { + "description": "The cardholder's billing address.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" }, - "required": ["currency", "product"], - "title": "one_time_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "add_invoice_item_entry", - "type": "object" + "required": ["city", "country", "line1", "postal_code"], + "title": "required_address", + "type": "object" + } }, - "type": "array" + "required": ["address"], + "title": "billing_specs", + "type": "object" }, - "application_fee_percent": { - "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).", - "type": "number" + "company": { + "description": "Additional information about a `company` cardholder.", + "properties": { + "tax_id": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "company_param", + "type": "object" }, - "backdate_start_date": { - "description": "For new subscriptions, a past timestamp to backdate the subscription's start date to. If set, the first invoice will contain a proration for the timespan between the start date and the current time. Can be combined with trials and the billing cycle anchor.", - "format": "unix-time", - "type": "integer" + "email": { + "description": "The cardholder's email address.", + "type": "string" }, - "billing_cycle_anchor": { - "description": "A future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices.", - "format": "unix-time", - "type": "integer", - "x-stripeBypassValidation": true + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "billing_thresholds": { - "anyOf": [ - { + "individual": { + "description": "Additional information about an `individual` cardholder.", + "properties": { + "card_issuing": { "properties": { - "amount_gte": { + "user_terms_acceptance": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "terms_acceptance_param", + "type": "object" + } + }, + "title": "card_issuing_param", + "type": "object" + }, + "dob": { + "properties": { + "day": { "type": "integer" }, - "reset_billing_cycle_anchor": { - "type": "boolean" + "month": { + "type": "integer" + }, + "year": { + "type": "integer" } }, - "title": "billing_thresholds_param", + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", "type": "object" }, - { - "enum": [""], + "first_name": { + "type": "string" + }, + "last_name": { "type": "string" + }, + "verification": { + "properties": { + "document": { + "properties": { + "back": { + "maxLength": 5000, + "type": "string" + }, + "front": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "person_verification_document_param", + "type": "object" + } + }, + "title": "person_verification_param", + "type": "object" } - ], - "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." - }, - "cancel_at": { - "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.", - "format": "unix-time", - "type": "integer" - }, - "cancel_at_period_end": { - "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", - "type": "boolean" - }, - "collection_method": { - "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`.", - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "coupon": { - "description": "The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription.", - "maxLength": 5000, - "type": "string" + }, + "title": "individual_param", + "type": "object" }, - "days_until_due": { - "description": "Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.", - "type": "integer" + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" }, - "default_payment_method": { - "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", - "maxLength": 5000, + "phone_number": { + "description": "The cardholder's phone number. This is required for all cardholders who will be creating EU cards. See the [3D Secure documentation](https://stripe.com/docs/issuing/3d-secure) for more details.", "type": "string" }, - "default_source": { - "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", - "maxLength": 5000, - "type": "string" + "preferred_locales": { + "description": "The cardholder’s preferred locales (languages), ordered by preference. Locales can be `de`, `en`, `es`, `fr`, or `it`.\n This changes the language of the [3D Secure flow](https://stripe.com/docs/issuing/3d-secure) and one-time password messages sent to the cardholder.", + "items": { + "enum": ["de", "en", "es", "fr", "it"], + "type": "string" + }, + "type": "array" }, - "default_tax_rates": { - "anyOf": [ - { + "spending_controls": { + "description": "Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", + "properties": { + "allowed_categories": { "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], "maxLength": 5000, "type": "string" }, "type": "array" }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription." - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "items": { - "description": "A list of up to 20 subscription items, each with an attached price.", - "items": { - "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "price": { + "allowed_merchant_countries": { + "items": { "maxLength": 5000, "type": "string" }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product", "recurring"], - "title": "recurring_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "subscription_item_create_params", - "type": "object" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "off_session": { - "description": "Indicates if a customer is on or off-session while an invoice payment is attempted.", - "type": "boolean" - }, - "payment_behavior": { - "description": "Use `allow_incomplete` to create subscriptions with `status=incomplete` if the first invoice cannot be paid. Creating subscriptions with this status allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.\n\n`pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription.", - "enum": [ - "allow_incomplete", - "error_if_incomplete", - "pending_if_incomplete" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "pending_invoice_item_interval": { - "anyOf": [ - { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "pending_invoice_item_interval_params", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval." - }, - "promotion_code": { - "description": "The API ID of a promotion code to apply to this subscription. A promotion code applied to a subscription will only affect invoices created for that particular subscription.", - "maxLength": 5000, - "type": "string" - }, - "proration_behavior": { - "description": "Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`.\n\nPassing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`.", - "enum": ["always_invoice", "create_prorations", "none"], - "type": "string" - }, - "transfer_data": { - "description": "If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.", - "properties": { - "amount_percent": { - "type": "number" + "type": "array" }, - "destination": { - "type": "string" - } - }, - "required": ["destination"], - "title": "transfer_data_specs", - "type": "object" - }, - "trial_end": { - "anyOf": [ - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" + "blocked_categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - { - "format": "unix-time", - "type": "integer" - } - ], - "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`." - }, - "trial_from_plan": { - "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed.", - "type": "boolean" - }, - "trial_period_days": { - "description": "Integer representing the number of trial period days before the customer is charged for the first time. This will always overwrite any trials that might apply via a subscribed plan.", - "type": "integer" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/subscription" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/customers/{customer}/subscriptions/{subscription_exposed_id}": { - "delete": { - "description": "

Cancels a customer’s subscription. If you set the at_period_end parameter to true, the subscription will remain active until the end of the period, at which point it will be canceled and not renewed. Otherwise, with the default false value, the subscription is terminated immediately. In either case, the customer will not be charged again for the subscription.

\n\n

Note, however, that any pending invoice items that you’ve created will still be charged for at the end of the period, unless manually deleted. If you’ve set the subscription to cancel at the end of the period, any pending prorations will also be left in place and collected at the end of the period. But if the subscription is set to cancel immediately, pending prorations will be removed.

\n\n

By default, upon subscription cancellation, Stripe will stop automatic collection of all finalized invoices for the customer. This is intended to prevent unexpected payment attempts after the customer has canceled a subscription. However, you can resume automatic collection of the invoices manually after subscription cancellation to have us proceed. Or, you could check for unpaid invoices before allowing the customer to cancel the subscription at all.

", - "operationId": "DeleteCustomersCustomerSubscriptionsSubscriptionExposedId", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "subscription_exposed_id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "invoice_now": { - "description": "Can be set to `true` if `at_period_end` is not set to `true`. Will generate a final invoice that invoices for any un-invoiced metered usage and new/pending proration invoice items.", - "type": "boolean" - }, - "prorate": { - "description": "Can be set to `true` if `at_period_end` is not set to `true`. Will generate a proration invoice item that credits remaining unused time until the subscription period end.", - "type": "boolean" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/subscription" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "get": { - "description": "

Retrieves the subscription with the given ID.

", - "operationId": "GetCustomersCustomerSubscriptionsSubscriptionExposedId", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "subscription_exposed_id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/subscription" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates an existing subscription on a customer to match the specified parameters. When changing plans or quantities, we will optionally prorate the price we charge next month to make up for any price changes. To preview how the proration will be calculated, use the upcoming invoice endpoint.

", - "operationId": "PostCustomersCustomerSubscriptionsSubscriptionExposedId", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "subscription_exposed_id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "add_invoice_items": { - "explode": true, - "style": "deepObject" - }, - "billing_thresholds": { - "explode": true, - "style": "deepObject" - }, - "cancel_at": { - "explode": true, - "style": "deepObject" - }, - "default_tax_rates": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "items": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "pause_collection": { - "explode": true, - "style": "deepObject" - }, - "pending_invoice_item_interval": { - "explode": true, - "style": "deepObject" - }, - "transfer_data": { - "explode": true, - "style": "deepObject" - }, - "trial_end": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "add_invoice_items": { - "description": "A list of prices and quantities that will generate invoice items appended to the first invoice for this subscription. You may pass up to 10 items.", - "items": { - "properties": { - "price": { + "blocked_merchant_countries": { + "items": { "maxLength": 5000, "type": "string" }, - "price_data": { + "type": "array" + }, + "spending_limits": { + "items": { "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "unit_amount": { + "amount": { "type": "integer" }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product"], - "title": "one_time_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { + "categories": { "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], "maxLength": 5000, "type": "string" }, "type": "array" }, - { - "enum": [""], + "interval": { + "enum": [ + "all_time", + "daily", + "monthly", + "per_authorization", + "weekly", + "yearly" + ], "type": "string" } - ] - } - }, - "title": "add_invoice_item_entry", - "type": "object" - }, - "type": "array" - }, - "application_fee_percent": { - "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).", - "type": "number" - }, - "billing_cycle_anchor": { - "description": "Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", - "enum": ["now", "unchanged"], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "amount_gte": { - "type": "integer" }, - "reset_billing_cycle_anchor": { - "type": "boolean" - } - }, - "title": "billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." - }, - "cancel_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period." - }, - "cancel_at_period_end": { - "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", - "type": "boolean" - }, - "collection_method": { - "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`.", - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "coupon": { - "description": "The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription.", - "maxLength": 5000, - "type": "string" - }, - "days_until_due": { - "description": "Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.", - "type": "integer" - }, - "default_payment_method": { - "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", - "maxLength": 5000, - "type": "string" - }, - "default_source": { - "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", - "maxLength": 5000, - "type": "string" - }, - "default_tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" + "required": ["amount", "interval"], + "title": "spending_limits_param", + "type": "object" }, "type": "array" }, - { - "enum": [""], + "spending_limits_currency": { "type": "string" } - ], - "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates." - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "items": { - "description": "A list of up to 20 subscription items, each with an attached price.", - "items": { - "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "clear_usage": { - "type": "boolean" - }, - "deleted": { - "type": "boolean" - }, - "id": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product", "recurring"], - "title": "recurring_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "subscription_item_update_params", - "type": "object" }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "off_session": { - "description": "Indicates if a customer is on or off-session while an invoice payment is attempted.", - "type": "boolean" - }, - "pause_collection": { - "anyOf": [ - { - "properties": { - "behavior": { - "enum": [ - "keep_as_draft", - "mark_uncollectible", - "void" - ], - "type": "string" - }, - "resumes_at": { - "format": "unix-time", - "type": "integer" - } - }, - "required": ["behavior"], - "title": "pause_collection_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "If specified, payment collection for this subscription will be paused." - }, - "payment_behavior": { - "description": "Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.", - "enum": [ - "allow_incomplete", - "error_if_incomplete", - "pending_if_incomplete" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "pending_invoice_item_interval": { - "anyOf": [ - { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "pending_invoice_item_interval_params", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval." - }, - "promotion_code": { - "description": "The promotion code to apply to this subscription. A promotion code applied to a subscription will only affect invoices created for that particular subscription.", - "maxLength": 5000, - "type": "string" - }, - "proration_behavior": { - "description": "Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. Valid values are `create_prorations`, `none`, or `always_invoice`.\n\nPassing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.\n\nProrations can be disabled by passing `none`.", - "enum": ["always_invoice", "create_prorations", "none"], - "type": "string" - }, - "proration_date": { - "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same proration that was previewed with [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. It can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.", - "format": "unix-time", - "type": "integer" - }, - "transfer_data": { - "anyOf": [ - { - "properties": { - "amount_percent": { - "type": "number" - }, - "destination": { - "type": "string" - } - }, - "required": ["destination"], - "title": "transfer_data_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value." - }, - "trial_end": { - "anyOf": [ - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - }, - { - "format": "unix-time", - "type": "integer" - } - ], - "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`." + "title": "authorization_controls_param_v2", + "type": "object" }, - "trial_from_plan": { - "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed.", - "type": "boolean" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/subscription" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/customers/{customer}/subscriptions/{subscription_exposed_id}/discount": { - "delete": { - "description": "

Removes the currently applied discount on a customer.

", - "operationId": "DeleteCustomersCustomerSubscriptionsSubscriptionExposedIdDiscount", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "subscription_exposed_id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, + "status": { + "description": "Specifies whether to permit authorizations on this cardholder's cards.", + "enum": ["active", "inactive"], + "type": "string" + } + }, "type": "object" } } @@ -47014,7 +92329,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_discount" + "$ref": "#/components/schemas/issuing.cardholder" } } }, @@ -47031,106 +92346,85 @@ "description": "Error response." } } - }, + } + }, + "/v1/issuing/cards": { "get": { - "description": "", - "operationId": "GetCustomersCustomerSubscriptionsSubscriptionExposedIdDiscount", + "description": "

Returns a list of Issuing Card objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetIssuingCards", "parameters": [ { - "in": "path", - "name": "customer", - "required": true, + "description": "Only return cards belonging to the Cardholder with the provided ID.", + "in": "query", + "name": "cardholder", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" }, { - "description": "Specifies which fields in the response should be expanded.", + "description": "Only return cards that were issued during the given date interval.", "explode": true, "in": "query", - "name": "expand", + "name": "created", "required": false, "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] }, "style": "deepObject" }, { - "in": "path", - "name": "subscription_exposed_id", - "required": true, + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/discount" - } - } - }, - "description": "Successful response." + "style": "form" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/customers/{customer}/tax_ids": { - "get": { - "description": "

Returns a list of tax IDs for a customer.

", - "operationId": "GetCustomersCustomerTaxIds", - "parameters": [ { - "in": "path", - "name": "customer", - "required": true, + "description": "Only return cards that have the given expiration month.", + "in": "query", + "name": "exp_month", + "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "type": "integer" }, - "style": "simple" + "style": "form" }, { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "description": "Only return cards that have the given expiration year.", "in": "query", - "name": "ending_before", + "name": "exp_year", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "type": "integer" }, "style": "form" }, @@ -47149,6 +92443,17 @@ }, "style": "deepObject" }, + { + "description": "Only return cards that have the given last four digits.", + "in": "query", + "name": "last4", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", @@ -47159,6 +92464,16 @@ }, "style": "form" }, + { + "in": "query", + "name": "personalization_design", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -47169,6 +92484,29 @@ "type": "string" }, "style": "form" + }, + { + "description": "Only return cards that have the given status. One of `active`, `inactive`, or `canceled`.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["active", "canceled", "inactive"], + "type": "string", + "x-stripeBypassValidation": true + }, + "style": "form" + }, + { + "description": "Only return cards that have the given type. One of `virtual` or `physical`.", + "in": "query", + "name": "type", + "required": false, + "schema": { + "enum": ["physical", "virtual"], + "type": "string" + }, + "style": "form" } ], "requestBody": { @@ -47176,6 +92514,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -47191,9 +92530,8 @@ "description": "", "properties": { "data": { - "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/tax_id" + "$ref": "#/components/schemas/issuing.card" }, "type": "array" }, @@ -47209,11 +92547,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, + "pattern": "^/v1/issuing/cards", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "TaxIDsList", + "title": "IssuingCardList", "type": "object", "x-expandableFields": ["data"] } @@ -47234,20 +92573,8 @@ } }, "post": { - "description": "

Creates a new TaxID object for a customer.

", - "operationId": "PostCustomersCustomerTaxIds", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], + "description": "

Creates an Issuing Card object.

", + "operationId": "PostIssuingCards", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -47255,10 +92582,40 @@ "expand": { "explode": true, "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "pin": { + "explode": true, + "style": "deepObject" + }, + "second_line": { + "explode": true, + "style": "deepObject" + }, + "shipping": { + "explode": true, + "style": "deepObject" + }, + "spending_controls": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { + "cardholder": { + "description": "The [Cardholder](https://stripe.com/docs/api#issuing_cardholder_object) object with which the card will be associated.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "The currency for the card.", + "type": "string" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -47267,369 +92624,1120 @@ }, "type": "array" }, - "type": { - "description": "Type of the tax ID, one of `ae_trn`, `au_abn`, `br_cnpj`, `br_cpf`, `ca_bn`, `ca_qst`, `ch_vat`, `cl_tin`, `es_cif`, `eu_vat`, `gb_vat`, `hk_br`, `id_npwp`, `in_gst`, `jp_cn`, `jp_rn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `th_vat`, `tw_vat`, `us_ein`, or `za_vat`", - "enum": [ - "ae_trn", - "au_abn", - "br_cnpj", - "br_cpf", - "ca_bn", - "ca_qst", - "ch_vat", - "cl_tin", - "es_cif", - "eu_vat", - "gb_vat", - "hk_br", - "id_npwp", - "in_gst", - "jp_cn", - "jp_rn", - "kr_brn", - "li_uid", - "mx_rfc", - "my_frp", - "my_itn", - "my_sst", - "no_vat", - "nz_gst", - "ru_inn", - "ru_kpp", - "sa_vat", - "sg_gst", - "sg_uen", - "th_vat", - "tw_vat", - "us_ein", - "za_vat" - ], + "financial_account": { + "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "personalization_design": { + "description": "The personalization design object belonging to this card.", + "maxLength": 5000, + "type": "string" + }, + "pin": { + "description": "The desired PIN for this card.", + "properties": { + "encrypted_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "encrypted_pin_param", + "type": "object" + }, + "replacement_for": { + "description": "The card this is meant to be a replacement for (if any).", "maxLength": 5000, + "type": "string" + }, + "replacement_reason": { + "description": "If `replacement_for` is specified, this should indicate why that card is being replaced.", + "enum": ["damaged", "expired", "lost", "stolen"], "type": "string", "x-stripeBypassValidation": true }, - "value": { - "description": "Value of the tax ID.", - "type": "string" - } - }, - "required": ["type", "value"], - "type": "object" - } - } - }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/tax_id" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/customers/{customer}/tax_ids/{id}": { - "delete": { - "description": "

Deletes an existing TaxID object.

", - "operationId": "DeleteCustomersCustomerTaxIdsId", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/deleted_tax_id" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "get": { - "description": "

Retrieves the TaxID object with the given identifier.

", - "operationId": "GetCustomersCustomerTaxIdsId", - "parameters": [ - { - "in": "path", - "name": "customer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/tax_id" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/disputes": { - "get": { - "description": "

Returns a list of your disputes.

", - "operationId": "GetDisputes", - "parameters": [ - { - "description": "Only return disputes associated to the charge specified by this charge ID.", - "in": "query", - "name": "charge", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" + "second_line": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The second line to print on the card." + }, + "shipping": { + "description": "The address where the card will be shipped.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["city", "country", "line1", "postal_code"], + "title": "required_address", + "type": "object" + }, + "address_validation": { + "properties": { + "mode": { + "enum": [ + "disabled", + "normalization_only", + "validation_and_normalization" + ], + "type": "string" + } + }, + "required": ["mode"], + "title": "address_validation_param", + "type": "object" + }, + "customs": { + "properties": { + "eori_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "customs_param", + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone_number": { + "type": "string" + }, + "require_signature": { + "type": "boolean" + }, + "service": { + "enum": ["express", "priority", "standard"], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": { + "enum": ["bulk", "individual"], + "type": "string" + } }, - "lte": { - "type": "integer" - } + "required": ["address", "name"], + "title": "shipping_specs", + "type": "object" }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "Only return disputes associated to the PaymentIntent specified by this PaymentIntent ID.", - "in": "query", - "name": "payment_intent", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, + "spending_controls": { + "description": "Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", + "properties": { + "allowed_categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "allowed_merchant_countries": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "blocked_categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "blocked_merchant_countries": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "spending_limits": { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "interval": { + "enum": [ + "all_time", + "daily", + "monthly", + "per_authorization", + "weekly", + "yearly" + ], + "type": "string" + } + }, + "required": ["amount", "interval"], + "title": "spending_limits_param", + "type": "object" + }, + "type": "array" + } + }, + "title": "authorization_controls_param", + "type": "object" + }, + "status": { + "description": "Whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`.", + "enum": ["active", "inactive"], + "type": "string" + }, + "type": { + "description": "The type of card to issue. Possible values are `physical` or `virtual`.", + "enum": ["physical", "virtual"], + "type": "string" + } + }, + "required": ["currency", "type"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/dispute" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/disputes", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/issuing.card" } } }, @@ -47648,14 +93756,14 @@ } } }, - "/v1/disputes/{dispute}": { + "/v1/issuing/cards/{card}": { "get": { - "description": "

Retrieves the dispute with the given ID.

", - "operationId": "GetDisputesDispute", + "description": "

Retrieves an Issuing Card object.

", + "operationId": "GetIssuingCardsCard", "parameters": [ { "in": "path", - "name": "dispute", + "name": "card", "required": true, "schema": { "maxLength": 5000, @@ -47684,6 +93792,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -47696,7 +93805,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/dispute" + "$ref": "#/components/schemas/issuing.card" } } }, @@ -47715,12 +93824,12 @@ } }, "post": { - "description": "

When you get a dispute, contacting your customer is always the best first step. If that doesn’t work, you can submit evidence to help us resolve the dispute in your favor. You can do this in your dashboard, but if you prefer, you can use the API to submit evidence programmatically.

\n\n

Depending on your dispute type, different evidence fields will give you a better chance of winning your dispute. To figure out which evidence fields to provide, see our guide to dispute types.

", - "operationId": "PostDisputesDispute", + "description": "

Updates the specified Issuing Card object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", + "operationId": "PostIssuingCardsCard", "parameters": [ { "in": "path", - "name": "dispute", + "name": "card", "required": true, "schema": { "maxLength": 5000, @@ -47733,349 +93842,1119 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "evidence": { + "expand": { "explode": true, "style": "deepObject" }, - "expand": { + "metadata": { "explode": true, "style": "deepObject" }, - "metadata": { + "pin": { + "explode": true, + "style": "deepObject" + }, + "shipping": { + "explode": true, + "style": "deepObject" + }, + "spending_controls": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "evidence": { - "description": "Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.", - "properties": { - "access_activity_log": { - "maxLength": 20000, - "type": "string" - }, - "billing_address": { - "maxLength": 5000, - "type": "string" - }, - "cancellation_policy": { - "type": "string" - }, - "cancellation_policy_disclosure": { - "maxLength": 20000, - "type": "string" - }, - "cancellation_rebuttal": { - "maxLength": 20000, - "type": "string" - }, - "customer_communication": { - "type": "string" - }, - "customer_email_address": { - "maxLength": 5000, - "type": "string" - }, - "customer_name": { - "maxLength": 5000, - "type": "string" - }, - "customer_purchase_ip": { - "maxLength": 5000, - "type": "string" - }, - "customer_signature": { - "type": "string" - }, - "duplicate_charge_documentation": { - "type": "string" + "cancellation_reason": { + "description": "Reason why the `status` of this card is `canceled`.", + "enum": ["lost", "stolen"], + "type": "string", + "x-stripeBypassValidation": true + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" }, - "duplicate_charge_explanation": { - "maxLength": 20000, + { + "enum": [""], "type": "string" - }, - "duplicate_charge_id": { + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "personalization_design": { + "maxLength": 5000, + "type": "string" + }, + "pin": { + "description": "The desired new PIN for this card.", + "properties": { + "encrypted_number": { "maxLength": 5000, "type": "string" + } + }, + "title": "encrypted_pin_param", + "type": "object" + }, + "shipping": { + "description": "Updated shipping information for the card.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["city", "country", "line1", "postal_code"], + "title": "required_address", + "type": "object" }, - "product_description": { - "maxLength": 20000, - "type": "string" - }, - "receipt": { - "type": "string" - }, - "refund_policy": { - "type": "string" - }, - "refund_policy_disclosure": { - "maxLength": 20000, - "type": "string" + "address_validation": { + "properties": { + "mode": { + "enum": [ + "disabled", + "normalization_only", + "validation_and_normalization" + ], + "type": "string" + } + }, + "required": ["mode"], + "title": "address_validation_param", + "type": "object" }, - "refund_refusal_explanation": { - "maxLength": 20000, - "type": "string" + "customs": { + "properties": { + "eori_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "customs_param", + "type": "object" }, - "service_date": { + "name": { "maxLength": 5000, "type": "string" }, - "service_documentation": { - "type": "string" - }, - "shipping_address": { - "maxLength": 5000, + "phone_number": { "type": "string" }, - "shipping_carrier": { - "maxLength": 5000, - "type": "string" + "require_signature": { + "type": "boolean" }, - "shipping_date": { - "maxLength": 5000, - "type": "string" + "service": { + "enum": ["express", "priority", "standard"], + "type": "string", + "x-stripeBypassValidation": true }, - "shipping_documentation": { + "type": { + "enum": ["bulk", "individual"], "type": "string" + } + }, + "required": ["address", "name"], + "title": "shipping_specs", + "type": "object" + }, + "spending_controls": { + "description": "Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", + "properties": { + "allowed_categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "shipping_tracking_number": { - "maxLength": 5000, - "type": "string" + "allowed_merchant_countries": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "uncategorized_file": { - "type": "string" + "blocked_categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "uncategorized_text": { - "maxLength": 20000, - "type": "string" - } - }, - "title": "dispute_evidence_params", - "type": "object" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { + "blocked_merchant_countries": { + "items": { + "maxLength": 5000, "type": "string" }, - "type": "object" - }, - { - "enum": [""], - "type": "string" + "type": "array" + }, + "spending_limits": { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "categories": { + "items": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "interval": { + "enum": [ + "all_time", + "daily", + "monthly", + "per_authorization", + "weekly", + "yearly" + ], + "type": "string" + } + }, + "required": ["amount", "interval"], + "title": "spending_limits_param", + "type": "object" + }, + "type": "array" } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "submit": { - "description": "Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).", - "type": "boolean" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/dispute" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/disputes/{dispute}/close": { - "post": { - "description": "

Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute, acknowledging it as lost.

\n\n

The status of the dispute will change from needs_response to lost. Closing a dispute is irreversible.

", - "operationId": "PostDisputesDisputeClose", - "parameters": [ - { - "in": "path", - "name": "dispute", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/dispute" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/ephemeral_keys": { - "post": { - "description": "

Creates a short-lived API key for a given resource.

", - "operationId": "PostEphemeralKeys", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "customer": { - "description": "The ID of the Customer you'd like to modify using the resulting ephemeral key.", - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" }, - "type": "array" + "title": "authorization_controls_param", + "type": "object" }, - "issuing_card": { - "description": "The ID of the Issuing Card you'd like to access using the resulting ephemeral key.", - "maxLength": 5000, - "type": "string" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ephemeral_key" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/ephemeral_keys/{key}": { - "delete": { - "description": "

Invalidates a short-lived API key for a given resource.

", - "operationId": "DeleteEphemeralKeysKey", - "parameters": [ - { - "in": "path", - "name": "key", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "status": { + "description": "Dictates whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`.", + "enum": ["active", "canceled", "inactive"], + "type": "string", + "x-stripeBypassValidation": true } }, "type": "object" @@ -48089,7 +94968,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ephemeral_key" + "$ref": "#/components/schemas/issuing.card" } } }, @@ -48108,12 +94987,13 @@ } } }, - "/v1/events": { + "/v1/issuing/disputes": { "get": { - "description": "

List events, going back up to 30 days. Each event data is rendered according to Stripe API version at its creation time, specified in event object api_version attribute (not according to your current Stripe API version or Stripe-Version header).

", - "operationId": "GetEvents", + "description": "

Returns a list of Issuing Dispute objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetIssuingDisputes", "parameters": [ { + "description": "Only return Issuing disputes that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -48145,16 +95025,6 @@ }, "style": "deepObject" }, - { - "description": "Filter events by whether all webhooks were successfully delivered. If false, events which are still pending or have failed all delivery attempts to a webhook endpoint will be returned.", - "in": "query", - "name": "delivery_success", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -48203,38 +95073,708 @@ "style": "form" }, { - "description": "A string containing a specific event name, or group of events using * as a wildcard. The list will be filtered to include only events with a matching event property.", + "description": "Select Issuing disputes with the given status.", "in": "query", - "name": "type", + "name": "status", "required": false, "schema": { - "maxLength": 5000, + "enum": ["expired", "lost", "submitted", "unsubmitted", "won"], "type": "string" }, "style": "form" }, { - "description": "An array of up to 20 strings containing specific event names. The list will be filtered to include only events with a matching event property. You may pass either `type` or `types`, but not both.", - "explode": true, + "description": "Select the Issuing dispute for the given transaction.", "in": "query", - "name": "types", + "name": "transaction", "required": false, "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "form" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/issuing.dispute" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/issuing/disputes", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "IssuingDisputeList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates an Issuing Dispute object. Individual pieces of evidence within the evidence object are optional at this point. Stripe only validates that required evidence is present during submission. Refer to Dispute reasons and evidence for more details about evidence requirements.

", + "operationId": "PostIssuingDisputes", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "evidence": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "treasury": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "amount": { + "description": "The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If not set, defaults to the full transaction amount.", + "type": "integer" + }, + "evidence": { + "description": "Evidence provided for the dispute.", + "properties": { + "canceled": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "canceled_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cancellation_policy_provided": { + "anyOf": [ + { + "type": "boolean" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cancellation_reason": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "expected_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_description": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_type": { + "enum": ["", "merchandise", "service"], + "type": "string" + }, + "return_status": { + "enum": ["", "merchant_rejected", "successful"], + "type": "string" + }, + "returned_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "canceled", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "duplicate": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card_statement": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cash_receipt": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "check_image": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "original_transaction": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "duplicate", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "fraudulent": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "fraudulent", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "merchandise_not_as_described": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "received_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "return_description": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "return_status": { + "enum": ["", "merchant_rejected", "successful"], + "type": "string" + }, + "returned_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "merchandise_not_as_described", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "no_valid_authorization": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "no_valid_authorization", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "not_received": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "expected_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_description": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_type": { + "enum": ["", "merchandise", "service"], + "type": "string" + } + }, + "title": "not_received", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "other": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_description": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_type": { + "enum": ["", "merchandise", "service"], + "type": "string" + } + }, + "title": "other", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "reason": { + "enum": [ + "canceled", + "duplicate", + "fraudulent", + "merchandise_not_as_described", + "no_valid_authorization", + "not_received", + "other", + "service_not_as_described" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "service_not_as_described": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "canceled_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cancellation_reason": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "received_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "service_not_as_described", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "evidence_param", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "transaction": { + "description": "The ID of the issuing transaction to create a dispute for. For transaction on Treasury FinancialAccounts, use `treasury.received_debit`.", + "maxLength": 5000, + "type": "string" + }, + "treasury": { + "description": "Params for disputes related to Treasury FinancialAccounts", + "properties": { + "received_debit": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["received_debit"], + "title": "treasury_param", + "type": "object" + } + }, "type": "object" } } @@ -48246,34 +95786,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/event" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/events", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "NotificationEventList", - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/issuing.dispute" } } }, @@ -48292,11 +95805,21 @@ } } }, - "/v1/events/{id}": { + "/v1/issuing/disputes/{dispute}": { "get": { - "description": "

Retrieves the details of an event. Supply the unique identifier of the event, which you might have received in a webhook.

", - "operationId": "GetEventsId", + "description": "

Retrieves an Issuing Dispute object.

", + "operationId": "GetIssuingDisputesDispute", "parameters": [ + { + "in": "path", + "name": "dispute", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -48311,16 +95834,6 @@ "type": "array" }, "style": "deepObject" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" } ], "requestBody": { @@ -48328,6 +95841,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -48340,7 +95854,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/event" + "$ref": "#/components/schemas/issuing.dispute" } } }, @@ -48357,373 +95871,599 @@ "description": "Error response." } } - } - }, - "/v1/exchange_rates": { - "get": { - "description": "

Returns a list of objects that contain the rates at which foreign currencies are converted to one another. Only shows the currencies for which Stripe supports.

", - "operationId": "GetExchangeRates", + }, + "post": { + "description": "

Updates the specified Issuing Dispute object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Properties on the evidence object can be unset by passing in an empty string.

", + "operationId": "PostIssuingDisputesDispute", "parameters": [ { - "description": "A cursor for use in pagination. `ending_before` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with the exchange rate for currency X your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and total number of supported payout currencies, and the default is the max.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with the exchange rate for currency X, your subsequent call can include `starting_after=X` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, + "in": "path", + "name": "dispute", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "evidence": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/exchange_rate" + "additionalProperties": false, + "properties": { + "amount": { + "description": "The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "evidence": { + "description": "Evidence provided for the dispute.", + "properties": { + "canceled": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "canceled_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cancellation_policy_provided": { + "anyOf": [ + { + "type": "boolean" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cancellation_reason": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "expected_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_description": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_type": { + "enum": ["", "merchandise", "service"], + "type": "string" + }, + "return_status": { + "enum": ["", "merchant_rejected", "successful"], + "type": "string" + }, + "returned_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "canceled", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "duplicate": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card_statement": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cash_receipt": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "check_image": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "original_transaction": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "duplicate", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "fraudulent": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "fraudulent", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "merchandise_not_as_described": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "received_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "return_description": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "return_status": { + "enum": ["", "merchant_rejected", "successful"], + "type": "string" + }, + "returned_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "merchandise_not_as_described", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/exchange_rates", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/exchange_rates/{rate_id}": { - "get": { - "description": "

Retrieves the exchange rates from the given currency to every supported currency.

", - "operationId": "GetExchangeRatesRateId", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "rate_id", - "required": true, - "schema": { - "maxLength": 3, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/exchange_rate" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/file_links": { - "get": { - "description": "

Returns a list of file links.

", - "operationId": "GetFileLinks", - "parameters": [ - { - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "Filter links by their expiration status. By default, all links are returned.", - "in": "query", - "name": "expired", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, - { - "description": "Only return links for the given file.", - "in": "query", - "name": "file", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/file_link" + "no_valid_authorization": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "no_valid_authorization", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/file_links", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Creates a new file link object.

", - "operationId": "PostFileLinks", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { + "not_received": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "expected_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_description": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_type": { + "enum": ["", "merchandise", "service"], + "type": "string" + } + }, + "title": "not_received", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "other": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_description": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_type": { + "enum": ["", "merchandise", "service"], + "type": "string" + } + }, + "title": "other", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "reason": { + "enum": [ + "canceled", + "duplicate", + "fraudulent", + "merchandise_not_as_described", + "no_valid_authorization", + "not_received", + "other", + "service_not_as_described" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "service_not_as_described": { + "anyOf": [ + { + "properties": { + "additional_documentation": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "canceled_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cancellation_reason": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "explanation": { + "anyOf": [ + { + "maxLength": 2500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "received_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "service_not_as_described", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "evidence_param", + "type": "object" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -48732,16 +96472,6 @@ }, "type": "array" }, - "expires_at": { - "description": "A future timestamp after which the link will no longer be usable.", - "format": "unix-time", - "type": "integer" - }, - "file": { - "description": "The ID of the file. The file's `purpose` must be one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `pci_document`, `sigma_scheduled_query`, or `tax_document_user_upload`.", - "maxLength": 5000, - "type": "string" - }, "metadata": { "anyOf": [ { @@ -48758,19 +96488,18 @@ "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." } }, - "required": ["file"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/file_link" + "$ref": "#/components/schemas/issuing.dispute" } } }, @@ -48789,80 +96518,17 @@ } } }, - "/v1/file_links/{link}": { - "get": { - "description": "

Retrieves the file link with the given ID.

", - "operationId": "GetFileLinksLink", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "link", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/file_link" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, + "/v1/issuing/disputes/{dispute}/submit": { "post": { - "description": "

Updates an existing file link object. Expired links can no longer be updated.

", - "operationId": "PostFileLinksLink", + "description": "

Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute’s reason are present. For more details, see Dispute reasons and evidence.

", + "operationId": "PostIssuingDisputesDisputeSubmit", "parameters": [ { "in": "path", - "name": "link", + "name": "dispute", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" @@ -48876,16 +96542,13 @@ "explode": true, "style": "deepObject" }, - "expires_at": { - "explode": true, - "style": "deepObject" - }, "metadata": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -48895,24 +96558,6 @@ }, "type": "array" }, - "expires_at": { - "anyOf": [ - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - }, - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "A future timestamp after which the link will no longer be usable, or `now` to expire the link immediately." - }, "metadata": { "anyOf": [ { @@ -48940,7 +96585,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/file_link" + "$ref": "#/components/schemas/issuing.dispute" } } }, @@ -48959,43 +96604,11 @@ } } }, - "/v1/files": { + "/v1/issuing/personalization_designs": { "get": { - "description": "

Returns a list of the files that your account has access to. The files are returned sorted by creation date, with the most recently created files appearing first.

", - "operationId": "GetFiles", + "description": "

Returns a list of personalization design objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetIssuingPersonalizationDesigns", "parameters": [ - { - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -49033,230 +96646,14 @@ "style": "form" }, { - "description": "The file purpose to filter queries by. If none is provided, files will not be filtered by purpose.", - "in": "query", - "name": "purpose", - "required": false, - "schema": { - "enum": [ - "account_requirement", - "additional_verification", - "business_icon", - "business_logo", - "customer_signature", - "dispute_evidence", - "document_provider_identity_document", - "finance_report_run", - "identity_document", - "pci_document", - "sigma_scheduled_query", - "tax_document_user_upload" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/file" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/files", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

To upload a file to Stripe, you’ll need to send a request of type multipart/form-data. The request should contain the file you would like to upload, as well as the parameters for creating a file.

\n\n

All of Stripe’s officially supported Client libraries should have support for sending multipart/form-data.

", - "operationId": "PostFiles", - "requestBody": { - "content": { - "multipart/form-data": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "file_link_data": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "file": { - "description": "A file to upload. The file should follow the specifications of RFC 2388 (which defines file transfers for the `multipart/form-data` protocol).", - "type": "string" - }, - "file_link_data": { - "description": "Optional parameters to automatically create a [file link](https://stripe.com/docs/api#file_links) for the newly created file.", - "properties": { - "create": { - "type": "boolean" - }, - "expires_at": { - "format": "unix-time", - "type": "integer" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "required": ["create"], - "title": "file_link_creation_params", - "type": "object" - }, - "purpose": { - "description": "The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.", - "enum": [ - "account_requirement", - "additional_verification", - "business_icon", - "business_logo", - "customer_signature", - "dispute_evidence", - "identity_document", - "pci_document", - "tax_document_user_upload" - ], - "type": "string", - "x-stripeBypassValidation": true - } - }, - "required": ["file", "purpose"], - "type": "object" - } - } - }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/file" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - }, - "servers": [ - { - "url": "https://files.stripe.com/" - } - ] - } - }, - "/v1/files/{file}": { - "get": { - "description": "

Retrieves the details of an existing file object. Supply the unique file ID from a file, and Stripe will return the corresponding file object. To access file contents, see the File Upload Guide.

", - "operationId": "GetFilesFile", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", + "description": "Only return personalization designs with the given lookup keys.", "explode": true, "in": "query", - "name": "expand", + "name": "lookup_keys", "required": false, "schema": { "items": { - "maxLength": 5000, + "maxLength": 200, "type": "string" }, "type": "array" @@ -49264,130 +96661,29 @@ "style": "deepObject" }, { - "in": "path", - "name": "file", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/file" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/invoiceitems": { - "get": { - "description": "

Returns a list of your invoice items. Invoice items are returned sorted by creation date, with the most recently created invoice items appearing first.

", - "operationId": "GetInvoiceitems", - "parameters": [ - { + "description": "Only return personalization designs with the given preferences.", "explode": true, "in": "query", - "name": "created", + "name": "preferences", "required": false, "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" + "properties": { + "is_default": { + "type": "boolean" }, - { - "type": "integer" + "is_platform_default": { + "type": "boolean" } - ] - }, - "style": "deepObject" - }, - { - "description": "The identifier of the customer whose invoice items to return. If none is provided, all invoice items will be returned.", - "in": "query", - "name": "customer", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" }, - "type": "array" + "title": "preferences_list_param", + "type": "object" }, "style": "deepObject" }, { - "description": "Only return invoice items belonging to this invoice. If none is provided, all invoice items will be returned. If specifying an invoice, no customer identifier is needed.", + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", - "name": "invoice", + "name": "starting_after", "required": false, "schema": { "maxLength": 5000, @@ -49396,32 +96692,12 @@ "style": "form" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "Set to `true` to only show pending invoice items, which are not yet attached to any invoices. Set to `false` to only show invoice items already attached to invoices. If unspecified, no filter is applied.", - "in": "query", - "name": "pending", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "Only return personalization designs with the given status.", "in": "query", - "name": "starting_after", + "name": "status", "required": false, "schema": { - "maxLength": 5000, + "enum": ["active", "inactive", "rejected", "review"], "type": "string" }, "style": "form" @@ -49432,6 +96708,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -49448,7 +96725,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/invoiceitem" + "$ref": "#/components/schemas/issuing.personalization_design" }, "type": "array" }, @@ -49464,11 +96741,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/invoiceitems", + "pattern": "^/v1/issuing/personalization_designs", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "IssuingPersonalizationDesignList", "type": "object", "x-expandableFields": ["data"] } @@ -49489,13 +96767,13 @@ } }, "post": { - "description": "

Creates an item to be added to a draft invoice (up to 250 items per invoice). If no invoice is specified, the item will be on the next invoice created for the customer specified.

", - "operationId": "PostInvoiceitems", + "description": "

Creates a personalization design object.

", + "operationId": "PostIssuingPersonalizationDesigns", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "discounts": { + "carrier_text": { "explode": true, "style": "deepObject" }, @@ -49507,68 +96785,72 @@ "explode": true, "style": "deepObject" }, - "period": { - "explode": true, - "style": "deepObject" - }, - "price_data": { - "explode": true, - "style": "deepObject" - }, - "tax_rates": { + "preferences": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "amount": { - "description": "The integer amount in %s of the charge to be applied to the upcoming invoice. Passing in a negative `amount` will reduce the `amount_due` on the invoice.", - "type": "integer" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "customer": { - "description": "The ID of the customer who will be billed when this invoice item is billed.", - "maxLength": 5000, - "type": "string" - }, - "description": { - "description": "An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.", - "maxLength": 5000, + "card_logo": { + "description": "The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.", "type": "string" }, - "discountable": { - "description": "Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items.", - "type": "boolean" - }, - "discounts": { - "anyOf": [ - { - "items": { - "properties": { - "coupon": { - "maxLength": 5000, - "type": "string" - }, - "discount": { - "maxLength": 5000, - "type": "string" - } + "carrier_text": { + "description": "Hash containing carrier text, for use with physical bundles that support carrier text.", + "properties": { + "footer_body": { + "anyOf": [ + { + "maxLength": 200, + "type": "string" }, - "title": "discounts_data_param", - "type": "object" - }, - "type": "array" + { + "enum": [""], + "type": "string" + } + ] }, - { - "enum": [""], - "type": "string" + "footer_title": { + "anyOf": [ + { + "maxLength": 30, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "header_body": { + "anyOf": [ + { + "maxLength": 200, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "header_title": { + "anyOf": [ + { + "maxLength": 30, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] } - ], - "description": "The coupons to redeem into discounts for the invoice item or invoice line item." + }, + "title": "carrier_text_param", + "type": "object" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -49578,97 +96860,45 @@ }, "type": "array" }, - "invoice": { - "description": "The ID of an existing invoice to add this invoice item to. When left blank, the invoice item will be added to the next upcoming scheduled invoice. This is useful when adding invoice items in response to an invoice.created webhook. You can only add invoice items to draft invoices and there is a maximum of 250 items per invoice.", - "maxLength": 5000, + "lookup_key": { + "description": "A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.", + "maxLength": 200, "type": "string" }, "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "period": { - "description": "The period associated with this invoice item.", - "properties": { - "end": { - "format": "unix-time", - "type": "integer" - }, - "start": { - "format": "unix-time", - "type": "integer" - } + "additionalProperties": { + "type": "string" }, - "required": ["end", "start"], - "title": "period", + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" }, - "price": { - "description": "The ID of the price object.", + "name": { + "description": "Friendly display name.", + "maxLength": 200, + "type": "string" + }, + "physical_bundle": { + "description": "The physical bundle object belonging to this personalization design.", "maxLength": 5000, "type": "string" }, - "price_data": { - "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "preferences": { + "description": "Information on whether this personalization design is used to create cards when one is not specified.", "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" + "is_default": { + "type": "boolean" } }, - "required": ["currency", "product"], - "title": "one_time_price_data", + "required": ["is_default"], + "title": "preferences_param", "type": "object" }, - "quantity": { - "description": "Non-negative integer. The quantity of units for the invoice item.", - "type": "integer" - }, - "subscription": { - "description": "The ID of a subscription to add this invoice item to. When left blank, the invoice item will be be added to the next upcoming scheduled invoice. When set, scheduled invoices for subscriptions other than the specified subscription will ignore the invoice item. Use this when you want to express that an invoice item has been accrued within the context of a particular subscription.", - "maxLength": 5000, - "type": "string" - }, - "tax_rates": { - "description": "The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "unit_amount": { - "description": "The integer unit amount in %s of the charge to be applied to the upcoming invoice. This `unit_amount` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount` will reduce the `amount_due` on the invoice.", - "type": "integer" - }, - "unit_amount_decimal": { - "description": "Same as `unit_amount`, but accepts a decimal value in %s with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", - "format": "decimal", - "type": "string" + "transfer_lookup_key": { + "description": "If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.", + "type": "boolean" } }, - "required": ["customer"], + "required": ["physical_bundle"], "type": "object" } } @@ -49680,7 +96910,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/invoiceitem" + "$ref": "#/components/schemas/issuing.personalization_design" } } }, @@ -49699,60 +96929,10 @@ } } }, - "/v1/invoiceitems/{invoiceitem}": { - "delete": { - "description": "

Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they’re not attached to invoices, or if it’s attached to a draft invoice.

", - "operationId": "DeleteInvoiceitemsInvoiceitem", - "parameters": [ - { - "in": "path", - "name": "invoiceitem", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/deleted_invoiceitem" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, + "/v1/issuing/personalization_designs/{personalization_design}": { "get": { - "description": "

Retrieves the invoice item with the given ID.

", - "operationId": "GetInvoiceitemsInvoiceitem", + "description": "

Retrieves a personalization design object.

", + "operationId": "GetIssuingPersonalizationDesignsPersonalizationDesign", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -49771,7 +96951,7 @@ }, { "in": "path", - "name": "invoiceitem", + "name": "personalization_design", "required": true, "schema": { "maxLength": 5000, @@ -49785,6 +96965,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -49797,7 +96978,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/invoiceitem" + "$ref": "#/components/schemas/issuing.personalization_design" } } }, @@ -49816,12 +96997,12 @@ } }, "post": { - "description": "

Updates the amount or description of an invoice item on an upcoming invoice. Updating an invoice item is only possible before the invoice it’s attached to is closed.

", - "operationId": "PostInvoiceitemsInvoiceitem", + "description": "

Updates a card personalization object.

", + "operationId": "PostIssuingPersonalizationDesignsPersonalizationDesign", "parameters": [ { "in": "path", - "name": "invoiceitem", + "name": "personalization_design", "required": true, "schema": { "maxLength": 5000, @@ -49834,7 +97015,11 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "discounts": { + "card_logo": { + "explode": true, + "style": "deepObject" + }, + "carrier_text": { "explode": true, "style": "deepObject" }, @@ -49842,281 +97027,198 @@ "explode": true, "style": "deepObject" }, - "metadata": { + "lookup_key": { "explode": true, "style": "deepObject" }, - "period": { + "metadata": { "explode": true, "style": "deepObject" }, - "price_data": { + "name": { "explode": true, "style": "deepObject" }, - "tax_rates": { + "preferences": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "amount": { - "description": "The integer amount in %s of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.", - "type": "integer" - }, - "description": { - "description": "An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.", - "maxLength": 5000, - "type": "string" - }, - "discountable": { - "description": "Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items. Cannot be set to true for prorations.", - "type": "boolean" - }, - "discounts": { + "card_logo": { "anyOf": [ { - "items": { - "properties": { - "coupon": { - "maxLength": 5000, - "type": "string" - }, - "discount": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "discounts_data_param", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], "type": "string" - } - ], - "description": "The coupons & existing discounts which apply to the invoice item or invoice line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts." - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" }, { "enum": [""], "type": "string" } ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "period": { - "description": "The period associated with this invoice item.", - "properties": { - "end": { - "format": "unix-time", - "type": "integer" - }, - "start": { - "format": "unix-time", - "type": "integer" - } - }, - "required": ["end", "start"], - "title": "period", - "type": "object" - }, - "price": { - "description": "The ID of the price object.", - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product"], - "title": "one_time_price_data", - "type": "object" - }, - "quantity": { - "description": "Non-negative integer. The quantity of units for the invoice item.", - "type": "integer" + "description": "The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`." }, - "tax_rates": { + "carrier_text": { "anyOf": [ { - "items": { - "maxLength": 5000, - "type": "string" + "properties": { + "footer_body": { + "anyOf": [ + { + "maxLength": 200, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "footer_title": { + "anyOf": [ + { + "maxLength": 30, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "header_body": { + "anyOf": [ + { + "maxLength": 200, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "header_title": { + "anyOf": [ + { + "maxLength": 30, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } }, - "type": "array" + "title": "carrier_text_param", + "type": "object" }, { "enum": [""], "type": "string" } ], - "description": "The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item. Pass an empty string to remove previously-defined tax rates." - }, - "unit_amount": { - "description": "The integer unit amount in %s of the charge to be applied to the upcoming invoice. This unit_amount will be multiplied by the quantity to get the full amount. If you want to apply a credit to the customer's account, pass a negative unit_amount.", - "type": "integer" + "description": "Hash containing carrier text, for use with physical bundles that support carrier text." }, - "unit_amount_decimal": { - "description": "Same as `unit_amount`, but accepts a decimal value in %s with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", - "format": "decimal", - "type": "string" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/invoiceitem" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/invoices": { - "get": { - "description": "

You can list all invoices, or list the invoices for a specific customer. The invoices are returned sorted by creation date, with the most recently created invoices appearing first.

", - "operationId": "GetInvoices", - "parameters": [ - { - "description": "The collection method of the invoice to retrieve. Either `charge_automatically` or `send_invoice`.", - "in": "query", - "name": "collection_method", - "required": false, - "schema": { - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "style": "form" - }, - { - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "lte": { - "type": "integer" - } + "type": "array" }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return invoices for the customer specified by this customer ID.", - "in": "query", - "name": "customer", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "explode": true, - "in": "query", - "name": "due_date", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" + "lookup_key": { + "anyOf": [ + { + "maxLength": 200, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters." + }, + "metadata": { + "additionalProperties": { + "type": "string" }, - "lt": { - "type": "integer" + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "name": { + "anyOf": [ + { + "maxLength": 200, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Friendly display name. Providing an empty string will set the field to null." + }, + "physical_bundle": { + "description": "The physical bundle object belonging to this personalization design.", + "maxLength": 5000, + "type": "string" + }, + "preferences": { + "description": "Information on whether this personalization design is used to create cards when one is not specified.", + "properties": { + "is_default": { + "type": "boolean" + } }, - "lte": { - "type": "integer" - } + "required": ["is_default"], + "title": "preferences_param", + "type": "object" }, - "title": "range_query_specs", - "type": "object" + "transfer_lookup_key": { + "description": "If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.", + "type": "boolean" + } }, - { - "type": "integer" + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.personalization_design" } - ] + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/issuing/physical_bundles": { + "get": { + "description": "

Returns a list of physical bundle objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetIssuingPhysicalBundles", + "parameters": [ { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -50165,24 +97267,23 @@ "style": "form" }, { - "description": "The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)", + "description": "Only return physical bundles with the given status.", "in": "query", "name": "status", "required": false, "schema": { - "enum": ["draft", "open", "paid", "uncollectible", "void"], - "maxLength": 5000, + "enum": ["active", "inactive", "review"], "type": "string" }, "style": "form" }, { - "description": "Only return invoices for the subscription specified by this subscription ID.", + "description": "Only return physical bundles with the given type.", "in": "query", - "name": "subscription", + "name": "type", "required": false, "schema": { - "maxLength": 5000, + "enum": ["custom", "standard"], "type": "string" }, "style": "form" @@ -50193,6 +97294,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -50209,7 +97311,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/invoice" + "$ref": "#/components/schemas/issuing.physical_bundle" }, "type": "array" }, @@ -50225,12 +97327,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/invoices", + "pattern": "^/v1/issuing/physical_bundles", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "InvoicesList", + "title": "IssuingPhysicalBundleList", "type": "object", "x-expandableFields": ["data"] } @@ -50249,30 +97351,162 @@ "description": "Error response." } } + } + }, + "/v1/issuing/physical_bundles/{physical_bundle}": { + "get": { + "description": "

Retrieves a physical bundle object.

", + "operationId": "GetIssuingPhysicalBundlesPhysicalBundle", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "physical_bundle", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.physical_bundle" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/issuing/settlements/{settlement}": { + "get": { + "description": "

Retrieves an Issuing Settlement object.

", + "operationId": "GetIssuingSettlementsSettlement", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "settlement", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.settlement" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } }, "post": { - "description": "

This endpoint creates a draft invoice for a given customer. The draft invoice created pulls in all pending invoice items on that customer, including prorations. The invoice remains a draft until you finalize the invoice, which allows you to pay or send the invoice to your customers.

", - "operationId": "PostInvoices", + "description": "

Updates the specified Issuing Settlement object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", + "operationId": "PostIssuingSettlementsSettlement", + "parameters": [ + { + "in": "path", + "name": "settlement", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "account_tax_ids": { - "explode": true, - "style": "deepObject" - }, - "custom_fields": { - "explode": true, - "style": "deepObject" - }, - "default_tax_rates": { - "explode": true, - "style": "deepObject" - }, - "discounts": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" @@ -50280,137 +97514,11 @@ "metadata": { "explode": true, "style": "deepObject" - }, - "payment_settings": { - "explode": true, - "style": "deepObject" - }, - "transfer_data": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "account_tax_ids": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The account tax IDs associated with the invoice. Only editable when the invoice is a draft." - }, - "application_fee_amount": { - "description": "A fee in %s that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).", - "type": "integer" - }, - "auto_advance": { - "description": "Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action.", - "type": "boolean" - }, - "collection_method": { - "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this invoice using the default source attached to the customer. When sending an invoice, Stripe will email this invoice to the customer with payment instructions. Defaults to `charge_automatically`.", - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "custom_fields": { - "anyOf": [ - { - "items": { - "properties": { - "name": { - "maxLength": 30, - "type": "string" - }, - "value": { - "maxLength": 30, - "type": "string" - } - }, - "required": ["name", "value"], - "title": "custom_field_params", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "A list of up to 4 custom fields to be displayed on the invoice." - }, - "customer": { - "description": "The ID of the customer who will be billed.", - "maxLength": 5000, - "type": "string" - }, - "days_until_due": { - "description": "The number of days from when the invoice is created until it is due. Valid only for invoices where `collection_method=send_invoice`.", - "type": "integer" - }, - "default_payment_method": { - "description": "ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.", - "maxLength": 5000, - "type": "string" - }, - "default_source": { - "description": "ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.", - "maxLength": 5000, - "type": "string" - }, - "default_tax_rates": { - "description": "The tax rates that will apply to any line item that does not have `tax_rates` set.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.", - "maxLength": 1500, - "type": "string" - }, - "discounts": { - "anyOf": [ - { - "items": { - "properties": { - "coupon": { - "maxLength": 5000, - "type": "string" - }, - "discount": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "discounts_data_param", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The coupons to redeem into discounts for the invoice. If not specified, inherits the discount from the invoice's customer. Pass an empty string to avoid inheriting any discounts." - }, - "due_date": { - "description": "The date on which payment for this invoice is due. Valid only for invoices where `collection_method=send_invoice`.", - "format": "unix-time", - "type": "integer" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -50419,145 +97527,26 @@ }, "type": "array" }, - "footer": { - "description": "Footer to be displayed on the invoice.", - "maxLength": 5000, - "type": "string" - }, "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "on_behalf_of": { - "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.", - "type": "string" - }, - "payment_settings": { - "description": "Configuration settings for the PaymentIntent that is generated when the invoice is finalized.", - "properties": { - "payment_method_options": { - "properties": { - "bancontact": { - "anyOf": [ - { - "properties": { - "preferred_language": { - "enum": ["de", "en", "fr", "nl"], - "type": "string" - } - }, - "title": "invoice_payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "card": { - "anyOf": [ - { - "properties": { - "request_three_d_secure": { - "enum": ["any", "automatic"], - "type": "string" - } - }, - "title": "invoice_payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "payment_method_options", - "type": "object" - }, - "payment_method_types": { - "anyOf": [ - { - "items": { - "enum": [ - "ach_credit_transfer", - "ach_debit", - "au_becs_debit", - "bacs_debit", - "bancontact", - "card", - "fpx", - "giropay", - "ideal", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "payment_settings", - "type": "object" - }, - "statement_descriptor": { - "description": "Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.", - "maxLength": 22, - "type": "string" - }, - "subscription": { - "description": "The ID of the subscription to invoice, if any. If not set, the created invoice will include all pending invoice items for the customer. If set, the created invoice will only include pending invoice items for that subscription and pending invoice items not associated with any subscription. The subscription's billing cycle and regular subscription events won't be affected.", - "maxLength": 5000, - "type": "string" - }, - "transfer_data": { - "description": "If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge.", - "properties": { - "amount": { - "type": "integer" - }, - "destination": { - "type": "string" - } + "additionalProperties": { + "type": "string" }, - "required": ["destination"], - "title": "transfer_data_specs", + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" } }, - "required": ["customer"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/invoice" + "$ref": "#/components/schemas/issuing.settlement" } } }, @@ -50576,27 +97565,16 @@ } } }, - "/v1/invoices/upcoming": { + "/v1/issuing/tokens": { "get": { - "description": "

At any time, you can preview the upcoming invoice for a customer. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice.

\n\n

Note that when you are viewing an upcoming invoice, you are simply viewing a preview – the invoice has not yet been created. As such, the upcoming invoice will not show up in invoice listing calls, and you cannot use the API to pay or edit the invoice. If you want to change the amount that your customer will be billed, you can add, remove, or update pending invoice items, or update the customer’s discount.

\n\n

You can preview the effects of updating a subscription, including a preview of what proration will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass a proration_date parameter when doing the actual subscription update. The value passed in should be the same as the subscription_proration_date returned on the upcoming invoice resource. The recommended way to get only the prorations being previewed is to consider only proration line items where period[start] is equal to the subscription_proration_date on the upcoming invoice resource.

", - "operationId": "GetInvoicesUpcoming", + "description": "

Lists all Issuing Token objects for a given card.

", + "operationId": "GetIssuingTokens", "parameters": [ { - "description": "The code of the coupon to apply. If `subscription` or `subscription_items` is provided, the invoice returned will preview updating or creating a subscription with that coupon. Otherwise, it will preview applying that coupon to the customer for the next upcoming invoice from among the customer's subscriptions. The invoice can be previewed without a coupon by passing this value as an empty string.", - "in": "query", - "name": "coupon", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "The identifier of the customer whose upcoming invoice you'd like to retrieve.", + "description": "The Issuing card identifier to list tokens for.", "in": "query", - "name": "customer", - "required": false, + "name": "card", + "required": true, "schema": { "maxLength": 5000, "type": "string" @@ -50604,38 +97582,49 @@ "style": "form" }, { - "description": "The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the customer or subscription. Pass an empty string to avoid inheriting any discounts.", + "description": "Only return Issuing tokens that were created during the given date interval.", "explode": true, "in": "query", - "name": "discounts", + "name": "created", "required": false, "schema": { "anyOf": [ { - "items": { - "properties": { - "coupon": { - "maxLength": 5000, - "type": "string" - }, - "discount": { - "maxLength": 5000, - "type": "string" - } + "properties": { + "gt": { + "type": "integer" }, - "title": "discounts_data_param", - "type": "object" + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } }, - "type": "array" + "title": "range_query_specs", + "type": "object" }, { - "enum": [""], - "type": "string" + "type": "integer" } ] }, "style": "deepObject" }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -50652,147 +97641,19 @@ "style": "deepObject" }, { - "description": "List of invoice items to add or update in the upcoming invoice preview.", - "explode": true, + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", - "name": "invoice_items", + "name": "limit", "required": false, "schema": { - "items": { - "properties": { - "amount": { - "type": "integer" - }, - "currency": { - "type": "string" - }, - "description": { - "maxLength": 5000, - "type": "string" - }, - "discountable": { - "type": "boolean" - }, - "discounts": { - "anyOf": [ - { - "items": { - "properties": { - "coupon": { - "maxLength": 5000, - "type": "string" - }, - "discount": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "discounts_data_param", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "invoiceitem": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "period": { - "properties": { - "end": { - "format": "unix-time", - "type": "integer" - }, - "start": { - "format": "unix-time", - "type": "integer" - } - }, - "required": ["end", "start"], - "title": "period", - "type": "object" - }, - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product"], - "title": "one_time_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "title": "invoice_item_preview_params", - "type": "object" - }, - "type": "array" + "type": "integer" }, - "style": "deepObject" + "style": "form" }, { - "description": "The identifier of the unstarted schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.", + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", - "name": "schedule", + "name": "starting_after", "required": false, "schema": { "maxLength": 5000, @@ -50801,277 +97662,334 @@ "style": "form" }, { - "description": "The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.", + "description": "Select Issuing tokens with the given status.", "in": "query", - "name": "subscription", + "name": "status", "required": false, "schema": { - "maxLength": 5000, + "enum": ["active", "deleted", "requested", "suspended"], "type": "string" }, "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/issuing.token" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "IssuingNetworkTokenList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/issuing/tokens/{token}": { + "get": { + "description": "

Retrieves an Issuing Token object.

", + "operationId": "GetIssuingTokensToken", + "parameters": [ { - "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`.", + "description": "Specifies which fields in the response should be expanded.", "explode": true, "in": "query", - "name": "subscription_billing_cycle_anchor", + "name": "expand", "required": false, "schema": { - "anyOf": [ - { - "enum": ["now", "unchanged"], - "maxLength": 5000, - "type": "string" - }, - { - "format": "unix-time", - "type": "integer" - } - ] + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, "style": "deepObject" }, { - "description": "Timestamp indicating when the subscription should be scheduled to cancel. Will prorate if within the current period and prorations have been enabled using `proration_behavior`.", - "explode": true, - "in": "query", - "name": "subscription_cancel_at", - "required": false, + "in": "path", + "name": "token", + "required": true, "schema": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.token" } - ] + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Attempts to update the specified Issuing Token object to the status specified.

", + "operationId": "PostIssuingTokensToken", + "parameters": [ { - "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", - "in": "query", - "name": "subscription_cancel_at_period_end", - "required": false, + "in": "path", + "name": "token", + "required": true, "schema": { - "type": "boolean" + "maxLength": 5000, + "type": "string" }, - "style": "form" + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "status": { + "description": "Specifies which status the token should be updated to.", + "enum": ["active", "deleted", "suspended"], + "type": "string" + } + }, + "required": ["status"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.token" + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/issuing/transactions": { + "get": { + "description": "

Returns a list of Issuing Transaction objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetIssuingTransactions", + "parameters": [ { - "description": "This simulates the subscription being canceled or expired immediately.", + "description": "Only return transactions that belong to the given card.", "in": "query", - "name": "subscription_cancel_now", + "name": "card", "required": false, "schema": { - "type": "boolean" + "maxLength": 5000, + "type": "string" }, "style": "form" }, { - "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set.", - "explode": true, + "description": "Only return transactions that belong to the given cardholder.", "in": "query", - "name": "subscription_default_tax_rates", + "name": "cardholder", "required": false, "schema": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "form" }, { - "description": "A list of up to 20 subscription items, each with an attached price.", + "description": "Only return transactions that were created during the given date interval.", "explode": true, "in": "query", - "name": "subscription_items", + "name": "created", "required": false, "schema": { - "items": { - "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "clear_usage": { - "type": "boolean" - }, - "deleted": { - "type": "boolean" - }, - "id": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" }, - "required": ["currency", "product", "recurring"], - "title": "recurring_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } + "title": "range_query_specs", + "type": "object" }, - "title": "subscription_item_update_params", - "type": "object" - }, - "type": "array" + { + "type": "integer" + } + ] }, "style": "deepObject" }, { - "description": "Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. Valid values are `create_prorations`, `none`, or `always_invoice`.\n\nPassing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.\n\nProrations can be disabled by passing `none`.", + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", - "name": "subscription_proration_behavior", + "name": "ending_before", "required": false, "schema": { - "enum": ["always_invoice", "create_prorations", "none"], + "maxLength": 5000, "type": "string" }, "style": "form" }, { - "description": "If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period, and cannot be before the subscription was on its current plan. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'.", + "description": "Specifies which fields in the response should be expanded.", + "explode": true, "in": "query", - "name": "subscription_proration_date", + "name": "expand", "required": false, "schema": { - "format": "unix-time", - "type": "integer" + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "style": "form" + "style": "deepObject" }, { - "description": "Date a subscription is intended to start (can be future or past)", + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", - "name": "subscription_start_date", + "name": "limit", "required": false, "schema": { - "format": "unix-time", "type": "integer" }, "style": "form" }, { - "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required.", - "explode": true, + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", - "name": "subscription_trial_end", + "name": "starting_after", "required": false, "schema": { - "anyOf": [ - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - }, - { - "format": "unix-time", - "type": "integer" - } - ] + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "form" }, { - "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `subscription_trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `subscription_trial_end` is not allowed.", + "description": "Only return transactions that have the given type. One of `capture` or `refund`.", "in": "query", - "name": "subscription_trial_from_plan", + "name": "type", "required": false, "schema": { - "type": "boolean" + "enum": ["capture", "refund"], + "type": "string" }, "style": "form" } @@ -51081,6 +97999,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -51093,7 +98012,34 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/invoice" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/issuing.transaction" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/issuing/transactions", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "IssuingTransactionList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -51112,142 +98058,111 @@ } } }, - "/v1/invoices/upcoming/lines": { + "/v1/issuing/transactions/{transaction}": { "get": { - "description": "

When retrieving an upcoming invoice, you’ll get a lines property containing the total count of line items and the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", - "operationId": "GetInvoicesUpcomingLines", + "description": "

Retrieves an Issuing Transaction object.

", + "operationId": "GetIssuingTransactionsTransaction", "parameters": [ { - "description": "The code of the coupon to apply. If `subscription` or `subscription_items` is provided, the invoice returned will preview updating or creating a subscription with that coupon. Otherwise, it will preview applying that coupon to the customer for the next upcoming invoice from among the customer's subscriptions. The invoice can be previewed without a coupon by passing this value as an empty string.", + "description": "Specifies which fields in the response should be expanded.", + "explode": true, "in": "query", - "name": "coupon", + "name": "expand", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "style": "form" + "style": "deepObject" }, { - "description": "The identifier of the customer whose upcoming invoice you'd like to retrieve.", - "in": "query", - "name": "customer", - "required": false, + "in": "path", + "name": "transaction", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } }, - { - "description": "The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the customer or subscription. Pass an empty string to avoid inheriting any discounts.", - "explode": true, - "in": "query", - "name": "discounts", - "required": false, - "schema": { - "anyOf": [ - { - "items": { - "properties": { - "coupon": { - "maxLength": 5000, - "type": "string" - }, - "discount": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "discounts_data_param", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.transaction" } - ] + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the specified Issuing Transaction object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", + "operationId": "PostIssuingTransactionsTransaction", + "parameters": [ { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, + "in": "path", + "name": "transaction", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "List of invoice items to add or update in the upcoming invoice preview.", - "explode": true, - "in": "query", - "name": "invoice_items", - "required": false, - "schema": { - "items": { + "schema": { + "additionalProperties": false, "properties": { - "amount": { - "type": "integer" - }, - "currency": { - "type": "string" - }, - "description": { - "maxLength": 5000, - "type": "string" - }, - "discountable": { - "type": "boolean" - }, - "discounts": { - "anyOf": [ - { - "items": { - "properties": { - "coupon": { - "maxLength": 5000, - "type": "string" - }, - "discount": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "discounts_data_param", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "invoiceitem": { - "maxLength": 5000, - "type": "string" + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, "metadata": { "anyOf": [ @@ -51261,76 +98176,304 @@ "enum": [""], "type": "string" } - ] - }, - "period": { - "properties": { - "end": { - "format": "unix-time", - "type": "integer" - }, - "start": { - "format": "unix-time", - "type": "integer" - } - }, - "required": ["end", "start"], - "title": "period", - "type": "object" - }, - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.transaction" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/link_account_sessions": { + "post": { + "description": "

To launch the Financial Connections authorization flow, create a Session. The session’s client_secret can be used to launch the flow using Stripe.js.

", + "operationId": "PostLinkAccountSessions", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "account_holder": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "filters": { + "explode": true, + "style": "deepObject" + }, + "permissions": { + "explode": true, + "style": "deepObject" + }, + "prefetch": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account_holder": { + "description": "The account holder to link accounts for.", "properties": { - "currency": { + "account": { + "maxLength": 5000, "type": "string" }, - "product": { + "customer": { "maxLength": 5000, "type": "string" }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", + "type": { + "enum": ["account", "customer"], "type": "string" } }, - "required": ["currency", "product"], - "title": "one_time_price_data", + "required": ["type"], + "title": "accountholder_params", "type": "object" }, - "quantity": { - "type": "integer" + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "tax_rates": { - "anyOf": [ - { + "filters": { + "description": "Filters to restrict the kinds of accounts to collect.", + "properties": { + "account_subcategories": { "items": { - "maxLength": 5000, + "enum": [ + "checking", + "credit_card", + "line_of_credit", + "mortgage", + "savings" + ], "type": "string" }, "type": "array" }, - { - "enum": [""], - "type": "string" + "countries": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" } - ] + }, + "title": "filters_params", + "type": "object" }, - "unit_amount": { - "type": "integer" + "permissions": { + "description": "List of data features that you would like to request access to.\n\nPossible values are `balances`, `transactions`, `ownership`, and `payment_method`.", + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" }, - "unit_amount_decimal": { - "format": "decimal", + "prefetch": { + "description": "List of data features that you would like to retrieve upon account creation.", + "items": { + "enum": ["balances", "ownership", "transactions"], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "return_url": { + "description": "For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.", + "maxLength": 5000, "type": "string" } }, - "title": "invoice_item_preview_params", - "type": "object" + "required": ["account_holder", "permissions"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/financial_connections.session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/link_account_sessions/{session}": { + "get": { + "description": "

Retrieves the details of a Financial Connections Session

", + "operationId": "GetLinkAccountSessionsSession", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "session", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/financial_connections.session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/linked_accounts": { + "get": { + "description": "

Returns a list of Financial Connections Account objects.

", + "operationId": "GetLinkedAccounts", + "parameters": [ + { + "description": "If present, only return accounts that belong to the specified account holder. `account_holder[customer]` and `account_holder[account]` are mutually exclusive.", + "explode": true, + "in": "query", + "name": "account_holder", + "required": false, + "schema": { + "properties": { + "account": { + "maxLength": 5000, + "type": "string" + }, + "customer": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "accountholder_params", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" }, "type": "array" }, @@ -51347,9 +98490,9 @@ "style": "form" }, { - "description": "The identifier of the unstarted schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.", + "description": "If present, only return accounts that were collected as part of the given session.", "in": "query", - "name": "schedule", + "name": "session", "required": false, "schema": { "maxLength": 5000, @@ -51367,328 +98510,409 @@ "type": "string" }, "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/financial_connections.account" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/financial_connections/accounts", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "BankConnectionsResourceLinkedAccountList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/linked_accounts/{account}": { + "get": { + "description": "

Retrieves the details of an Financial Connections Account.

", + "operationId": "GetLinkedAccountsAccount", + "parameters": [ { - "description": "The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.", - "in": "query", - "name": "subscription", - "required": false, + "in": "path", + "name": "account", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" }, { - "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`.", + "description": "Specifies which fields in the response should be expanded.", "explode": true, "in": "query", - "name": "subscription_billing_cycle_anchor", + "name": "expand", "required": false, "schema": { - "anyOf": [ - { - "enum": ["now", "unchanged"], - "maxLength": 5000, - "type": "string" - }, - { - "format": "unix-time", - "type": "integer" - } - ] + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } }, - { - "description": "Timestamp indicating when the subscription should be scheduled to cancel. Will prorate if within the current period and prorations have been enabled using `proration_behavior`.", - "explode": true, - "in": "query", - "name": "subscription_cancel_at", - "required": false, - "schema": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/financial_connections.account" } - ] + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/linked_accounts/{account}/disconnect": { + "post": { + "description": "

Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions).

", + "operationId": "PostLinkedAccountsAccountDisconnect", + "parameters": [ { - "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", - "in": "query", - "name": "subscription_cancel_at_period_end", - "required": false, + "in": "path", + "name": "account", + "required": true, "schema": { - "type": "boolean" + "maxLength": 5000, + "type": "string" }, - "style": "form" + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/financial_connections.account" + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/linked_accounts/{account}/owners": { + "get": { + "description": "

Lists all owners for a given Account

", + "operationId": "GetLinkedAccountsAccountOwners", + "parameters": [ { - "description": "This simulates the subscription being canceled or expired immediately.", - "in": "query", - "name": "subscription_cancel_now", - "required": false, + "in": "path", + "name": "account", + "required": true, "schema": { - "type": "boolean" + "maxLength": 5000, + "type": "string" }, - "style": "form" + "style": "simple" }, { - "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set.", - "explode": true, + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", - "name": "subscription_default_tax_rates", + "name": "ending_before", "required": false, "schema": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "form" }, { - "description": "A list of up to 20 subscription items, each with an attached price.", + "description": "Specifies which fields in the response should be expanded.", "explode": true, "in": "query", - "name": "subscription_items", + "name": "expand", "required": false, "schema": { "items": { - "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "clear_usage": { - "type": "boolean" - }, - "deleted": { - "type": "boolean" - }, - "id": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product", "recurring"], - "title": "recurring_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "subscription_item_update_params", - "type": "object" + "maxLength": 5000, + "type": "string" }, "type": "array" }, "style": "deepObject" }, { - "description": "Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. Valid values are `create_prorations`, `none`, or `always_invoice`.\n\nPassing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.\n\nProrations can be disabled by passing `none`.", + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", - "name": "subscription_proration_behavior", + "name": "limit", "required": false, "schema": { - "enum": ["always_invoice", "create_prorations", "none"], - "type": "string" + "type": "integer" }, "style": "form" }, { - "description": "If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period, and cannot be before the subscription was on its current plan. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'.", + "description": "The ID of the ownership object to fetch owners from.", "in": "query", - "name": "subscription_proration_date", - "required": false, + "name": "ownership", + "required": true, "schema": { - "format": "unix-time", - "type": "integer" + "maxLength": 5000, + "type": "string" }, "style": "form" }, { - "description": "Date a subscription is intended to start (can be future or past)", + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", - "name": "subscription_start_date", + "name": "starting_after", "required": false, "schema": { - "format": "unix-time", - "type": "integer" + "maxLength": 5000, + "type": "string" }, "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } }, - { - "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required.", - "explode": true, - "in": "query", - "name": "subscription_trial_end", - "required": false, - "schema": { - "anyOf": [ - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - }, - { - "format": "unix-time", - "type": "integer" + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/financial_connections.account_owner" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "BankConnectionsResourceOwnerList", + "type": "object", + "x-expandableFields": ["data"] } - ] + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/linked_accounts/{account}/refresh": { + "post": { + "description": "

Refreshes the data associated with a Financial Connections Account.

", + "operationId": "PostLinkedAccountsAccountRefresh", + "parameters": [ { - "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `subscription_trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `subscription_trial_end` is not allowed.", - "in": "query", - "name": "subscription_trial_from_plan", - "required": false, + "in": "path", + "name": "account", + "required": true, "schema": { - "type": "boolean" + "maxLength": 5000, + "type": "string" }, - "style": "form" + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "features": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "features": { + "description": "The list of account features that you would like to refresh.", + "items": { + "enum": ["balance", "ownership", "transactions"], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + } + }, + "required": ["features"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/line_item" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "InvoiceLinesList", - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/financial_connections.account" } } }, @@ -51707,17 +98931,31 @@ } } }, - "/v1/invoices/{invoice}": { - "delete": { - "description": "

Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be voided.

", - "operationId": "DeleteInvoicesInvoice", + "/v1/mandates/{mandate}": { + "get": { + "description": "

Retrieves a Mandate object.

", + "operationId": "GetMandatesMandate", "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, { "in": "path", - "name": "invoice", + "name": "mandate", "required": true, "schema": { - "maxLength": 5000, "type": "string" }, "style": "simple" @@ -51728,6 +98966,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -51740,7 +98979,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_invoice" + "$ref": "#/components/schemas/mandate" } } }, @@ -51757,11 +98996,68 @@ "description": "Error response." } } - }, + } + }, + "/v1/payment_intents": { "get": { - "description": "

Retrieves the invoice with the given ID.

", - "operationId": "GetInvoicesInvoice", + "description": "

Returns a list of PaymentIntents.

", + "operationId": "GetPaymentIntents", "parameters": [ + { + "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp or a dictionary with a number of different query options.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return PaymentIntents for the customer that this customer ID specifies.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -51778,14 +99074,25 @@ "style": "deepObject" }, { - "in": "path", - "name": "invoice", - "required": true, + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" } ], "requestBody": { @@ -51793,6 +99100,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -51805,7 +99113,34 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/invoice" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/payment_intent" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/payment_intents", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PaymentFlowsPaymentIntentList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -51824,53 +99159,49 @@ } }, "post": { - "description": "

Draft invoices are fully editable. Once an invoice is finalized,\nmonetary values, as well as collection_method, become uneditable.

\n\n

If you would like to stop the Stripe Billing engine from automatically finalizing, reattempting payments on,\nsending reminders for, or automatically reconciling invoices, pass\nauto_advance=false.

", - "operationId": "PostInvoicesInvoice", - "parameters": [ - { - "in": "path", - "name": "invoice", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], + "description": "

Creates a PaymentIntent object.

\n\n

After the PaymentIntent is created, attach a payment method and confirm\nto continue the payment. Learn more about the available payment flows\nwith the Payment Intents API.

\n\n

When you use confirm=true during creation, it’s equivalent to creating\nand confirming the PaymentIntent in the same call. You can use any parameters\navailable in the confirm API when you supply\nconfirm=true.

", + "operationId": "PostPaymentIntents", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "account_tax_ids": { + "automatic_payment_methods": { "explode": true, "style": "deepObject" }, - "custom_fields": { + "expand": { "explode": true, "style": "deepObject" }, - "default_tax_rates": { + "mandate_data": { "explode": true, "style": "deepObject" }, - "discounts": { + "metadata": { "explode": true, "style": "deepObject" }, - "expand": { + "off_session": { "explode": true, "style": "deepObject" }, - "metadata": { + "payment_method_data": { "explode": true, "style": "deepObject" }, - "on_behalf_of": { + "payment_method_options": { "explode": true, "style": "deepObject" }, - "payment_settings": { + "payment_method_types": { + "explode": true, + "style": "deepObject" + }, + "radar_options": { + "explode": true, + "style": "deepObject" + }, + "shipping": { "explode": true, "style": "deepObject" }, @@ -51880,1383 +99211,2270 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "account_tax_ids": { + "amount": { + "description": "Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", + "type": "integer" + }, + "application_fee_amount": { + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "type": "integer" + }, + "automatic_payment_methods": { + "description": "When you enable this parameter, this PaymentIntent accepts payment methods that you enable in the Dashboard and that are compatible with this PaymentIntent's other parameters.", + "properties": { + "allow_redirects": { + "enum": ["always", "never"], + "type": "string" + }, + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "automatic_payment_methods_param", + "type": "object" + }, + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["automatic", "automatic_async", "manual"], + "type": "string" + }, + "confirm": { + "description": "Set to `true` to attempt to [confirm this PaymentIntent](https://stripe.com/docs/api/payment_intents/confirm) immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, you can also provide the parameters available in the [Confirm API](https://stripe.com/docs/api/payment_intents/confirm).", + "type": "boolean" + }, + "confirmation_method": { + "description": "Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.", + "enum": ["automatic", "manual"], + "type": "string" + }, + "confirmation_token": { + "description": "ID of the ConfirmationToken used to confirm this PaymentIntent.\n\nIf the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "ID of the Customer this PaymentIntent belongs to, if one exists.\n\nPayment methods attached to other Customers cannot be used with this PaymentIntent.\n\nIf [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 1000, + "type": "string" + }, + "error_on_requires_action": { + "description": "Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. Use this parameter for simpler integrations that don't handle customer actions, such as [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).", + "type": "boolean" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "mandate": { + "description": "ID of the mandate that's used for this payment. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).", + "maxLength": 5000, + "type": "string" + }, + "mandate_data": { "anyOf": [ { - "items": { - "maxLength": 5000, - "type": "string" + "properties": { + "customer_acceptance": { + "properties": { + "accepted_at": { + "format": "unix-time", + "type": "integer" + }, + "offline": { + "properties": {}, + "title": "offline_param", + "type": "object" + }, + "online": { + "properties": { + "ip_address": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["ip_address", "user_agent"], + "title": "online_param", + "type": "object" + }, + "type": { + "enum": ["offline", "online"], + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "customer_acceptance_param", + "type": "object" + } + }, + "required": ["customer_acceptance"], + "title": "secret_key_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "This hash contains details about the Mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm)." + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "off_session": { + "anyOf": [ + { + "type": "boolean" + }, + { + "enum": ["one_off", "recurring"], + "maxLength": 5000, + "type": "string" + } + ], + "description": "Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm)." + }, + "on_behalf_of": { + "description": "The Stripe account ID that these funds are intended for. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "type": "string" + }, + "payment_method": { + "description": "ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.\n\nIf you omit this parameter with `confirm=true`, `customer.default_source` attaches as this PaymentIntent's payment instrument to improve migration for users of the Charges API. We recommend that you explicitly provide the `payment_method` moving forward.", + "maxLength": 5000, + "type": "string" + }, + "payment_method_configuration": { + "description": "The ID of the payment method configuration to use with this PaymentIntent.", + "maxLength": 100, + "type": "string" + }, + "payment_method_data": { + "description": "If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear\nin the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)\nproperty on the PaymentIntent.", + "properties": { + "acss_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "institution_number": { + "maxLength": 5000, + "type": "string" + }, + "transit_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "account_number", + "institution_number", + "transit_number" + ], + "title": "payment_method_param", + "type": "object" + }, + "affirm": { + "properties": {}, + "title": "param", + "type": "object" + }, + "afterpay_clearpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "alipay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "allow_redisplay": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "amazon_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "au_becs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "bsb_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "bsb_number"], + "title": "param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "sort_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "bancontact": { + "properties": {}, + "title": "param", + "type": "object" + }, + "billing_details": { + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "billing_details_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "name": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } }, - "type": "array" + "title": "billing_details_inner_params", + "type": "object" }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The account tax IDs associated with the invoice. Only editable when the invoice is a draft." - }, - "application_fee_amount": { - "description": "A fee in %s that will be applied to the invoice and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the Stripe-Account header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/billing/invoices/connect#collecting-fees).", - "type": "integer" - }, - "auto_advance": { - "description": "Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/workflow/#auto_advance) of the invoice.", - "type": "boolean" - }, - "collection_method": { - "description": "Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices.", - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "custom_fields": { - "anyOf": [ - { - "items": { - "properties": { - "name": { - "maxLength": 30, - "type": "string" + "blik": { + "properties": {}, + "title": "param", + "type": "object" + }, + "boleto": { + "properties": { + "tax_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "param", + "type": "object" + }, + "cashapp": { + "properties": {}, + "title": "param", + "type": "object" + }, + "customer_balance": { + "properties": {}, + "title": "param", + "type": "object" + }, + "eps": { + "properties": { + "bank": { + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "fpx": { + "properties": { + "bank": { + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["bank"], + "title": "param", + "type": "object" + }, + "giropay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "grabpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "ideal": { + "properties": { + "bank": { + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "interac_present": { + "properties": {}, + "title": "param", + "type": "object" + }, + "klarna": { + "properties": { + "dob": { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } }, - "value": { - "maxLength": 30, - "type": "string" - } - }, - "required": ["name", "value"], - "title": "custom_field_params", - "type": "object" + "required": ["day", "month", "year"], + "title": "date_of_birth", + "type": "object" + } }, - "type": "array" + "title": "param", + "type": "object" }, - { - "enum": [""], - "type": "string" - } - ], - "description": "A list of up to 4 custom fields to be displayed on the invoice. If a value for `custom_fields` is specified, the list specified will replace the existing custom field list on this invoice. Pass an empty string to remove previously-defined fields." - }, - "days_until_due": { - "description": "The number of days from which the invoice is created until it is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.", - "type": "integer" - }, - "default_payment_method": { - "description": "ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.", - "maxLength": 5000, - "type": "string" - }, - "default_source": { - "description": "ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.", - "maxLength": 5000, - "type": "string" - }, - "default_tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, + "konbini": { + "properties": {}, + "title": "param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "param", + "type": "object" + }, + "metadata": { + "additionalProperties": { "type": "string" }, - "type": "array" + "type": "object" }, - { - "enum": [""], - "type": "string" + "mobilepay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "multibanco": { + "properties": {}, + "title": "param", + "type": "object" + }, + "oxxo": { + "properties": {}, + "title": "param", + "type": "object" + }, + "p24": { + "properties": { + "bank": { + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "param", + "type": "object" + }, + "paynow": { + "properties": {}, + "title": "param", + "type": "object" + }, + "paypal": { + "properties": {}, + "title": "param", + "type": "object" + }, + "pix": { + "properties": {}, + "title": "param", + "type": "object" + }, + "promptpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "radar_options": { + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "revolut_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "iban": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["iban"], + "title": "param", + "type": "object" + }, + "sofort": { + "properties": { + "country": { + "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], + "type": "string" + } + }, + "required": ["country"], + "title": "param", + "type": "object" + }, + "swish": { + "properties": {}, + "title": "param", + "type": "object" + }, + "twint": { + "properties": {}, + "title": "param", + "type": "object" + }, + "type": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "properties": { + "account_holder_type": { + "enum": ["company", "individual"], + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "savings"], + "type": "string" + }, + "financial_connections_account": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "wechat_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "zip": { + "properties": {}, + "title": "param", + "type": "object" } - ], - "description": "The tax rates that will apply to any line item that does not have `tax_rates` set. Pass an empty string to remove previously-defined tax rates." - }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.", - "maxLength": 1500, - "type": "string" + }, + "required": ["type"], + "title": "payment_method_data_params", + "type": "object" }, - "discounts": { - "anyOf": [ - { - "items": { - "properties": { - "coupon": { - "maxLength": 5000, - "type": "string" + "payment_method_options": { + "description": "Payment method-specific configuration for this PaymentIntent.", + "properties": { + "acss_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "custom_mandate_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "interval_description": { + "maxLength": 500, + "type": "string" + }, + "payment_schedule": { + "enum": [ + "combined", + "interval", + "sporadic" + ], + "type": "string" + }, + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_mandate_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "affirm": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "maxLength": 30, + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "afterpay_clearpay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "reference": { + "maxLength": 128, + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "alipay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "amazon_pay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } }, - "discount": { - "maxLength": 5000, - "type": "string" - } + "title": "payment_method_options_param", + "type": "object" }, - "title": "discounts_data_param", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The discounts that will apply to the invoice. Pass an empty string to remove previously-defined discounts." - }, - "due_date": { - "description": "The date on which payment for this invoice is due. Only valid for invoices where `collection_method=send_invoice`. This field can only be updated on `draft` invoices.", - "format": "unix-time", - "type": "integer" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "footer": { - "description": "Footer to be displayed on the invoice.", - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" + { + "enum": [""], + "type": "string" + } + ] }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "on_behalf_of": { - "anyOf": [ - { - "type": "string" + "au_becs_debit": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details." - }, - "payment_settings": { - "description": "Configuration settings for the PaymentIntent that is generated when the invoice is finalized.", - "properties": { - "payment_method_options": { - "properties": { - "bancontact": { - "anyOf": [ - { - "properties": { - "preferred_language": { - "enum": ["de", "en", "fr", "nl"], - "type": "string" - } - }, - "title": "invoice_payment_method_options_param", + "bacs_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", "type": "object" }, - { - "enum": [""], + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], "type": "string" } - ] + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" }, - "card": { - "anyOf": [ - { - "properties": { - "request_three_d_secure": { - "enum": ["any", "automatic"], - "type": "string" - } - }, - "title": "invoice_payment_method_options_param", - "type": "object" + { + "enum": [""], + "type": "string" + } + ] + }, + "bancontact": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": ["de", "en", "fr", "nl"], + "type": "string" }, - { - "enum": [""], + "setup_future_usage": { + "enum": ["", "none", "off_session"], "type": "string" } - ] + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" } - }, - "title": "payment_method_options", - "type": "object" + ] }, - "payment_method_types": { + "blik": { "anyOf": [ { - "items": { - "enum": [ - "ach_credit_transfer", - "ach_debit", - "au_becs_debit", - "bacs_debit", - "bancontact", - "card", - "fpx", - "giropay", - "ideal", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true + "properties": { + "code": { + "maxLength": 5000, + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none"], + "type": "string", + "x-stripeBypassValidation": true + } }, - "type": "array" + "title": "payment_intent_payment_method_options_param", + "type": "object" }, { "enum": [""], "type": "string" } ] - } - }, - "title": "payment_settings", - "type": "object" - }, - "statement_descriptor": { - "description": "Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.", - "maxLength": 22, - "type": "string" - }, - "transfer_data": { - "anyOf": [ - { - "properties": { - "amount": { - "type": "integer" + }, + "boleto": { + "anyOf": [ + { + "properties": { + "expires_after_days": { + "type": "integer" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" }, - "destination": { + { + "enum": [""], "type": "string" } - }, - "required": ["destination"], - "title": "transfer_data_specs", - "type": "object" + ] }, - { - "enum": [""], - "type": "string" - } - ], - "description": "If specified, the funds from the invoice will be transferred to the destination and the ID of the resulting transfer will be found on the invoice's charge. This will be unset if you POST an empty value." - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/invoice" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/invoices/{invoice}/finalize": { - "post": { - "description": "

Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you’d like to finalize a draft invoice manually, you can do so using this method.

", - "operationId": "PostInvoicesInvoiceFinalize", - "parameters": [ - { - "in": "path", - "name": "invoice", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "auto_advance": { - "description": "Controls whether Stripe will perform [automatic collection](https://stripe.com/docs/billing/invoices/overview#auto-advance) of the invoice. When `false`, the invoice's state will not automatically advance without an explicit action.", - "type": "boolean" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/invoice" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/invoices/{invoice}/lines": { - "get": { - "description": "

When retrieving an invoice, you’ll get a lines property containing the total count of line items and the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", - "operationId": "GetInvoicesInvoiceLines", - "parameters": [ - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "invoice", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "description": "Details about each object.", - "items": { - "$ref": "#/components/schemas/line_item" + "card": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "cvc_token": { + "maxLength": 5000, + "type": "string" + }, + "installments": { + "properties": { + "enabled": { + "type": "boolean" + }, + "plan": { + "anyOf": [ + { + "properties": { + "count": { + "type": "integer" + }, + "interval": { + "enum": ["month"], + "type": "string" + }, + "type": { + "enum": ["fixed_count"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "installment_plan", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "installments_param", + "type": "object" + }, + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + }, + "end_date": { + "format": "unix-time", + "type": "integer" + }, + "interval": { + "enum": [ + "day", + "month", + "sporadic", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "type": "integer" + }, + "reference": { + "maxLength": 80, + "type": "string" + }, + "start_date": { + "format": "unix-time", + "type": "integer" + }, + "supported_types": { + "items": { + "enum": ["india"], + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "amount", + "amount_type", + "interval", + "reference", + "start_date" + ], + "title": "mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_extended_authorization": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_incremental_authorization": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_multicapture": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_overcapture": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string", + "x-stripeBypassValidation": true + }, + "require_cvc_recollection": { + "type": "boolean" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + }, + "statement_descriptor_suffix_kana": { + "anyOf": [ + { + "maxLength": 22, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "statement_descriptor_suffix_kanji": { + "anyOf": [ + { + "maxLength": 17, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "three_d_secure": { + "properties": { + "ares_trans_status": { + "enum": ["A", "C", "I", "N", "R", "U", "Y"], + "type": "string" + }, + "cryptogram": { + "maxLength": 5000, + "type": "string" + }, + "electronic_commerce_indicator": { + "enum": ["01", "02", "05", "06", "07"], + "type": "string", + "x-stripeBypassValidation": true + }, + "exemption_indicator": { + "enum": ["low_risk", "none"], + "type": "string" + }, + "network_options": { + "properties": { + "cartes_bancaires": { + "properties": { + "cb_avalgo": { + "enum": [ + "0", + "1", + "2", + "3", + "4", + "A" + ], + "type": "string" + }, + "cb_exemption": { + "maxLength": 4, + "type": "string" + }, + "cb_score": { + "type": "integer" + } + }, + "required": ["cb_avalgo"], + "title": "cartes_bancaires_network_options_param", + "type": "object" + } + }, + "title": "network_options_param", + "type": "object" + }, + "requestor_challenge_indicator": { + "maxLength": 2, + "type": "string" + }, + "transaction_id": { + "maxLength": 5000, + "type": "string" + }, + "version": { + "enum": ["1.0.2", "2.1.0", "2.2.0"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "cryptogram", + "transaction_id", + "version" + ], + "title": "payment_method_options_param", + "type": "object" + } + }, + "title": "payment_intent_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "InvoiceLinesList", - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/invoices/{invoice}/mark_uncollectible": { - "post": { - "description": "

Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes.

", - "operationId": "PostInvoicesInvoiceMarkUncollectible", - "parameters": [ - { - "in": "path", - "name": "invoice", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/invoice" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/invoices/{invoice}/pay": { - "post": { - "description": "

Stripe automatically creates and then attempts to collect payment on invoices for customers on subscriptions according to your subscriptions settings. However, if you’d like to attempt payment on an invoice out of the normal collection schedule or for some other reason, you can do so.

", - "operationId": "PostInvoicesInvoicePay", - "parameters": [ - { - "in": "path", - "name": "invoice", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "forgive": { - "description": "In cases where the source used to pay the invoice has insufficient funds, passing `forgive=true` controls whether a charge should be attempted for the full amount available on the source, up to the amount to fully pay the invoice. This effectively forgives the difference between the amount available on the source and the amount due. \n\nPassing `forgive=false` will fail the charge if the source hasn't been pre-funded with the right amount. An example for this case is with ACH Credit Transfers and wires: if the amount wired is less than the amount due by a small amount, you might want to forgive the difference. Defaults to `false`.", - "type": "boolean" - }, - "off_session": { - "description": "Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `true` (off-session).", - "type": "boolean" - }, - "paid_out_of_band": { - "description": "Boolean representing whether an invoice is paid outside of Stripe. This will result in no charge being made. Defaults to `false`.", - "type": "boolean" - }, - "payment_method": { - "description": "A PaymentMethod to be charged. The PaymentMethod must be the ID of a PaymentMethod belonging to the customer associated with the invoice being paid.", - "maxLength": 5000, - "type": "string" - }, - "source": { - "description": "A payment source to be charged. The source must be the ID of a source belonging to the customer associated with the invoice being paid.", - "maxLength": 5000, - "type": "string" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/invoice" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/invoices/{invoice}/send": { - "post": { - "description": "

Stripe will automatically send invoices to customers according to your subscriptions settings. However, if you’d like to manually send an invoice to your customer out of the normal schedule, you can do so. When sending invoices that have already been paid, there will be no reference to the payment in the email.

\n\n

Requests made in test-mode result in no emails being sent, despite sending an invoice.sent event.

", - "operationId": "PostInvoicesInvoiceSend", - "parameters": [ - { - "in": "path", - "name": "invoice", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/invoice" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/invoices/{invoice}/void": { - "post": { - "description": "

Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to deletion, however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.

", - "operationId": "PostInvoicesInvoiceVoid", - "parameters": [ - { - "in": "path", - "name": "invoice", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/invoice" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/issuer_fraud_records": { - "get": { - "deprecated": true, - "description": "

Returns a list of issuer fraud records.

", - "operationId": "GetIssuerFraudRecords", - "parameters": [ - { - "description": "Only return issuer fraud records for the charge specified by this charge ID.", - "in": "query", - "name": "charge", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/issuer_fraud_record" + "card_present": { + "anyOf": [ + { + "properties": { + "request_extended_authorization": { + "type": "boolean" + }, + "request_incremental_authorization_support": { + "type": "boolean" + }, + "routing": { + "properties": { + "requested_priority": { + "enum": ["domestic", "international"], + "type": "string" + } + }, + "title": "routing_payment_method_options_param", + "type": "object" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cashapp": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/issuer_fraud_records", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "RadarIssuerFraudRecordList", - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/issuer_fraud_records/{issuer_fraud_record}": { - "get": { - "deprecated": true, - "description": "

Retrieves the details of an issuer fraud record that has previously been created.

\n\n

Please refer to the issuer fraud record object reference for more details.

", - "operationId": "GetIssuerFraudRecordsIssuerFraudRecord", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "issuer_fraud_record", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuer_fraud_record" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/issuing/authorizations": { - "get": { - "description": "

Returns a list of Issuing Authorization objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", - "operationId": "GetIssuingAuthorizations", - "parameters": [ - { - "description": "Only return authorizations that belong to the given card.", - "in": "query", - "name": "card", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return authorizations that belong to the given cardholder.", - "in": "query", - "name": "cardholder", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return authorizations that were created during the given date interval.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return authorizations with the given status. One of `pending`, `closed`, or `reversed`.", - "in": "query", - "name": "status", - "required": false, - "schema": { - "enum": ["closed", "pending", "reversed"], - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/issuing.authorization" + "customer_balance": { + "anyOf": [ + { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_params", + "type": "object" + }, + "requested_address_types": { + "items": { + "enum": [ + "aba", + "iban", + "sepa", + "sort_code", + "spei", + "swift", + "zengin" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "type": { + "enum": [ + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "mx_bank_transfer", + "us_bank_transfer" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "enum": ["bank_transfer"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "eps": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "fpx": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "giropay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "grabpay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "ideal": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "interac_present": { + "anyOf": [ + { + "properties": {}, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "klarna": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "enum": [ + "cs-CZ", + "da-DK", + "de-AT", + "de-CH", + "de-DE", + "el-GR", + "en-AT", + "en-AU", + "en-BE", + "en-CA", + "en-CH", + "en-CZ", + "en-DE", + "en-DK", + "en-ES", + "en-FI", + "en-FR", + "en-GB", + "en-GR", + "en-IE", + "en-IT", + "en-NL", + "en-NO", + "en-NZ", + "en-PL", + "en-PT", + "en-RO", + "en-SE", + "en-US", + "es-ES", + "es-US", + "fi-FI", + "fr-BE", + "fr-CA", + "fr-CH", + "fr-FR", + "it-CH", + "it-IT", + "nb-NO", + "nl-BE", + "nl-NL", + "pl-PL", + "pt-PT", + "ro-RO", + "sv-FI", + "sv-SE" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "konbini": { + "anyOf": [ + { + "properties": { + "confirmation_number": { + "anyOf": [ + { + "maxLength": 11, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "expires_after_days": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "expires_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_description": { + "anyOf": [ + { + "maxLength": 22, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "link": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "mobilepay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "multibanco": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "oxxo": { + "anyOf": [ + { + "properties": { + "expires_after_days": { + "type": "integer" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/issuing/authorizations", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/issuing/authorizations/{authorization}": { - "get": { - "description": "

Retrieves an Issuing Authorization object.

", - "operationId": "GetIssuingAuthorizationsAuthorization", - "parameters": [ - { - "in": "path", - "name": "authorization", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.authorization" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates the specified Issuing Authorization object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostIssuingAuthorizationsAuthorization", - "parameters": [ - { - "in": "path", - "name": "authorization", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" + "p24": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + }, + "tos_shown_and_accepted": { + "type": "boolean" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.authorization" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/issuing/authorizations/{authorization}/approve": { - "post": { - "description": "

Approves a pending Issuing Authorization object. This request should be made within the timeout window of the real-time authorization flow.

", - "operationId": "PostIssuingAuthorizationsAuthorizationApprove", - "parameters": [ - { - "in": "path", - "name": "authorization", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "amount": { - "description": "If the authorization's `pending_request.is_amount_controllable` property is `true`, you may provide this value to control how much to hold for the authorization. Must be positive (use [`decline`](https://stripe.com/docs/api/issuing/authorizations/decline) to decline an authorization request).", - "type": "integer" + "paynow": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "paypal": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "enum": [ + "cs-CZ", + "da-DK", + "de-AT", + "de-DE", + "de-LU", + "el-GR", + "en-GB", + "en-US", + "es-ES", + "fi-FI", + "fr-BE", + "fr-FR", + "fr-LU", + "hu-HU", + "it-IT", + "nl-BE", + "nl-NL", + "pl-PL", + "pt-PT", + "sk-SK", + "sv-SE" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "reference": { + "maxLength": 127, + "type": "string" + }, + "risk_correlation_id": { + "maxLength": 32, + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "pix": { + "anyOf": [ + { + "properties": { + "expires_after_seconds": { + "type": "integer" + }, + "expires_at": { + "format": "unix-time", + "type": "integer" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "promptpay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "revolut_pay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sofort": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": [ + "", + "de", + "en", + "es", + "fr", + "it", + "nl", + "pl" + ], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "swish": { + "anyOf": [ + { + "properties": { + "reference": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "twint": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "title": "linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "return_url": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "linked_account_options_param", + "type": "object" + }, + "mandate_options": { + "properties": { + "collection_method": { + "enum": ["", "paper"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "networks": { + "properties": { + "requested": { + "items": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "type": "array" + } + }, + "title": "networks_options_param", + "type": "object" + }, + "preferred_settlement_speed": { + "enum": ["", "fastest", "standard"], + "type": "string" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "wechat_pay": { + "anyOf": [ + { + "properties": { + "app_id": { + "maxLength": 5000, + "type": "string" + }, + "client": { + "enum": ["android", "ios", "web"], + "type": "string", + "x-stripeBypassValidation": true + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "required": ["client"], + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "zip": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_method_options_param", + "type": "object" }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", + "payment_method_types": { + "description": "The list of payment method types (for example, a card) that this PaymentIntent can use. If you don't provide this, it defaults to [\"card\"]. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).", "items": { "maxLength": 5000, "type": "string" }, "type": "array" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" + "radar_options": { + "description": "Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).", + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "receipt_email": { + "description": "Email address to send the receipt to. If you specify `receipt_email` for a payment in live mode, you send a receipt regardless of your [email settings](https://dashboard.stripe.com/account/emails).", + "type": "string" + }, + "return_url": { + "description": "The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).", + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).", + "enum": ["off_session", "on_session"], + "type": "string" + }, + "shipping": { + "description": "Shipping information for this PaymentIntent.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } }, + "title": "optional_fields_address", "type": "object" }, - { - "enum": [""], + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "tracking_number": { + "maxLength": 5000, "type": "string" } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "required": ["address", "name"], + "title": "optional_fields_shipping", + "type": "object" + }, + "statement_descriptor": { + "description": "Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).\n\nSetting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.", + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_suffix": { + "description": "Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.", + "maxLength": 22, + "type": "string" + }, + "transfer_data": { + "description": "The parameters that you can use to automatically create a Transfer.\nLearn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "properties": { + "amount": { + "type": "integer" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_creation_params", + "type": "object" + }, + "transfer_group": { + "description": "A string that identifies the resulting payment as part of a group. Learn more about the [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers).", + "type": "string" + }, + "use_stripe_sdk": { + "description": "Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.", + "type": "boolean" } }, + "required": ["amount", "currency"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/issuing.authorization" + "$ref": "#/components/schemas/payment_intent" } } }, @@ -53275,61 +101493,66 @@ } } }, - "/v1/issuing/authorizations/{authorization}/decline": { - "post": { - "description": "

Declines a pending Issuing Authorization object. This request should be made within the timeout window of the real time authorization flow.

", - "operationId": "PostIssuingAuthorizationsAuthorizationDecline", + "/v1/payment_intents/search": { + "get": { + "description": "

Search for PaymentIntents you’ve previously created using Stripe’s Search Query Language.\nDon’t use search in read-after-write flows where strict consistency is necessary. Under normal operating\nconditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up\nto an hour behind during outages. Search functionality is not available to merchants in India.

", + "operationId": "GetPaymentIntentsSearch", "parameters": [ { - "in": "path", - "name": "authorization", + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.", + "in": "query", + "name": "page", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for payment intents](https://stripe.com/docs/search#query-fields-for-payment-intents).", + "in": "query", + "name": "query", "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -53341,7 +101564,40 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/issuing.authorization" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/payment_intent" + }, + "type": "array" + }, + "has_more": { + "type": "boolean" + }, + "next_page": { + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["search_result"], + "type": "string" + }, + "total_count": { + "description": "The total number of objects that match the query, only accurate up to 10,000.", + "type": "integer" + }, + "url": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SearchResult", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -53360,58 +101616,15 @@ } } }, - "/v1/issuing/cardholders": { + "/v1/payment_intents/{intent}": { "get": { - "description": "

Returns a list of Issuing Cardholder objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", - "operationId": "GetIssuingCardholders", + "description": "

Retrieves the details of a PaymentIntent that has previously been created.

\n\n

You can retrieve a PaymentIntent client-side using a publishable key when the client_secret is in the query string.

\n\n

If you retrieve a PaymentIntent with a publishable key, it only returns a subset of properties. Refer to the payment intent object reference for more details.

", + "operationId": "GetPaymentIntentsIntent", "parameters": [ { - "description": "Only return cardholders that were created during the given date interval.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return cardholders that have the given email address.", - "in": "query", - "name": "email", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "description": "The client secret of the PaymentIntent. We require it if you use a publishable key to retrieve the source.", "in": "query", - "name": "ending_before", + "name": "client_secret", "required": false, "schema": { "maxLength": 5000, @@ -53435,58 +101648,14 @@ "style": "deepObject" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "Only return cardholders that have the given phone number.", - "in": "query", - "name": "phone_number", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, + "in": "path", + "name": "intent", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" - }, - { - "description": "Only return cardholders that have the given status. One of `active`, `inactive`, or `blocked`.", - "in": "query", - "name": "status", - "required": false, - "schema": { - "enum": ["active", "blocked", "inactive"], - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return cardholders that have the given type. One of `individual` or `company`.", - "in": "query", - "name": "type", - "required": false, - "schema": { - "enum": ["company", "individual"], - "type": "string", - "x-stripeBypassValidation": true - }, - "style": "form" + "style": "simple" } ], "requestBody": { @@ -53494,6 +101663,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -53506,33 +101676,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/issuing.cardholder" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/issuing/cardholders", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/payment_intent" } } }, @@ -53551,2301 +101695,2213 @@ } }, "post": { - "description": "

Creates a new Issuing Cardholder object that can be issued cards.

", - "operationId": "PostIssuingCardholders", + "description": "

Updates properties on a PaymentIntent object without confirming.

\n\n

Depending on which properties you update, you might need to confirm the\nPaymentIntent again. For example, updating the payment_method\nalways requires you to confirm the PaymentIntent again. If you prefer to\nupdate and confirm at the same time, we recommend updating properties through\nthe confirm API instead.

", + "operationId": "PostPaymentIntentsIntent", + "parameters": [ + { + "in": "path", + "name": "intent", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "billing": { + "application_fee_amount": { "explode": true, "style": "deepObject" }, - "company": { + "expand": { "explode": true, "style": "deepObject" }, - "expand": { + "metadata": { "explode": true, "style": "deepObject" }, - "individual": { + "payment_method_data": { "explode": true, "style": "deepObject" }, - "metadata": { + "payment_method_options": { "explode": true, "style": "deepObject" }, - "spending_controls": { + "payment_method_types": { + "explode": true, + "style": "deepObject" + }, + "receipt_email": { + "explode": true, + "style": "deepObject" + }, + "shipping": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "billing": { - "description": "The cardholder's billing address.", + "amount": { + "description": "Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", + "type": "integer" + }, + "application_fee_amount": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts)." + }, + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["automatic", "automatic_async", "manual"], + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "ID of the Customer this PaymentIntent belongs to, if one exists.\n\nPayment methods attached to other Customers cannot be used with this PaymentIntent.\n\nIf [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 1000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "payment_method": { + "description": "ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent. To unset this field to null, pass in an empty string.", + "maxLength": 5000, + "type": "string" + }, + "payment_method_configuration": { + "description": "The ID of the payment method configuration to use with this PaymentIntent.", + "maxLength": 100, + "type": "string" + }, + "payment_method_data": { + "description": "If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear\nin the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)\nproperty on the PaymentIntent.", "properties": { - "address": { + "acss_debit": { "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { + "account_number": { "maxLength": 5000, "type": "string" }, - "line1": { + "institution_number": { "maxLength": 5000, "type": "string" }, - "line2": { + "transit_number": { "maxLength": 5000, "type": "string" - }, - "postal_code": { + } + }, + "required": [ + "account_number", + "institution_number", + "transit_number" + ], + "title": "payment_method_param", + "type": "object" + }, + "affirm": { + "properties": {}, + "title": "param", + "type": "object" + }, + "afterpay_clearpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "alipay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "allow_redisplay": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "amazon_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "au_becs_debit": { + "properties": { + "account_number": { "maxLength": 5000, "type": "string" }, - "state": { + "bsb_number": { "maxLength": 5000, "type": "string" } }, - "required": ["city", "country", "line1", "postal_code"], - "title": "required_address", + "required": ["account_number", "bsb_number"], + "title": "param", "type": "object" - } - }, - "required": ["address"], - "title": "billing_specs", - "type": "object" - }, - "company": { - "description": "Additional information about a `company` cardholder.", - "properties": { - "tax_id": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "company_param", - "type": "object" - }, - "email": { - "description": "The cardholder's email address.", - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "individual": { - "description": "Additional information about an `individual` cardholder.", - "properties": { - "dob": { + }, + "bacs_debit": { "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" + "account_number": { + "maxLength": 5000, + "type": "string" }, - "year": { - "type": "integer" + "sort_code": { + "maxLength": 5000, + "type": "string" } }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", + "title": "param", "type": "object" }, - "first_name": { - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "maxLength": 5000, - "type": "string" + "bancontact": { + "properties": {}, + "title": "param", + "type": "object" }, - "verification": { + "billing_details": { "properties": { - "document": { - "properties": { - "back": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "billing_details_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "name": { + "anyOf": [ + { "maxLength": 5000, "type": "string" }, - "front": { + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "anyOf": [ + { "maxLength": 5000, "type": "string" + }, + { + "enum": [""], + "type": "string" } - }, - "title": "person_verification_document_param", - "type": "object" + ] } }, - "title": "person_verification_param", + "title": "billing_details_inner_params", "type": "object" - } - }, - "required": ["first_name", "last_name"], - "title": "individual_param", - "type": "object" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "name": { - "description": "The cardholder's name. This will be printed on cards issued to them.", - "type": "string" - }, - "phone_number": { - "description": "The cardholder's phone number. This will be transformed to [E.164](https://en.wikipedia.org/wiki/E.164) if it is not provided in that format already.", - "type": "string" - }, - "spending_controls": { - "description": "Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", - "properties": { - "allowed_categories": { - "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], - "maxLength": 5000, - "type": "string" + }, + "blik": { + "properties": {}, + "title": "param", + "type": "object" + }, + "boleto": { + "properties": { + "tax_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "param", + "type": "object" + }, + "cashapp": { + "properties": {}, + "title": "param", + "type": "object" + }, + "customer_balance": { + "properties": {}, + "title": "param", + "type": "object" + }, + "eps": { + "properties": { + "bank": { + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "maxLength": 5000, + "type": "string" + } }, - "type": "array" + "title": "param", + "type": "object" }, - "blocked_categories": { - "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], - "maxLength": 5000, + "fpx": { + "properties": { + "bank": { + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["bank"], + "title": "param", + "type": "object" + }, + "giropay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "grabpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "ideal": { + "properties": { + "bank": { + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "interac_present": { + "properties": {}, + "title": "param", + "type": "object" + }, + "klarna": { + "properties": { + "dob": { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth", + "type": "object" + } + }, + "title": "param", + "type": "object" + }, + "konbini": { + "properties": {}, + "title": "param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "param", + "type": "object" + }, + "metadata": { + "additionalProperties": { "type": "string" }, - "type": "array" + "type": "object" + }, + "mobilepay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "multibanco": { + "properties": {}, + "title": "param", + "type": "object" + }, + "oxxo": { + "properties": {}, + "title": "param", + "type": "object" + }, + "p24": { + "properties": { + "bank": { + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "param", + "type": "object" + }, + "paynow": { + "properties": {}, + "title": "param", + "type": "object" + }, + "paypal": { + "properties": {}, + "title": "param", + "type": "object" + }, + "pix": { + "properties": {}, + "title": "param", + "type": "object" + }, + "promptpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "radar_options": { + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "revolut_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "iban": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["iban"], + "title": "param", + "type": "object" + }, + "sofort": { + "properties": { + "country": { + "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], + "type": "string" + } + }, + "required": ["country"], + "title": "param", + "type": "object" + }, + "swish": { + "properties": {}, + "title": "param", + "type": "object" + }, + "twint": { + "properties": {}, + "title": "param", + "type": "object" + }, + "type": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "properties": { + "account_holder_type": { + "enum": ["company", "individual"], + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "savings"], + "type": "string" + }, + "financial_connections_account": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_param", + "type": "object" }, - "spending_limits": { - "items": { - "properties": { - "amount": { - "type": "integer" + "wechat_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "zip": { + "properties": {}, + "title": "param", + "type": "object" + } + }, + "required": ["type"], + "title": "payment_method_data_params", + "type": "object" + }, + "payment_method_options": { + "description": "Payment-method-specific configuration for this PaymentIntent.", + "properties": { + "acss_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "custom_mandate_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "interval_description": { + "maxLength": 500, + "type": "string" + }, + "payment_schedule": { + "enum": [ + "combined", + "interval", + "sporadic" + ], + "type": "string" + }, + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_mandate_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } }, - "categories": { - "items": { + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "affirm": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "maxLength": 30, + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "afterpay_clearpay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "reference": { + "maxLength": 128, + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "alipay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "amazon_pay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "au_becs_debit": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bacs_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bancontact": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": ["de", "en", "fr", "nl"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "blik": { + "anyOf": [ + { + "properties": { + "code": { + "maxLength": 5000, + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "boleto": { + "anyOf": [ + { + "properties": { + "expires_after_days": { + "type": "integer" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" ], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "cvc_token": { "maxLength": 5000, "type": "string" }, - "type": "array" + "installments": { + "properties": { + "enabled": { + "type": "boolean" + }, + "plan": { + "anyOf": [ + { + "properties": { + "count": { + "type": "integer" + }, + "interval": { + "enum": ["month"], + "type": "string" + }, + "type": { + "enum": ["fixed_count"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "installment_plan", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "installments_param", + "type": "object" + }, + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + }, + "end_date": { + "format": "unix-time", + "type": "integer" + }, + "interval": { + "enum": [ + "day", + "month", + "sporadic", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "type": "integer" + }, + "reference": { + "maxLength": 80, + "type": "string" + }, + "start_date": { + "format": "unix-time", + "type": "integer" + }, + "supported_types": { + "items": { + "enum": ["india"], + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "amount", + "amount_type", + "interval", + "reference", + "start_date" + ], + "title": "mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_extended_authorization": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_incremental_authorization": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_multicapture": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_overcapture": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string", + "x-stripeBypassValidation": true + }, + "require_cvc_recollection": { + "type": "boolean" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + }, + "statement_descriptor_suffix_kana": { + "anyOf": [ + { + "maxLength": 22, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "statement_descriptor_suffix_kanji": { + "anyOf": [ + { + "maxLength": 17, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "three_d_secure": { + "properties": { + "ares_trans_status": { + "enum": ["A", "C", "I", "N", "R", "U", "Y"], + "type": "string" + }, + "cryptogram": { + "maxLength": 5000, + "type": "string" + }, + "electronic_commerce_indicator": { + "enum": ["01", "02", "05", "06", "07"], + "type": "string", + "x-stripeBypassValidation": true + }, + "exemption_indicator": { + "enum": ["low_risk", "none"], + "type": "string" + }, + "network_options": { + "properties": { + "cartes_bancaires": { + "properties": { + "cb_avalgo": { + "enum": [ + "0", + "1", + "2", + "3", + "4", + "A" + ], + "type": "string" + }, + "cb_exemption": { + "maxLength": 4, + "type": "string" + }, + "cb_score": { + "type": "integer" + } + }, + "required": ["cb_avalgo"], + "title": "cartes_bancaires_network_options_param", + "type": "object" + } + }, + "title": "network_options_param", + "type": "object" + }, + "requestor_challenge_indicator": { + "maxLength": 2, + "type": "string" + }, + "transaction_id": { + "maxLength": 5000, + "type": "string" + }, + "version": { + "enum": ["1.0.2", "2.1.0", "2.2.0"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "cryptogram", + "transaction_id", + "version" + ], + "title": "payment_method_options_param", + "type": "object" + } }, - "interval": { - "enum": [ - "all_time", - "daily", - "monthly", - "per_authorization", - "weekly", - "yearly" - ], - "type": "string" - } + "title": "payment_intent_param", + "type": "object" }, - "required": ["amount", "interval"], - "title": "spending_limits_param", - "type": "object" - }, - "type": "array" + { + "enum": [""], + "type": "string" + } + ] }, - "spending_limits_currency": { - "type": "string" - } - }, - "title": "authorization_controls_param_v2", - "type": "object" - }, - "status": { - "description": "Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`.", - "enum": ["active", "inactive"], - "type": "string" - }, - "type": { - "description": "One of `individual` or `company`.", - "enum": ["company", "individual"], - "type": "string", - "x-stripeBypassValidation": true - } - }, - "required": ["billing", "name", "type"], - "type": "object" - } - } - }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.cardholder" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/issuing/cardholders/{cardholder}": { - "get": { - "description": "

Retrieves an Issuing Cardholder object.

", - "operationId": "GetIssuingCardholdersCardholder", - "parameters": [ - { - "in": "path", - "name": "cardholder", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.cardholder" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates the specified Issuing Cardholder object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostIssuingCardholdersCardholder", - "parameters": [ - { - "in": "path", - "name": "cardholder", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "billing": { - "explode": true, - "style": "deepObject" - }, - "company": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "individual": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "spending_controls": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "billing": { - "description": "The cardholder's billing address.", - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, + "card_present": { + "anyOf": [ + { + "properties": { + "request_extended_authorization": { + "type": "boolean" + }, + "request_incremental_authorization_support": { + "type": "boolean" + }, + "routing": { + "properties": { + "requested_priority": { + "enum": ["domestic", "international"], + "type": "string" + } + }, + "title": "routing_payment_method_options_param", + "type": "object" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], "type": "string" + } + ] + }, + "cashapp": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" }, - "country": { - "maxLength": 5000, + { + "enum": [""], + "type": "string" + } + ] + }, + "customer_balance": { + "anyOf": [ + { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_params", + "type": "object" + }, + "requested_address_types": { + "items": { + "enum": [ + "aba", + "iban", + "sepa", + "sort_code", + "spei", + "swift", + "zengin" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "type": { + "enum": [ + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "mx_bank_transfer", + "us_bank_transfer" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "enum": ["bank_transfer"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "eps": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "fpx": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], "type": "string" + } + ] + }, + "giropay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" }, - "line1": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ] + }, + "grabpay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" }, - "line2": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ] + }, + "ideal": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" }, - "postal_code": { - "maxLength": 5000, + { + "enum": [""], "type": "string" + } + ] + }, + "interac_present": { + "anyOf": [ + { + "properties": {}, + "title": "payment_method_options_param", + "type": "object" }, - "state": { - "maxLength": 5000, + { + "enum": [""], "type": "string" } - }, - "required": ["city", "country", "line1", "postal_code"], - "title": "required_address", - "type": "object" - } - }, - "required": ["address"], - "title": "billing_specs", - "type": "object" - }, - "company": { - "description": "Additional information about a `company` cardholder.", - "properties": { - "tax_id": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "company_param", - "type": "object" - }, - "email": { - "description": "The cardholder's email address.", - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "individual": { - "description": "Additional information about an `individual` cardholder.", - "properties": { - "dob": { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" + ] + }, + "klarna": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "enum": [ + "cs-CZ", + "da-DK", + "de-AT", + "de-CH", + "de-DE", + "el-GR", + "en-AT", + "en-AU", + "en-BE", + "en-CA", + "en-CH", + "en-CZ", + "en-DE", + "en-DK", + "en-ES", + "en-FI", + "en-FR", + "en-GB", + "en-GR", + "en-IE", + "en-IT", + "en-NL", + "en-NO", + "en-NZ", + "en-PL", + "en-PT", + "en-RO", + "en-SE", + "en-US", + "es-ES", + "es-US", + "fi-FI", + "fr-BE", + "fr-CA", + "fr-CH", + "fr-FR", + "it-CH", + "it-IT", + "nb-NO", + "nl-BE", + "nl-NL", + "pl-PL", + "pt-PT", + "ro-RO", + "sv-FI", + "sv-SE" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_param", + "type": "object" }, - "year": { - "type": "integer" + { + "enum": [""], + "type": "string" } - }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" - }, - "first_name": { - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "maxLength": 5000, - "type": "string" + ] }, - "verification": { - "properties": { - "document": { + "konbini": { + "anyOf": [ + { "properties": { - "back": { - "maxLength": 5000, - "type": "string" + "confirmation_number": { + "anyOf": [ + { + "maxLength": 11, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "front": { - "maxLength": 5000, + "expires_after_days": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "expires_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_description": { + "anyOf": [ + { + "maxLength": 22, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "setup_future_usage": { + "enum": ["none"], "type": "string" } }, - "title": "person_verification_document_param", + "title": "payment_method_options_param", "type": "object" - } - }, - "title": "person_verification_param", - "type": "object" - } - }, - "required": ["first_name", "last_name"], - "title": "individual_param", - "type": "object" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "phone_number": { - "description": "The cardholder's phone number.", - "type": "string" - }, - "spending_controls": { - "description": "Rules that control spending across this cardholder's cards. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", - "properties": { - "allowed_categories": { - "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], - "maxLength": 5000, - "type": "string" - }, - "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "blocked_categories": { - "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "link": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "mobilepay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "multibanco": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "oxxo": { + "anyOf": [ + { + "properties": { + "expires_after_days": { + "type": "integer" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "p24": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + }, + "tos_shown_and_accepted": { + "type": "boolean" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "paynow": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "paypal": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "enum": [ + "cs-CZ", + "da-DK", + "de-AT", + "de-DE", + "de-LU", + "el-GR", + "en-GB", + "en-US", + "es-ES", + "fi-FI", + "fr-BE", + "fr-FR", + "fr-LU", + "hu-HU", + "it-IT", + "nl-BE", + "nl-NL", + "pl-PL", + "pt-PT", + "sk-SK", + "sv-SE" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "reference": { + "maxLength": 127, + "type": "string" + }, + "risk_correlation_id": { + "maxLength": 32, + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "pix": { + "anyOf": [ + { + "properties": { + "expires_after_seconds": { + "type": "integer" + }, + "expires_at": { + "format": "unix-time", + "type": "integer" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "promptpay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "revolut_pay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sofort": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": [ + "", + "de", + "en", + "es", + "fr", + "it", + "nl", + "pl" + ], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "spending_limits": { - "items": { - "properties": { - "amount": { - "type": "integer" + "swish": { + "anyOf": [ + { + "properties": { + "reference": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } }, - "categories": { - "items": { + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "twint": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "title": "linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "return_url": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "linked_account_options_param", + "type": "object" + }, + "mandate_options": { + "properties": { + "collection_method": { + "enum": ["", "paper"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "networks": { + "properties": { + "requested": { + "items": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "type": "array" + } + }, + "title": "networks_options_param", + "type": "object" + }, + "preferred_settlement_speed": { + "enum": ["", "fastest", "standard"], + "type": "string" + }, + "setup_future_usage": { "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "wechat_pay": { + "anyOf": [ + { + "properties": { + "app_id": { "maxLength": 5000, "type": "string" }, - "type": "array" + "client": { + "enum": ["android", "ios", "web"], + "type": "string", + "x-stripeBypassValidation": true + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } }, - "interval": { - "enum": [ - "all_time", - "daily", - "monthly", - "per_authorization", - "weekly", - "yearly" - ], - "type": "string" - } + "required": ["client"], + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "zip": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "payment_method_types": { + "description": "The list of payment method types (for example, card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "receipt_email": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails)." + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).\n\nIf you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.", + "enum": ["", "off_session", "on_session"], + "type": "string" + }, + "shipping": { + "anyOf": [ + { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" }, - "required": ["amount", "interval"], - "title": "spending_limits_param", - "type": "object" + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "tracking_number": { + "maxLength": 5000, + "type": "string" + } }, - "type": "array" + "required": ["address", "name"], + "title": "optional_fields_shipping", + "type": "object" }, - "spending_limits_currency": { + { + "enum": [""], "type": "string" } + ], + "description": "Shipping information for this PaymentIntent." + }, + "statement_descriptor": { + "description": "Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).\n\nSetting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.", + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_suffix": { + "description": "Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.", + "maxLength": 22, + "type": "string" + }, + "transfer_data": { + "description": "Use this parameter to automatically create a Transfer when the payment succeeds. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "properties": { + "amount": { + "type": "integer" + } }, - "title": "authorization_controls_param_v2", + "title": "transfer_data_update_params", "type": "object" }, - "status": { - "description": "Specifies whether to permit authorizations on this cardholder's cards.", - "enum": ["active", "inactive"], + "transfer_group": { + "description": "A string that identifies the resulting payment as part of a group. You can only provide `transfer_group` if it hasn't been set. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", "type": "string" } }, @@ -55860,7 +103916,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/issuing.cardholder" + "$ref": "#/components/schemas/payment_intent" } } }, @@ -55879,163 +103935,252 @@ } } }, - "/v1/issuing/cards": { - "get": { - "description": "

Returns a list of Issuing Card objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", - "operationId": "GetIssuingCards", + "/v1/payment_intents/{intent}/apply_customer_balance": { + "post": { + "description": "

Manually reconcile the remaining amount for a customer_balance PaymentIntent.

", + "operationId": "PostPaymentIntentsIntentApplyCustomerBalance", "parameters": [ { - "description": "Only return cards belonging to the Cardholder with the provided ID.", - "in": "query", - "name": "cardholder", - "required": false, + "in": "path", + "name": "intent", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" - }, - { - "description": "Only return cards that were issued during the given date interval.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "Amount that you intend to apply to this PaymentIntent from the customer’s cash balance.\n\nA positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (for example, 100 cents to charge 1 USD or 100 to charge 100 JPY, a zero-decimal currency).\n\nThe maximum amount is the amount of the PaymentIntent.\n\nWhen you omit the amount, it defaults to the remaining amount requested on the PaymentIntent.", + "type": "integer" }, - "title": "range_query_specs", - "type": "object" + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } }, - { - "type": "integer" + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payment_intent" } - ] + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/payment_intents/{intent}/cancel": { + "post": { + "description": "

You can cancel a PaymentIntent object when it’s in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, in rare cases, processing.

\n\n

After it’s canceled, no additional charges are made by the PaymentIntent and any operations on the PaymentIntent fail with an error. For PaymentIntents with a status of requires_capture, the remaining amount_capturable is automatically refunded.

\n\n

You can’t cancel the PaymentIntent for a Checkout Session. Expire the Checkout Session instead.

", + "operationId": "PostPaymentIntentsIntentCancel", + "parameters": [ { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, + "in": "path", + "name": "intent", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" - }, - { - "description": "Only return cards that have the given expiration month.", - "in": "query", - "name": "exp_month", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "Only return cards that have the given expiration year.", - "in": "query", - "name": "exp_year", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } }, - "type": "array" - }, - "style": "deepObject" + "schema": { + "additionalProperties": false, + "properties": { + "cancellation_reason": { + "description": "Reason for canceling this PaymentIntent. Possible values are: `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`", + "enum": [ + "abandoned", + "duplicate", + "fraudulent", + "requested_by_customer" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } }, - { - "description": "Only return cards that have the given last four digits.", - "in": "query", - "name": "last4", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payment_intent" + } + } }, - "style": "form" + "description": "Successful response." }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } }, - "style": "form" - }, + "description": "Error response." + } + } + } + }, + "/v1/payment_intents/{intent}/capture": { + "post": { + "description": "

Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.

\n\n

Uncaptured PaymentIntents are cancelled a set number of days (7 by default) after their creation.

\n\n

Learn more about separate authorization and capture.

", + "operationId": "PostPaymentIntentsIntentCapture", + "parameters": [ { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, + "in": "path", + "name": "intent", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" - }, - { - "description": "Only return cards that have the given status. One of `active`, `inactive`, or `canceled`.", - "in": "query", - "name": "status", - "required": false, - "schema": { - "enum": ["active", "canceled", "inactive"], - "type": "string", - "x-stripeBypassValidation": true - }, - "style": "form" - }, - { - "description": "Only return cards that have the given type. One of `virtual` or `physical`.", - "in": "query", - "name": "type", - "required": false, - "schema": { - "enum": ["physical", "virtual"], - "type": "string" - }, - "style": "form" + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "amount_to_capture": { + "description": "The amount to capture from the PaymentIntent, which must be less than or equal to the original amount. Any additional amount is automatically refunded. Defaults to the full `amount_capturable` if it's not provided.", + "type": "integer" + }, + "application_fee_amount": { + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "type": "integer" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "final_capture": { + "description": "Defaults to `true`. When capturing a PaymentIntent, setting `final_capture` to `false` notifies Stripe to not release the remaining uncaptured funds to make sure that they're captured in future requests. You can only use this setting when [multicapture](https://stripe.com/docs/payments/multicapture) is available for PaymentIntents.", + "type": "boolean" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "statement_descriptor": { + "description": "Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).\n\nSetting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.", + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_suffix": { + "description": "Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.", + "maxLength": 22, + "type": "string" + }, + "transfer_data": { + "description": "The parameters that you can use to automatically create a transfer after the payment\nis captured. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "properties": { + "amount": { + "type": "integer" + } + }, + "title": "transfer_data_update_params", + "type": "object" + } + }, "type": "object" } } @@ -56047,33 +104192,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/issuing.card" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/issuing/cards", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/payment_intent" } } }, @@ -56090,10 +104209,24 @@ "description": "Error response." } } - }, + } + }, + "/v1/payment_intents/{intent}/confirm": { "post": { - "description": "

Creates an Issuing Card object.

", - "operationId": "PostIssuingCards", + "description": "

Confirm that your customer intends to pay with current or provided\npayment method. Upon confirmation, the PaymentIntent will attempt to initiate\na payment.\nIf the selected payment method requires additional authentication steps, the\nPaymentIntent will transition to the requires_action status and\nsuggest additional actions via next_action. If payment fails,\nthe PaymentIntent transitions to the requires_payment_method status or the\ncanceled status if the confirmation limit is reached. If\npayment succeeds, the PaymentIntent will transition to the succeeded\nstatus (or requires_capture, if capture_method is set to manual).\nIf the confirmation_method is automatic, payment may be attempted\nusing our client SDKs\nand the PaymentIntent’s client_secret.\nAfter next_actions are handled by the client, no additional\nconfirmation is required to complete the payment.\nIf the confirmation_method is manual, all payment attempts must be\ninitiated using a secret key.\nIf any actions are required for the payment, the PaymentIntent will\nreturn to the requires_confirmation state\nafter those actions are completed. Your server needs to then\nexplicitly re-confirm the PaymentIntent to initiate the next payment\nattempt.

", + "operationId": "PostPaymentIntentsIntentConfirm", + "parameters": [ + { + "in": "path", + "name": "intent", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -56102,30 +104235,61 @@ "explode": true, "style": "deepObject" }, - "metadata": { + "mandate_data": { "explode": true, "style": "deepObject" }, - "shipping": { + "off_session": { "explode": true, "style": "deepObject" }, - "spending_controls": { + "payment_method_data": { + "explode": true, + "style": "deepObject" + }, + "payment_method_options": { + "explode": true, + "style": "deepObject" + }, + "payment_method_types": { + "explode": true, + "style": "deepObject" + }, + "radar_options": { + "explode": true, + "style": "deepObject" + }, + "receipt_email": { + "explode": true, + "style": "deepObject" + }, + "shipping": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "cardholder": { - "description": "The [Cardholder](https://stripe.com/docs/api#issuing_cardholder_object) object with which the card will be associated.", + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": ["automatic", "automatic_async", "manual"], + "type": "string" + }, + "client_secret": { + "description": "The client secret of the PaymentIntent.", "maxLength": 5000, "type": "string" }, - "currency": { - "description": "The currency for the card. This currently must be `usd`.", + "confirmation_token": { + "description": "ID of the ConfirmationToken used to confirm this PaymentIntent.\n\nIf the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.", + "maxLength": 5000, "type": "string" }, + "error_on_requires_action": { + "description": "Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. This parameter is intended for simpler integrations that do not handle customer actions, like [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication).", + "type": "boolean" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -56134,2095 +104298,2189 @@ }, "type": "array" }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" + "mandate": { + "description": "ID of the mandate that's used for this payment.", + "maxLength": 5000, + "type": "string" + }, + "mandate_data": { + "anyOf": [ + { + "properties": { + "customer_acceptance": { + "properties": { + "accepted_at": { + "format": "unix-time", + "type": "integer" + }, + "offline": { + "properties": {}, + "title": "offline_param", + "type": "object" + }, + "online": { + "properties": { + "ip_address": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["ip_address", "user_agent"], + "title": "online_param", + "type": "object" + }, + "type": { + "enum": ["offline", "online"], + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "customer_acceptance_param", + "type": "object" + } + }, + "required": ["customer_acceptance"], + "title": "secret_key_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + }, + { + "description": "This hash contains details about the Mandate to create", + "properties": { + "customer_acceptance": { + "properties": { + "online": { + "properties": { + "ip_address": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "online_param", + "type": "object" + }, + "type": { + "enum": ["online"], + "maxLength": 5000, + "type": "string" + } + }, + "required": ["online", "type"], + "title": "customer_acceptance_param", + "type": "object" + } + }, + "required": ["customer_acceptance"], + "title": "client_key_param", + "type": "object" + } + ] + }, + "off_session": { + "anyOf": [ + { + "type": "boolean" + }, + { + "enum": ["one_off", "recurring"], + "maxLength": 5000, + "type": "string" + } + ], + "description": "Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards)." }, - "replacement_for": { - "description": "The card this is meant to be a replacement for (if any).", + "payment_method": { + "description": "ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.", "maxLength": 5000, "type": "string" }, - "replacement_reason": { - "description": "If `replacement_for` is specified, this should indicate why that card is being replaced.", - "enum": ["damaged", "expired", "lost", "stolen"], - "type": "string", - "x-stripeBypassValidation": true - }, - "shipping": { - "description": "The address where the card will be shipped.", + "payment_method_data": { + "description": "If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear\nin the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)\nproperty on the PaymentIntent.", "properties": { - "address": { + "acss_debit": { "properties": { - "city": { + "account_number": { "maxLength": 5000, "type": "string" }, - "country": { + "institution_number": { "maxLength": 5000, "type": "string" }, - "line1": { + "transit_number": { "maxLength": 5000, "type": "string" - }, - "line2": { + } + }, + "required": [ + "account_number", + "institution_number", + "transit_number" + ], + "title": "payment_method_param", + "type": "object" + }, + "affirm": { + "properties": {}, + "title": "param", + "type": "object" + }, + "afterpay_clearpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "alipay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "allow_redisplay": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "amazon_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "au_becs_debit": { + "properties": { + "account_number": { "maxLength": 5000, "type": "string" }, - "postal_code": { + "bsb_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "bsb_number"], + "title": "param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "account_number": { "maxLength": 5000, "type": "string" }, - "state": { + "sort_code": { "maxLength": 5000, "type": "string" } }, - "required": ["city", "country", "line1", "postal_code"], - "title": "required_address", + "title": "param", "type": "object" }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "service": { - "enum": ["express", "priority", "standard"], - "type": "string", - "x-stripeBypassValidation": true + "bancontact": { + "properties": {}, + "title": "param", + "type": "object" }, - "type": { - "enum": ["bulk", "individual"], - "type": "string" - } - }, - "required": ["address", "name"], - "title": "shipping_specs", - "type": "object" - }, - "spending_controls": { - "description": "Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", - "properties": { - "allowed_categories": { - "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], - "maxLength": 5000, - "type": "string" + "billing_details": { + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "billing_details_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "name": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } }, - "type": "array" + "title": "billing_details_inner_params", + "type": "object" }, - "blocked_categories": { - "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], - "maxLength": 5000, + "blik": { + "properties": {}, + "title": "param", + "type": "object" + }, + "boleto": { + "properties": { + "tax_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "param", + "type": "object" + }, + "cashapp": { + "properties": {}, + "title": "param", + "type": "object" + }, + "customer_balance": { + "properties": {}, + "title": "param", + "type": "object" + }, + "eps": { + "properties": { + "bank": { + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "fpx": { + "properties": { + "bank": { + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["bank"], + "title": "param", + "type": "object" + }, + "giropay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "grabpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "ideal": { + "properties": { + "bank": { + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "interac_present": { + "properties": {}, + "title": "param", + "type": "object" + }, + "klarna": { + "properties": { + "dob": { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth", + "type": "object" + } + }, + "title": "param", + "type": "object" + }, + "konbini": { + "properties": {}, + "title": "param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "param", + "type": "object" + }, + "metadata": { + "additionalProperties": { "type": "string" }, - "type": "array" + "type": "object" + }, + "mobilepay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "multibanco": { + "properties": {}, + "title": "param", + "type": "object" + }, + "oxxo": { + "properties": {}, + "title": "param", + "type": "object" + }, + "p24": { + "properties": { + "bank": { + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "param", + "type": "object" + }, + "paynow": { + "properties": {}, + "title": "param", + "type": "object" + }, + "paypal": { + "properties": {}, + "title": "param", + "type": "object" + }, + "pix": { + "properties": {}, + "title": "param", + "type": "object" + }, + "promptpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "radar_options": { + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" }, - "spending_limits": { - "items": { - "properties": { - "amount": { - "type": "integer" + "revolut_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "iban": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["iban"], + "title": "param", + "type": "object" + }, + "sofort": { + "properties": { + "country": { + "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], + "type": "string" + } + }, + "required": ["country"], + "title": "param", + "type": "object" + }, + "swish": { + "properties": {}, + "title": "param", + "type": "object" + }, + "twint": { + "properties": {}, + "title": "param", + "type": "object" + }, + "type": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "properties": { + "account_holder_type": { + "enum": ["company", "individual"], + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "savings"], + "type": "string" + }, + "financial_connections_account": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "wechat_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "zip": { + "properties": {}, + "title": "param", + "type": "object" + } + }, + "required": ["type"], + "title": "payment_method_data_params", + "type": "object" + }, + "payment_method_options": { + "description": "Payment method-specific configuration for this PaymentIntent.", + "properties": { + "acss_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "custom_mandate_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "interval_description": { + "maxLength": 500, + "type": "string" + }, + "payment_schedule": { + "enum": [ + "combined", + "interval", + "sporadic" + ], + "type": "string" + }, + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_mandate_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "affirm": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "maxLength": 30, + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "afterpay_clearpay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "reference": { + "maxLength": 128, + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "alipay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "amazon_pay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "au_becs_debit": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bacs_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bancontact": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": ["de", "en", "fr", "nl"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "blik": { + "anyOf": [ + { + "properties": { + "code": { + "maxLength": 5000, + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "boleto": { + "anyOf": [ + { + "properties": { + "expires_after_days": { + "type": "integer" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "cvc_token": { + "maxLength": 5000, + "type": "string" + }, + "installments": { + "properties": { + "enabled": { + "type": "boolean" + }, + "plan": { + "anyOf": [ + { + "properties": { + "count": { + "type": "integer" + }, + "interval": { + "enum": ["month"], + "type": "string" + }, + "type": { + "enum": ["fixed_count"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "installment_plan", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "installments_param", + "type": "object" + }, + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + }, + "end_date": { + "format": "unix-time", + "type": "integer" + }, + "interval": { + "enum": [ + "day", + "month", + "sporadic", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "type": "integer" + }, + "reference": { + "maxLength": 80, + "type": "string" + }, + "start_date": { + "format": "unix-time", + "type": "integer" + }, + "supported_types": { + "items": { + "enum": ["india"], + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "amount", + "amount_type", + "interval", + "reference", + "start_date" + ], + "title": "mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_extended_authorization": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_incremental_authorization": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_multicapture": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_overcapture": { + "enum": ["if_available", "never"], + "type": "string" + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string", + "x-stripeBypassValidation": true + }, + "require_cvc_recollection": { + "type": "boolean" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + }, + "statement_descriptor_suffix_kana": { + "anyOf": [ + { + "maxLength": 22, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "statement_descriptor_suffix_kanji": { + "anyOf": [ + { + "maxLength": 17, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "three_d_secure": { + "properties": { + "ares_trans_status": { + "enum": ["A", "C", "I", "N", "R", "U", "Y"], + "type": "string" + }, + "cryptogram": { + "maxLength": 5000, + "type": "string" + }, + "electronic_commerce_indicator": { + "enum": ["01", "02", "05", "06", "07"], + "type": "string", + "x-stripeBypassValidation": true + }, + "exemption_indicator": { + "enum": ["low_risk", "none"], + "type": "string" + }, + "network_options": { + "properties": { + "cartes_bancaires": { + "properties": { + "cb_avalgo": { + "enum": [ + "0", + "1", + "2", + "3", + "4", + "A" + ], + "type": "string" + }, + "cb_exemption": { + "maxLength": 4, + "type": "string" + }, + "cb_score": { + "type": "integer" + } + }, + "required": ["cb_avalgo"], + "title": "cartes_bancaires_network_options_param", + "type": "object" + } + }, + "title": "network_options_param", + "type": "object" + }, + "requestor_challenge_indicator": { + "maxLength": 2, + "type": "string" + }, + "transaction_id": { + "maxLength": 5000, + "type": "string" + }, + "version": { + "enum": ["1.0.2", "2.1.0", "2.2.0"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": [ + "cryptogram", + "transaction_id", + "version" + ], + "title": "payment_method_options_param", + "type": "object" + } + }, + "title": "payment_intent_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card_present": { + "anyOf": [ + { + "properties": { + "request_extended_authorization": { + "type": "boolean" + }, + "request_incremental_authorization_support": { + "type": "boolean" + }, + "routing": { + "properties": { + "requested_priority": { + "enum": ["domestic", "international"], + "type": "string" + } + }, + "title": "routing_payment_method_options_param", + "type": "object" + } }, - "categories": { - "items": { + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "cashapp": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" + "", + "none", + "off_session", + "on_session" ], - "maxLength": 5000, "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "customer_balance": { + "anyOf": [ + { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_params", + "type": "object" + }, + "requested_address_types": { + "items": { + "enum": [ + "aba", + "iban", + "sepa", + "sort_code", + "spei", + "swift", + "zengin" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "type": { + "enum": [ + "eu_bank_transfer", + "gb_bank_transfer", + "jp_bank_transfer", + "mx_bank_transfer", + "us_bank_transfer" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["type"], + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "enum": ["bank_transfer"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "eps": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "fpx": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "giropay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "grabpay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "ideal": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "interac_present": { + "anyOf": [ + { + "properties": {}, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "klarna": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "enum": [ + "cs-CZ", + "da-DK", + "de-AT", + "de-CH", + "de-DE", + "el-GR", + "en-AT", + "en-AU", + "en-BE", + "en-CA", + "en-CH", + "en-CZ", + "en-DE", + "en-DK", + "en-ES", + "en-FI", + "en-FR", + "en-GB", + "en-GR", + "en-IE", + "en-IT", + "en-NL", + "en-NO", + "en-NZ", + "en-PL", + "en-PT", + "en-RO", + "en-SE", + "en-US", + "es-ES", + "es-US", + "fi-FI", + "fr-BE", + "fr-CA", + "fr-CH", + "fr-FR", + "it-CH", + "it-IT", + "nb-NO", + "nl-BE", + "nl-NL", + "pl-PL", + "pt-PT", + "ro-RO", + "sv-FI", + "sv-SE" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "konbini": { + "anyOf": [ + { + "properties": { + "confirmation_number": { + "anyOf": [ + { + "maxLength": 11, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "expires_after_days": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "expires_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "product_description": { + "anyOf": [ + { + "maxLength": 22, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "type": "array" + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } }, - "interval": { - "enum": [ - "all_time", - "daily", - "monthly", - "per_authorization", - "weekly", - "yearly" - ], - "type": "string" - } + "title": "payment_method_options_param", + "type": "object" }, - "required": ["amount", "interval"], - "title": "spending_limits_param", - "type": "object" - }, - "type": "array" - } - }, - "title": "authorization_controls_param", - "type": "object" - }, - "status": { - "description": "Whether authorizations can be approved on this card. Defaults to `inactive`.", - "enum": ["active", "inactive"], - "type": "string" - }, - "type": { - "description": "The type of card to issue. Possible values are `physical` or `virtual`.", - "enum": ["physical", "virtual"], - "type": "string" - } - }, - "required": ["currency", "type"], - "type": "object" - } - } - }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.card" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/issuing/cards/{card}": { - "get": { - "description": "

Retrieves an Issuing Card object.

", - "operationId": "GetIssuingCardsCard", - "parameters": [ - { - "in": "path", - "name": "card", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.card" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates the specified Issuing Card object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostIssuingCardsCard", - "parameters": [ - { - "in": "path", - "name": "card", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "spending_controls": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "cancellation_reason": { - "description": "Reason why the `status` of this card is `canceled`.", - "enum": ["lost", "stolen"], - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" + { + "enum": [""], + "type": "string" + } + ] }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "spending_controls": { - "description": "Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.", - "properties": { - "allowed_categories": { - "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "link": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "blocked_categories": { - "items": { - "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" - ], - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "mobilepay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "multibanco": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "oxxo": { + "anyOf": [ + { + "properties": { + "expires_after_days": { + "type": "integer" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "p24": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + }, + "tos_shown_and_accepted": { + "type": "boolean" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "paynow": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "paypal": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "preferred_locale": { + "enum": [ + "cs-CZ", + "da-DK", + "de-AT", + "de-DE", + "de-LU", + "el-GR", + "en-GB", + "en-US", + "es-ES", + "fi-FI", + "fr-BE", + "fr-FR", + "fr-LU", + "hu-HU", + "it-IT", + "nl-BE", + "nl-NL", + "pl-PL", + "pt-PT", + "sk-SK", + "sv-SE" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "reference": { + "maxLength": 127, + "type": "string" + }, + "risk_correlation_id": { + "maxLength": 32, + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "pix": { + "anyOf": [ + { + "properties": { + "expires_after_seconds": { + "type": "integer" + }, + "expires_at": { + "format": "unix-time", + "type": "integer" + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "promptpay": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "revolut_pay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "enum": ["", "manual"], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + }, + "setup_future_usage": { + "enum": [ + "", + "none", + "off_session", + "on_session" + ], + "type": "string" + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sofort": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": [ + "", + "de", + "en", + "es", + "fr", + "it", + "nl", + "pl" + ], + "type": "string" + }, + "setup_future_usage": { + "enum": ["", "none", "off_session"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "spending_limits": { - "items": { - "properties": { - "amount": { - "type": "integer" + "swish": { + "anyOf": [ + { + "properties": { + "reference": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } }, - "categories": { - "items": { + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "twint": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "title": "linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "return_url": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "linked_account_options_param", + "type": "object" + }, + "mandate_options": { + "properties": { + "collection_method": { + "enum": ["", "paper"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "networks": { + "properties": { + "requested": { + "items": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "type": "array" + } + }, + "title": "networks_options_param", + "type": "object" + }, + "preferred_settlement_speed": { + "enum": ["", "fastest", "standard"], + "type": "string" + }, + "setup_future_usage": { "enum": [ - "ac_refrigeration_repair", - "accounting_bookkeeping_services", - "advertising_services", - "agricultural_cooperative", - "airlines_air_carriers", - "airports_flying_fields", - "ambulance_services", - "amusement_parks_carnivals", - "antique_reproductions", - "antique_shops", - "aquariums", - "architectural_surveying_services", - "art_dealers_and_galleries", - "artists_supply_and_craft_shops", - "auto_and_home_supply_stores", - "auto_body_repair_shops", - "auto_paint_shops", - "auto_service_shops", - "automated_cash_disburse", - "automated_fuel_dispensers", - "automobile_associations", - "automotive_parts_and_accessories_stores", - "automotive_tire_stores", - "bail_and_bond_payments", - "bakeries", - "bands_orchestras", - "barber_and_beauty_shops", - "betting_casino_gambling", - "bicycle_shops", - "billiard_pool_establishments", - "boat_dealers", - "boat_rentals_and_leases", - "book_stores", - "books_periodicals_and_newspapers", - "bowling_alleys", - "bus_lines", - "business_secretarial_schools", - "buying_shopping_services", - "cable_satellite_and_other_pay_television_and_radio", - "camera_and_photographic_supply_stores", - "candy_nut_and_confectionery_stores", - "car_and_truck_dealers_new_used", - "car_and_truck_dealers_used_only", - "car_rental_agencies", - "car_washes", - "carpentry_services", - "carpet_upholstery_cleaning", - "caterers", - "charitable_and_social_service_organizations_fundraising", - "chemicals_and_allied_products", - "child_care_services", - "childrens_and_infants_wear_stores", - "chiropodists_podiatrists", - "chiropractors", - "cigar_stores_and_stands", - "civic_social_fraternal_associations", - "cleaning_and_maintenance", - "clothing_rental", - "colleges_universities", - "commercial_equipment", - "commercial_footwear", - "commercial_photography_art_and_graphics", - "commuter_transport_and_ferries", - "computer_network_services", - "computer_programming", - "computer_repair", - "computer_software_stores", - "computers_peripherals_and_software", - "concrete_work_services", - "construction_materials", - "consulting_public_relations", - "correspondence_schools", - "cosmetic_stores", - "counseling_services", - "country_clubs", - "courier_services", - "court_costs", - "credit_reporting_agencies", - "cruise_lines", - "dairy_products_stores", - "dance_hall_studios_schools", - "dating_escort_services", - "dentists_orthodontists", - "department_stores", - "detective_agencies", - "digital_goods_applications", - "digital_goods_games", - "digital_goods_large_volume", - "digital_goods_media", - "direct_marketing_catalog_merchant", - "direct_marketing_combination_catalog_and_retail_merchant", - "direct_marketing_inbound_telemarketing", - "direct_marketing_insurance_services", - "direct_marketing_other", - "direct_marketing_outbound_telemarketing", - "direct_marketing_subscription", - "direct_marketing_travel", - "discount_stores", - "doctors", - "door_to_door_sales", - "drapery_window_covering_and_upholstery_stores", - "drinking_places", - "drug_stores_and_pharmacies", - "drugs_drug_proprietaries_and_druggist_sundries", - "dry_cleaners", - "durable_goods", - "duty_free_stores", - "eating_places_restaurants", - "educational_services", - "electric_razor_stores", - "electrical_parts_and_equipment", - "electrical_services", - "electronics_repair_shops", - "electronics_stores", - "elementary_secondary_schools", - "employment_temp_agencies", - "equipment_rental", - "exterminating_services", - "family_clothing_stores", - "fast_food_restaurants", - "financial_institutions", - "fines_government_administrative_entities", - "fireplace_fireplace_screens_and_accessories_stores", - "floor_covering_stores", - "florists", - "florists_supplies_nursery_stock_and_flowers", - "freezer_and_locker_meat_provisioners", - "fuel_dealers_non_automotive", - "funeral_services_crematories", - "furniture_home_furnishings_and_equipment_stores_except_appliances", - "furniture_repair_refinishing", - "furriers_and_fur_shops", - "general_services", - "gift_card_novelty_and_souvenir_shops", - "glass_paint_and_wallpaper_stores", - "glassware_crystal_stores", - "golf_courses_public", - "government_services", - "grocery_stores_supermarkets", - "hardware_equipment_and_supplies", - "hardware_stores", - "health_and_beauty_spas", - "hearing_aids_sales_and_supplies", - "heating_plumbing_a_c", - "hobby_toy_and_game_shops", - "home_supply_warehouse_stores", - "hospitals", - "hotels_motels_and_resorts", - "household_appliance_stores", - "industrial_supplies", - "information_retrieval_services", - "insurance_default", - "insurance_underwriting_premiums", - "intra_company_purchases", - "jewelry_stores_watches_clocks_and_silverware_stores", - "landscaping_services", - "laundries", - "laundry_cleaning_services", - "legal_services_attorneys", - "luggage_and_leather_goods_stores", - "lumber_building_materials_stores", - "manual_cash_disburse", - "marinas_service_and_supplies", - "masonry_stonework_and_plaster", - "massage_parlors", - "medical_and_dental_labs", - "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", - "medical_services", - "membership_organizations", - "mens_and_boys_clothing_and_accessories_stores", - "mens_womens_clothing_stores", - "metal_service_centers", - "miscellaneous", - "miscellaneous_apparel_and_accessory_shops", - "miscellaneous_auto_dealers", - "miscellaneous_business_services", - "miscellaneous_food_stores", - "miscellaneous_general_merchandise", - "miscellaneous_general_services", - "miscellaneous_home_furnishing_specialty_stores", - "miscellaneous_publishing_and_printing", - "miscellaneous_recreation_services", - "miscellaneous_repair_shops", - "miscellaneous_specialty_retail", - "mobile_home_dealers", - "motion_picture_theaters", - "motor_freight_carriers_and_trucking", - "motor_homes_dealers", - "motor_vehicle_supplies_and_new_parts", - "motorcycle_shops_and_dealers", - "motorcycle_shops_dealers", - "music_stores_musical_instruments_pianos_and_sheet_music", - "news_dealers_and_newsstands", - "non_fi_money_orders", - "non_fi_stored_value_card_purchase_load", - "nondurable_goods", - "nurseries_lawn_and_garden_supply_stores", - "nursing_personal_care", - "office_and_commercial_furniture", - "opticians_eyeglasses", - "optometrists_ophthalmologist", - "orthopedic_goods_prosthetic_devices", - "osteopaths", - "package_stores_beer_wine_and_liquor", - "paints_varnishes_and_supplies", - "parking_lots_garages", - "passenger_railways", - "pawn_shops", - "pet_shops_pet_food_and_supplies", - "petroleum_and_petroleum_products", - "photo_developing", - "photographic_photocopy_microfilm_equipment_and_supplies", - "photographic_studios", - "picture_video_production", - "piece_goods_notions_and_other_dry_goods", - "plumbing_heating_equipment_and_supplies", - "political_organizations", - "postal_services_government_only", - "precious_stones_and_metals_watches_and_jewelry", - "professional_services", - "public_warehousing_and_storage", - "quick_copy_repro_and_blueprint", - "railroads", - "real_estate_agents_and_managers_rentals", - "record_stores", - "recreational_vehicle_rentals", - "religious_goods_stores", - "religious_organizations", - "roofing_siding_sheet_metal", - "secretarial_support_services", - "security_brokers_dealers", - "service_stations", - "sewing_needlework_fabric_and_piece_goods_stores", - "shoe_repair_hat_cleaning", - "shoe_stores", - "small_appliance_repair", - "snowmobile_dealers", - "special_trade_services", - "specialty_cleaning", - "sporting_goods_stores", - "sporting_recreation_camps", - "sports_and_riding_apparel_stores", - "sports_clubs_fields", - "stamp_and_coin_stores", - "stationary_office_supplies_printing_and_writing_paper", - "stationery_stores_office_and_school_supply_stores", - "swimming_pools_sales", - "t_ui_travel_germany", - "tailors_alterations", - "tax_payments_government_agencies", - "tax_preparation_services", - "taxicabs_limousines", - "telecommunication_equipment_and_telephone_sales", - "telecommunication_services", - "telegraph_services", - "tent_and_awning_shops", - "testing_laboratories", - "theatrical_ticket_agencies", - "timeshares", - "tire_retreading_and_repair", - "tolls_bridge_fees", - "tourist_attractions_and_exhibits", - "towing_services", - "trailer_parks_campgrounds", - "transportation_services", - "travel_agencies_tour_operators", - "truck_stop_iteration", - "truck_utility_trailer_rentals", - "typesetting_plate_making_and_related_services", - "typewriter_stores", - "u_s_federal_government_agencies_or_departments", - "uniforms_commercial_clothing", - "used_merchandise_and_secondhand_stores", - "utilities", - "variety_stores", - "veterinary_services", - "video_amusement_game_supplies", - "video_game_arcades", - "video_tape_rental_stores", - "vocational_trade_schools", - "watch_jewelry_repair", - "welding_repair", - "wholesale_clubs", - "wig_and_toupee_stores", - "wires_money_orders", - "womens_accessory_and_specialty_shops", - "womens_ready_to_wear_stores", - "wrecking_and_salvage_yards" + "", + "none", + "off_session", + "on_session" ], + "type": "string" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "payment_intent_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "wechat_pay": { + "anyOf": [ + { + "properties": { + "app_id": { "maxLength": 5000, "type": "string" }, - "type": "array" + "client": { + "enum": ["android", "ios", "web"], + "type": "string", + "x-stripeBypassValidation": true + }, + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } }, - "interval": { - "enum": [ - "all_time", - "daily", - "monthly", - "per_authorization", - "weekly", - "yearly" - ], - "type": "string" - } + "required": ["client"], + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "zip": { + "anyOf": [ + { + "properties": { + "setup_future_usage": { + "enum": ["none"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "payment_method_types": { + "description": "The list of payment method types (for example, a card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "radar_options": { + "description": "Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).", + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "receipt_email": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails)." + }, + "return_url": { + "description": "The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.\nIf you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.\nThis parameter is only used for cards and other redirect-based payment methods.", + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nIf you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.\n\nIf the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.\n\nWhen processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).\n\nIf you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.", + "enum": ["", "off_session", "on_session"], + "type": "string" + }, + "shipping": { + "anyOf": [ + { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" }, - "required": ["amount", "interval"], - "title": "spending_limits_param", - "type": "object" + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "tracking_number": { + "maxLength": 5000, + "type": "string" + } }, - "type": "array" + "required": ["address", "name"], + "title": "optional_fields_shipping", + "type": "object" + }, + { + "enum": [""], + "type": "string" } - }, - "title": "authorization_controls_param", - "type": "object" + ], + "description": "Shipping information for this PaymentIntent." }, - "status": { - "description": "Dictates whether authorizations can be approved on this card. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`.", - "enum": ["active", "canceled", "inactive"], - "type": "string", - "x-stripeBypassValidation": true + "use_stripe_sdk": { + "description": "Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.", + "type": "boolean" } }, "type": "object" @@ -58236,7 +106494,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/issuing.card" + "$ref": "#/components/schemas/payment_intent" } } }, @@ -58255,43 +106513,219 @@ } } }, - "/v1/issuing/disputes": { - "get": { - "description": "

Returns a list of Issuing Dispute objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", - "operationId": "GetIssuingDisputes", + "/v1/payment_intents/{intent}/increment_authorization": { + "post": { + "description": "

Perform an incremental authorization on an eligible\nPaymentIntent. To be eligible, the\nPaymentIntent’s status must be requires_capture and\nincremental_authorization_supported\nmust be true.

\n\n

Incremental authorizations attempt to increase the authorized amount on\nyour customer’s card to the new, higher amount provided. Similar to the\ninitial authorization, incremental authorizations can be declined. A\nsingle PaymentIntent can call this endpoint multiple times to further\nincrease the authorized amount.

\n\n

If the incremental authorization succeeds, the PaymentIntent object\nreturns with the updated\namount.\nIf the incremental authorization fails, a\ncard_declined error returns, and no other\nfields on the PaymentIntent or Charge update. The PaymentIntent\nobject remains capturable for the previously authorized amount.

\n\n

Each PaymentIntent can have a maximum of 10 incremental authorization attempts, including declines.\nAfter it’s captured, a PaymentIntent can no longer be incremented.

\n\n

Learn more about incremental authorizations.

", + "operationId": "PostPaymentIntentsIntentIncrementAuthorization", "parameters": [ { - "description": "Select Issuing disputes that were created during the given date interval.", - "explode": true, - "in": "query", - "name": "created", - "required": false, + "in": "path", + "name": "intent", + "required": true, "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "The updated total amount that you intend to collect from the cardholder. This amount must be greater than the currently authorized amount.", + "type": "integer" + }, + "application_fee_amount": { + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "type": "integer" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 1000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "gte": { - "type": "integer" + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" }, - "lt": { - "type": "integer" + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "statement_descriptor": { + "description": "Text that appears on the customer's statement as the statement descriptor for a non-card or card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).", + "maxLength": 22, + "type": "string" + }, + "transfer_data": { + "description": "The parameters used to automatically create a transfer after the payment is captured.\nLearn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "properties": { + "amount": { + "type": "integer" + } }, - "lte": { + "title": "transfer_data_update_params", + "type": "object" + } + }, + "required": ["amount"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payment_intent" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/payment_intents/{intent}/verify_microdeposits": { + "post": { + "description": "

Verifies microdeposits on a PaymentIntent object.

", + "operationId": "PostPaymentIntentsIntentVerifyMicrodeposits", + "parameters": [ + { + "in": "path", + "name": "intent", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "amounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amounts": { + "description": "Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.", + "items": { "type": "integer" - } + }, + "type": "array" }, - "title": "range_query_specs", - "type": "object" + "client_secret": { + "description": "The client secret of the PaymentIntent.", + "maxLength": 5000, + "type": "string" + }, + "descriptor_code": { + "description": "A six-character code starting with SM present in the microdeposit sent to the bank account.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } }, - { - "type": "integer" + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payment_intent" } - ] + } }, - "style": "deepObject" + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/payment_links": { + "get": { + "description": "

Returns a list of your payment links.

", + "operationId": "GetPaymentLinks", + "parameters": [ + { + "description": "Only return payment links that are active or inactive (e.g., pass `false` to list all inactive payment links).", + "in": "query", + "name": "active", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", @@ -58339,28 +106773,6 @@ "type": "string" }, "style": "form" - }, - { - "description": "Select Issuing disputes with the given status.", - "in": "query", - "name": "status", - "required": false, - "schema": { - "enum": ["expired", "lost", "submitted", "unsubmitted", "won"], - "type": "string" - }, - "style": "form" - }, - { - "description": "Select the Issuing dispute for the given transaction.", - "in": "query", - "name": "transaction", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" } ], "requestBody": { @@ -58368,6 +106780,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -58384,7 +106797,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/issuing.dispute" + "$ref": "#/components/schemas/payment_link" }, "type": "array" }, @@ -58400,12 +106813,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/issuing/disputes", + "pattern": "^/v1/payment_links", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "IssuingDisputeList", + "title": "PaymentLinksResourcePaymentLinkList", "type": "object", "x-expandableFields": ["data"] } @@ -58426,13 +106839,29 @@ } }, "post": { - "description": "

Creates an Issuing Dispute object. Individual pieces of evidence within the evidence object are optional at this point. Stripe only validates that required evidence is present during submission. Refer to Dispute reasons and evidence for more details about evidence requirements.

", - "operationId": "PostIssuingDisputes", + "description": "

Creates a payment link.

", + "operationId": "PostPaymentLinks", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "evidence": { + "after_completion": { + "explode": true, + "style": "deepObject" + }, + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "consent_collection": { + "explode": true, + "style": "deepObject" + }, + "custom_fields": { + "explode": true, + "style": "deepObject" + }, + "custom_text": { "explode": true, "style": "deepObject" }, @@ -58440,100 +106869,263 @@ "explode": true, "style": "deepObject" }, + "invoice_creation": { + "explode": true, + "style": "deepObject" + }, + "line_items": { + "explode": true, + "style": "deepObject" + }, "metadata": { "explode": true, "style": "deepObject" + }, + "payment_intent_data": { + "explode": true, + "style": "deepObject" + }, + "payment_method_types": { + "explode": true, + "style": "deepObject" + }, + "phone_number_collection": { + "explode": true, + "style": "deepObject" + }, + "restrictions": { + "explode": true, + "style": "deepObject" + }, + "shipping_address_collection": { + "explode": true, + "style": "deepObject" + }, + "shipping_options": { + "explode": true, + "style": "deepObject" + }, + "subscription_data": { + "explode": true, + "style": "deepObject" + }, + "tax_id_collection": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "evidence": { - "description": "Evidence provided for the dispute.", + "after_completion": { + "description": "Behavior after the purchase is complete.", "properties": { - "canceled": { - "anyOf": [ - { - "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "canceled_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "cancellation_policy_provided": { - "anyOf": [ - { - "type": "boolean" - }, - { - "enum": [""], + "hosted_confirmation": { + "properties": { + "custom_message": { + "maxLength": 500, + "type": "string" + } + }, + "title": "after_completion_confirmation_page_params", + "type": "object" + }, + "redirect": { + "properties": { + "url": { + "maxLength": 2048, + "type": "string" + } + }, + "required": ["url"], + "title": "after_completion_redirect_params", + "type": "object" + }, + "type": { + "enum": ["hosted_confirmation", "redirect"], + "type": "string" + } + }, + "required": ["type"], + "title": "after_completion_params", + "type": "object" + }, + "allow_promotion_codes": { + "description": "Enables user redeemable promotion codes.", + "type": "boolean" + }, + "application_fee_amount": { + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. Can only be applied when there are no line items with recurring prices.", + "type": "integer" + }, + "application_fee_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.", + "type": "number" + }, + "automatic_tax": { + "description": "Configuration for automatic tax collection.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_params", + "type": "object" + }, + "billing_address_collection": { + "description": "Configuration for collecting the customer's billing address. Defaults to `auto`.", + "enum": ["auto", "required"], + "type": "string" + }, + "consent_collection": { + "description": "Configure fields to gather active consent from customers.", + "properties": { + "payment_method_reuse_agreement": { + "properties": { + "position": { + "enum": ["auto", "hidden"], + "type": "string" + } + }, + "required": ["position"], + "title": "payment_method_reuse_agreement_params", + "type": "object" + }, + "promotions": { + "enum": ["auto", "none"], + "type": "string" + }, + "terms_of_service": { + "enum": ["none", "required"], + "type": "string" + } + }, + "title": "consent_collection_params", + "type": "object" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies) and supported by each line item's price.", + "type": "string" + }, + "custom_fields": { + "description": "Collect additional information from your customer using custom fields. Up to 3 fields are supported.", + "items": { + "properties": { + "dropdown": { + "properties": { + "options": { + "items": { + "properties": { + "label": { + "maxLength": 100, "type": "string" - } - ] - }, - "cancellation_reason": { - "maxLength": 1500, - "type": "string" - }, - "expected_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" }, - { - "enum": [""], + "value": { + "maxLength": 100, "type": "string" } - ] - }, - "explanation": { - "maxLength": 1500, - "type": "string" - }, - "product_description": { - "maxLength": 1500, - "type": "string" - }, - "product_type": { - "enum": ["", "merchandise", "service"], - "type": "string" + }, + "required": ["label", "value"], + "title": "custom_field_option_param", + "type": "object" }, - "return_status": { - "enum": ["", "merchant_rejected", "successful"], + "type": "array" + } + }, + "required": ["options"], + "title": "custom_field_dropdown_param", + "type": "object" + }, + "key": { + "maxLength": 200, + "type": "string" + }, + "label": { + "properties": { + "custom": { + "maxLength": 50, + "type": "string" + }, + "type": { + "enum": ["custom"], + "type": "string" + } + }, + "required": ["custom", "type"], + "title": "custom_field_label_param", + "type": "object" + }, + "numeric": { + "properties": { + "maximum_length": { + "type": "integer" + }, + "minimum_length": { + "type": "integer" + } + }, + "title": "custom_field_numeric_param", + "type": "object" + }, + "optional": { + "type": "boolean" + }, + "text": { + "properties": { + "maximum_length": { + "type": "integer" + }, + "minimum_length": { + "type": "integer" + } + }, + "title": "custom_field_text_param", + "type": "object" + }, + "type": { + "enum": ["dropdown", "numeric", "text"], + "type": "string" + } + }, + "required": ["key", "label", "type"], + "title": "custom_field_param", + "type": "object" + }, + "type": "array" + }, + "custom_text": { + "description": "Display additional text for your customers using custom text.", + "properties": { + "after_submit": { + "anyOf": [ + { + "properties": { + "message": { + "maxLength": 1200, "type": "string" - }, - "returned_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] } }, - "title": "canceled", + "required": ["message"], + "title": "custom_text_position_param", "type": "object" }, { @@ -58542,64 +107134,36 @@ } ] }, - "duplicate": { + "shipping_address": { "anyOf": [ { "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "card_statement": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "cash_receipt": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "check_image": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "explanation": { - "maxLength": 1500, + "message": { + "maxLength": 1200, "type": "string" - }, - "original_transaction": { - "maxLength": 5000, + } + }, + "required": ["message"], + "title": "custom_text_position_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "submit": { + "anyOf": [ + { + "properties": { + "message": { + "maxLength": 1200, "type": "string" } }, - "title": "duplicate", + "required": ["message"], + "title": "custom_text_position_param", "type": "object" }, { @@ -58608,27 +107172,17 @@ } ] }, - "fraudulent": { + "terms_of_service_acceptance": { "anyOf": [ { "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "explanation": { - "maxLength": 1500, + "message": { + "maxLength": 1200, "type": "string" } }, - "title": "fraudulent", + "required": ["message"], + "title": "custom_text_position_param", "type": "object" }, { @@ -58636,250 +107190,661 @@ "type": "string" } ] + } + }, + "title": "custom_text_param", + "type": "object" + }, + "customer_creation": { + "description": "Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).", + "enum": ["always", "if_required"], + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "inactive_message": { + "description": "The custom message to be displayed to a customer when a payment link is no longer active.", + "maxLength": 500, + "type": "string" + }, + "invoice_creation": { + "description": "Generate a post-purchase Invoice for one-time payments.", + "properties": { + "enabled": { + "type": "boolean" + }, + "invoice_data": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "custom_fields": { + "anyOf": [ + { + "items": { + "properties": { + "name": { + "maxLength": 40, + "type": "string" + }, + "value": { + "maxLength": 140, + "type": "string" + } + }, + "required": ["name", "value"], + "title": "custom_field_params", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "description": { + "maxLength": 1500, + "type": "string" + }, + "footer": { + "maxLength": 5000, + "type": "string" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "rendering_options": { + "anyOf": [ + { + "properties": { + "amount_tax_display": { + "enum": [ + "", + "exclude_tax", + "include_inclusive_tax" + ], + "type": "string" + } + }, + "title": "rendering_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "invoice_settings_params", + "type": "object" + } + }, + "required": ["enabled"], + "title": "invoice_creation_create_params", + "type": "object" + }, + "line_items": { + "description": "The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.", + "items": { + "properties": { + "adjustable_quantity": { + "properties": { + "enabled": { + "type": "boolean" + }, + "maximum": { + "type": "integer" + }, + "minimum": { + "type": "integer" + } + }, + "required": ["enabled"], + "title": "adjustable_quantity_params", + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + } + }, + "required": ["price", "quantity"], + "title": "line_items_create_params", + "type": "object" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.", + "type": "object" + }, + "on_behalf_of": { + "description": "The account on behalf of which to charge.", + "type": "string" + }, + "payment_intent_data": { + "description": "A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.", + "properties": { + "capture_method": { + "enum": ["automatic", "automatic_async", "manual"], + "type": "string" + }, + "description": { + "maxLength": 1000, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "setup_future_usage": { + "enum": ["off_session", "on_session"], + "type": "string" + }, + "statement_descriptor": { + "maxLength": 22, + "type": "string" + }, + "statement_descriptor_suffix": { + "maxLength": 22, + "type": "string" + }, + "transfer_group": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_intent_data_params", + "type": "object" + }, + "payment_method_collection": { + "description": "Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.\n\nCan only be set in `subscription` mode. Defaults to `always`.\n\nIf you'd like information on how to collect a payment method outside of Checkout, read the guide on [configuring subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).", + "enum": ["always", "if_required"], + "type": "string" + }, + "payment_method_types": { + "description": "The list of payment method types that customers can use. If no value is passed, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods) (20+ payment methods [supported](https://stripe.com/docs/payments/payment-methods/integration-options#payment-method-product-support)).", + "items": { + "enum": [ + "affirm", + "afterpay_clearpay", + "alipay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "cashapp", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "phone_number_collection": { + "description": "Controls phone number collection settings during checkout.\n\nWe recommend that you review your privacy policy and check with your legal contacts.", + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "phone_number_collection_params", + "type": "object" + }, + "restrictions": { + "description": "Settings that restrict the usage of a payment link.", + "properties": { + "completed_sessions": { + "properties": { + "limit": { + "type": "integer" + } + }, + "required": ["limit"], + "title": "completed_sessions_params", + "type": "object" + } + }, + "required": ["completed_sessions"], + "title": "restrictions_params", + "type": "object" + }, + "shipping_address_collection": { + "description": "Configuration for collecting the customer's shipping address.", + "properties": { + "allowed_countries": { + "items": { + "enum": [ + "AC", + "AD", + "AE", + "AF", + "AG", + "AI", + "AL", + "AM", + "AO", + "AQ", + "AR", + "AT", + "AU", + "AW", + "AX", + "AZ", + "BA", + "BB", + "BD", + "BE", + "BF", + "BG", + "BH", + "BI", + "BJ", + "BL", + "BM", + "BN", + "BO", + "BQ", + "BR", + "BS", + "BT", + "BV", + "BW", + "BY", + "BZ", + "CA", + "CD", + "CF", + "CG", + "CH", + "CI", + "CK", + "CL", + "CM", + "CN", + "CO", + "CR", + "CV", + "CW", + "CY", + "CZ", + "DE", + "DJ", + "DK", + "DM", + "DO", + "DZ", + "EC", + "EE", + "EG", + "EH", + "ER", + "ES", + "ET", + "FI", + "FJ", + "FK", + "FO", + "FR", + "GA", + "GB", + "GD", + "GE", + "GF", + "GG", + "GH", + "GI", + "GL", + "GM", + "GN", + "GP", + "GQ", + "GR", + "GS", + "GT", + "GU", + "GW", + "GY", + "HK", + "HN", + "HR", + "HT", + "HU", + "ID", + "IE", + "IL", + "IM", + "IN", + "IO", + "IQ", + "IS", + "IT", + "JE", + "JM", + "JO", + "JP", + "KE", + "KG", + "KH", + "KI", + "KM", + "KN", + "KR", + "KW", + "KY", + "KZ", + "LA", + "LB", + "LC", + "LI", + "LK", + "LR", + "LS", + "LT", + "LU", + "LV", + "LY", + "MA", + "MC", + "MD", + "ME", + "MF", + "MG", + "MK", + "ML", + "MM", + "MN", + "MO", + "MQ", + "MR", + "MS", + "MT", + "MU", + "MV", + "MW", + "MX", + "MY", + "MZ", + "NA", + "NC", + "NE", + "NG", + "NI", + "NL", + "NO", + "NP", + "NR", + "NU", + "NZ", + "OM", + "PA", + "PE", + "PF", + "PG", + "PH", + "PK", + "PL", + "PM", + "PN", + "PR", + "PS", + "PT", + "PY", + "QA", + "RE", + "RO", + "RS", + "RU", + "RW", + "SA", + "SB", + "SC", + "SE", + "SG", + "SH", + "SI", + "SJ", + "SK", + "SL", + "SM", + "SN", + "SO", + "SR", + "SS", + "ST", + "SV", + "SX", + "SZ", + "TA", + "TC", + "TD", + "TF", + "TG", + "TH", + "TJ", + "TK", + "TL", + "TM", + "TN", + "TO", + "TR", + "TT", + "TV", + "TW", + "TZ", + "UA", + "UG", + "US", + "UY", + "UZ", + "VA", + "VC", + "VE", + "VG", + "VN", + "VU", + "WF", + "WS", + "XK", + "YE", + "YT", + "ZA", + "ZM", + "ZW", + "ZZ" + ], + "type": "string" + }, + "type": "array" + } + }, + "required": ["allowed_countries"], + "title": "shipping_address_collection_params", + "type": "object" + }, + "shipping_options": { + "description": "The shipping rate options to apply to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.", + "items": { + "properties": { + "shipping_rate": { + "maxLength": 5000, + "type": "string" + } }, - "merchandise_not_as_described": { - "anyOf": [ - { - "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "explanation": { - "maxLength": 1500, - "type": "string" - }, - "received_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "return_description": { - "maxLength": 1500, - "type": "string" - }, - "return_status": { - "enum": ["", "merchant_rejected", "successful"], - "type": "string" - }, - "returned_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "merchandise_not_as_described", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] + "title": "shipping_option_params", + "type": "object" + }, + "type": "array" + }, + "submit_type": { + "description": "Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).", + "enum": ["auto", "book", "donate", "pay"], + "type": "string" + }, + "subscription_data": { + "description": "When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.", + "properties": { + "description": { + "maxLength": 500, + "type": "string" }, - "not_received": { - "anyOf": [ - { + "invoice_settings": { + "properties": { + "issuer": { "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "expected_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "explanation": { - "maxLength": 1500, + "account": { "type": "string" }, - "product_description": { - "maxLength": 1500, - "type": "string" - }, - "product_type": { - "enum": ["", "merchandise", "service"], + "type": { + "enum": ["account", "self"], "type": "string" } }, - "title": "not_received", + "required": ["type"], + "title": "param", "type": "object" - }, - { - "enum": [""], - "type": "string" } - ] + }, + "title": "subscription_data_invoice_settings_params", + "type": "object" }, - "other": { - "anyOf": [ - { - "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "explanation": { - "maxLength": 1500, - "type": "string" - }, - "product_description": { - "maxLength": 1500, - "type": "string" - }, - "product_type": { - "enum": ["", "merchandise", "service"], - "type": "string" - } - }, - "title": "other", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" }, - "reason": { - "enum": [ - "canceled", - "duplicate", - "fraudulent", - "merchandise_not_as_described", - "not_received", - "other", - "service_not_as_described" - ], - "type": "string", - "x-stripeBypassValidation": true + "trial_period_days": { + "type": "integer" }, - "service_not_as_described": { - "anyOf": [ - { + "trial_settings": { + "properties": { + "end_behavior": { "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "canceled_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "cancellation_reason": { - "maxLength": 1500, + "missing_payment_method": { + "enum": ["cancel", "create_invoice", "pause"], "type": "string" - }, - "explanation": { - "maxLength": 1500, - "type": "string" - }, - "received_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] } }, - "title": "service_not_as_described", + "required": ["missing_payment_method"], + "title": "end_behavior", "type": "object" - }, - { - "enum": [""], - "type": "string" } - ] + }, + "required": ["end_behavior"], + "title": "trial_settings_config", + "type": "object" } }, - "title": "evidence_param", + "title": "subscription_data_params", "type": "object" }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" + "tax_id_collection": { + "description": "Controls tax ID collection during checkout.", + "properties": { + "enabled": { + "type": "boolean" + } }, - "type": "array" + "required": ["enabled"], + "title": "tax_id_collection_params", + "type": "object" }, - "metadata": { - "additionalProperties": { - "type": "string" + "transfer_data": { + "description": "The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.", + "properties": { + "amount": { + "type": "integer" + }, + "destination": { + "type": "string" + } }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "required": ["destination"], + "title": "transfer_data_params", "type": "object" - }, - "transaction": { - "description": "The ID of the issuing transaction to create a dispute for.", - "maxLength": 5000, - "type": "string" } }, - "required": ["transaction"], + "required": ["line_items"], "type": "object" } } @@ -58891,7 +107856,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/issuing.dispute" + "$ref": "#/components/schemas/payment_link" } } }, @@ -58910,21 +107875,11 @@ } } }, - "/v1/issuing/disputes/{dispute}": { + "/v1/payment_links/{payment_link}": { "get": { - "description": "

Retrieves an Issuing Dispute object.

", - "operationId": "GetIssuingDisputesDispute", + "description": "

Retrieve a payment link.

", + "operationId": "GetPaymentLinksPaymentLink", "parameters": [ - { - "in": "path", - "name": "dispute", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -58939,6 +107894,16 @@ "type": "array" }, "style": "deepObject" + }, + { + "in": "path", + "name": "payment_link", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" } ], "requestBody": { @@ -58946,6 +107911,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -58958,7 +107924,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/issuing.dispute" + "$ref": "#/components/schemas/payment_link" } } }, @@ -58977,12 +107943,12 @@ } }, "post": { - "description": "

Updates the specified Issuing Dispute object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Properties on the evidence object can be unset by passing in an empty string.

", - "operationId": "PostIssuingDisputesDispute", + "description": "

Updates a payment link.

", + "operationId": "PostPaymentLinksPaymentLink", "parameters": [ { "in": "path", - "name": "dispute", + "name": "payment_link", "required": true, "schema": { "maxLength": 5000, @@ -58995,7 +107961,19 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "evidence": { + "after_completion": { + "explode": true, + "style": "deepObject" + }, + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "custom_fields": { + "explode": true, + "style": "deepObject" + }, + "custom_text": { "explode": true, "style": "deepObject" }, @@ -59003,100 +107981,229 @@ "explode": true, "style": "deepObject" }, + "inactive_message": { + "explode": true, + "style": "deepObject" + }, + "invoice_creation": { + "explode": true, + "style": "deepObject" + }, + "line_items": { + "explode": true, + "style": "deepObject" + }, "metadata": { "explode": true, "style": "deepObject" + }, + "payment_intent_data": { + "explode": true, + "style": "deepObject" + }, + "payment_method_types": { + "explode": true, + "style": "deepObject" + }, + "restrictions": { + "explode": true, + "style": "deepObject" + }, + "shipping_address_collection": { + "explode": true, + "style": "deepObject" + }, + "subscription_data": { + "explode": true, + "style": "deepObject" + }, + "tax_id_collection": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "evidence": { - "description": "Evidence provided for the dispute.", + "active": { + "description": "Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.", + "type": "boolean" + }, + "after_completion": { + "description": "Behavior after the purchase is complete.", "properties": { - "canceled": { - "anyOf": [ - { - "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "canceled_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "cancellation_policy_provided": { - "anyOf": [ - { - "type": "boolean" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "cancellation_reason": { - "maxLength": 1500, - "type": "string" - }, - "expected_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" + "hosted_confirmation": { + "properties": { + "custom_message": { + "maxLength": 500, + "type": "string" + } + }, + "title": "after_completion_confirmation_page_params", + "type": "object" + }, + "redirect": { + "properties": { + "url": { + "maxLength": 2048, + "type": "string" + } + }, + "required": ["url"], + "title": "after_completion_redirect_params", + "type": "object" + }, + "type": { + "enum": ["hosted_confirmation", "redirect"], + "type": "string" + } + }, + "required": ["type"], + "title": "after_completion_params", + "type": "object" + }, + "allow_promotion_codes": { + "description": "Enables user redeemable promotion codes.", + "type": "boolean" + }, + "automatic_tax": { + "description": "Configuration for automatic tax collection.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_params", + "type": "object" + }, + "billing_address_collection": { + "description": "Configuration for collecting the customer's billing address. Defaults to `auto`.", + "enum": ["auto", "required"], + "type": "string" + }, + "custom_fields": { + "anyOf": [ + { + "items": { + "properties": { + "dropdown": { + "properties": { + "options": { + "items": { + "properties": { + "label": { + "maxLength": 100, + "type": "string" + }, + "value": { + "maxLength": 100, + "type": "string" + } + }, + "required": ["label", "value"], + "title": "custom_field_option_param", + "type": "object" }, - { - "enum": [""], - "type": "string" - } - ] + "type": "array" + } }, - "explanation": { - "maxLength": 1500, - "type": "string" + "required": ["options"], + "title": "custom_field_dropdown_param", + "type": "object" + }, + "key": { + "maxLength": 200, + "type": "string" + }, + "label": { + "properties": { + "custom": { + "maxLength": 50, + "type": "string" + }, + "type": { + "enum": ["custom"], + "type": "string" + } }, - "product_description": { - "maxLength": 1500, - "type": "string" + "required": ["custom", "type"], + "title": "custom_field_label_param", + "type": "object" + }, + "numeric": { + "properties": { + "maximum_length": { + "type": "integer" + }, + "minimum_length": { + "type": "integer" + } }, - "product_type": { - "enum": ["", "merchandise", "service"], - "type": "string" + "title": "custom_field_numeric_param", + "type": "object" + }, + "optional": { + "type": "boolean" + }, + "text": { + "properties": { + "maximum_length": { + "type": "integer" + }, + "minimum_length": { + "type": "integer" + } }, - "return_status": { - "enum": ["", "merchant_rejected", "successful"], + "title": "custom_field_text_param", + "type": "object" + }, + "type": { + "enum": ["dropdown", "numeric", "text"], + "type": "string" + } + }, + "required": ["key", "label", "type"], + "title": "custom_field_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Collect additional information from your customer using custom fields. Up to 3 fields are supported." + }, + "custom_text": { + "description": "Display additional text for your customers using custom text.", + "properties": { + "after_submit": { + "anyOf": [ + { + "properties": { + "message": { + "maxLength": 1200, "type": "string" - }, - "returned_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] } }, - "title": "canceled", + "required": ["message"], + "title": "custom_text_position_param", "type": "object" }, { @@ -59105,64 +108212,17 @@ } ] }, - "duplicate": { + "shipping_address": { "anyOf": [ { "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "card_statement": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "cash_receipt": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "check_image": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "explanation": { - "maxLength": 1500, - "type": "string" - }, - "original_transaction": { - "maxLength": 5000, + "message": { + "maxLength": 1200, "type": "string" } }, - "title": "duplicate", + "required": ["message"], + "title": "custom_text_position_param", "type": "object" }, { @@ -59171,27 +108231,17 @@ } ] }, - "fraudulent": { + "submit": { "anyOf": [ { "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "explanation": { - "maxLength": 1500, + "message": { + "maxLength": 1200, "type": "string" } }, - "title": "fraudulent", + "required": ["message"], + "title": "custom_text_position_param", "type": "object" }, { @@ -59200,59 +108250,17 @@ } ] }, - "merchandise_not_as_described": { + "terms_of_service_acceptance": { "anyOf": [ { "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "explanation": { - "maxLength": 1500, - "type": "string" - }, - "received_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "return_description": { - "maxLength": 1500, - "type": "string" - }, - "return_status": { - "enum": ["", "merchant_rejected", "successful"], + "message": { + "maxLength": 1200, "type": "string" - }, - "returned_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] } }, - "title": "merchandise_not_as_described", + "required": ["message"], + "title": "custom_text_position_param", "type": "object" }, { @@ -59260,85 +108268,215 @@ "type": "string" } ] + } + }, + "title": "custom_text_param", + "type": "object" + }, + "customer_creation": { + "description": "Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).", + "enum": ["always", "if_required"], + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "inactive_message": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" }, - "not_received": { - "anyOf": [ - { - "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] + { + "enum": [""], + "type": "string" + } + ], + "description": "The custom message to be displayed to a customer when a payment link is no longer active." + }, + "invoice_creation": { + "description": "Generate a post-purchase Invoice for one-time payments.", + "properties": { + "enabled": { + "type": "boolean" + }, + "invoice_data": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "expected_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" + { + "enum": [""], + "type": "string" + } + ] + }, + "custom_fields": { + "anyOf": [ + { + "items": { + "properties": { + "name": { + "maxLength": 40, + "type": "string" + }, + "value": { + "maxLength": 140, + "type": "string" + } }, - { - "enum": [""], - "type": "string" - } - ] + "required": ["name", "value"], + "title": "custom_field_params", + "type": "object" + }, + "type": "array" }, - "explanation": { - "maxLength": 1500, + { + "enum": [""], "type": "string" - }, - "product_description": { - "maxLength": 1500, + } + ] + }, + "description": { + "maxLength": 1500, + "type": "string" + }, + "footer": { + "maxLength": 5000, + "type": "string" + }, + "issuer": { + "properties": { + "account": { "type": "string" }, - "product_type": { - "enum": ["", "merchandise", "service"], + "type": { + "enum": ["account", "self"], "type": "string" } }, - "title": "not_received", + "required": ["type"], + "title": "param", "type": "object" }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "rendering_options": { + "anyOf": [ + { + "properties": { + "amount_tax_display": { + "enum": [ + "", + "exclude_tax", + "include_inclusive_tax" + ], + "type": "string" + } + }, + "title": "rendering_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "invoice_settings_params", + "type": "object" + } + }, + "required": ["enabled"], + "title": "invoice_creation_update_params", + "type": "object" + }, + "line_items": { + "description": "The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.", + "items": { + "properties": { + "adjustable_quantity": { + "properties": { + "enabled": { + "type": "boolean" + }, + "maximum": { + "type": "integer" + }, + "minimum": { + "type": "integer" + } + }, + "required": ["enabled"], + "title": "adjustable_quantity_params", + "type": "object" + }, + "id": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + } + }, + "required": ["id"], + "title": "line_items_update_params", + "type": "object" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.", + "type": "object" + }, + "payment_intent_data": { + "description": "A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.", + "properties": { + "description": { + "anyOf": [ + { + "maxLength": 1000, + "type": "string" + }, { "enum": [""], "type": "string" } ] }, - "other": { + "metadata": { "anyOf": [ { - "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "explanation": { - "maxLength": 1500, - "type": "string" - }, - "product_description": { - "maxLength": 1500, - "type": "string" - }, - "product_type": { - "enum": ["", "merchandise", "service"], - "type": "string" - } + "additionalProperties": { + "type": "string" }, - "title": "other", "type": "object" }, { @@ -59347,68 +108485,448 @@ } ] }, - "reason": { - "enum": [ - "canceled", - "duplicate", - "fraudulent", - "merchandise_not_as_described", - "not_received", - "other", - "service_not_as_described" - ], - "type": "string", - "x-stripeBypassValidation": true + "statement_descriptor": { + "anyOf": [ + { + "maxLength": 22, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "service_not_as_described": { + "statement_descriptor_suffix": { + "anyOf": [ + { + "maxLength": 22, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "transfer_group": { "anyOf": [ { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_intent_data_update_params", + "type": "object" + }, + "payment_method_collection": { + "description": "Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.\n\nCan only be set in `subscription` mode. Defaults to `always`.\n\nIf you'd like information on how to collect a payment method outside of Checkout, read the guide on [configuring subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).", + "enum": ["always", "if_required"], + "type": "string" + }, + "payment_method_types": { + "anyOf": [ + { + "items": { + "enum": [ + "affirm", + "afterpay_clearpay", + "alipay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "cashapp", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The list of payment method types that customers can use. Pass an empty string to enable dynamic payment methods that use your [payment method settings](https://dashboard.stripe.com/settings/payment_methods)." + }, + "restrictions": { + "anyOf": [ + { + "properties": { + "completed_sessions": { "properties": { - "additional_documentation": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "canceled_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "cancellation_reason": { - "maxLength": 1500, + "limit": { + "type": "integer" + } + }, + "required": ["limit"], + "title": "completed_sessions_params", + "type": "object" + } + }, + "required": ["completed_sessions"], + "title": "restrictions_params", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Settings that restrict the usage of a payment link." + }, + "shipping_address_collection": { + "anyOf": [ + { + "properties": { + "allowed_countries": { + "items": { + "enum": [ + "AC", + "AD", + "AE", + "AF", + "AG", + "AI", + "AL", + "AM", + "AO", + "AQ", + "AR", + "AT", + "AU", + "AW", + "AX", + "AZ", + "BA", + "BB", + "BD", + "BE", + "BF", + "BG", + "BH", + "BI", + "BJ", + "BL", + "BM", + "BN", + "BO", + "BQ", + "BR", + "BS", + "BT", + "BV", + "BW", + "BY", + "BZ", + "CA", + "CD", + "CF", + "CG", + "CH", + "CI", + "CK", + "CL", + "CM", + "CN", + "CO", + "CR", + "CV", + "CW", + "CY", + "CZ", + "DE", + "DJ", + "DK", + "DM", + "DO", + "DZ", + "EC", + "EE", + "EG", + "EH", + "ER", + "ES", + "ET", + "FI", + "FJ", + "FK", + "FO", + "FR", + "GA", + "GB", + "GD", + "GE", + "GF", + "GG", + "GH", + "GI", + "GL", + "GM", + "GN", + "GP", + "GQ", + "GR", + "GS", + "GT", + "GU", + "GW", + "GY", + "HK", + "HN", + "HR", + "HT", + "HU", + "ID", + "IE", + "IL", + "IM", + "IN", + "IO", + "IQ", + "IS", + "IT", + "JE", + "JM", + "JO", + "JP", + "KE", + "KG", + "KH", + "KI", + "KM", + "KN", + "KR", + "KW", + "KY", + "KZ", + "LA", + "LB", + "LC", + "LI", + "LK", + "LR", + "LS", + "LT", + "LU", + "LV", + "LY", + "MA", + "MC", + "MD", + "ME", + "MF", + "MG", + "MK", + "ML", + "MM", + "MN", + "MO", + "MQ", + "MR", + "MS", + "MT", + "MU", + "MV", + "MW", + "MX", + "MY", + "MZ", + "NA", + "NC", + "NE", + "NG", + "NI", + "NL", + "NO", + "NP", + "NR", + "NU", + "NZ", + "OM", + "PA", + "PE", + "PF", + "PG", + "PH", + "PK", + "PL", + "PM", + "PN", + "PR", + "PS", + "PT", + "PY", + "QA", + "RE", + "RO", + "RS", + "RU", + "RW", + "SA", + "SB", + "SC", + "SE", + "SG", + "SH", + "SI", + "SJ", + "SK", + "SL", + "SM", + "SN", + "SO", + "SR", + "SS", + "ST", + "SV", + "SX", + "SZ", + "TA", + "TC", + "TD", + "TF", + "TG", + "TH", + "TJ", + "TK", + "TL", + "TM", + "TN", + "TO", + "TR", + "TT", + "TV", + "TW", + "TZ", + "UA", + "UG", + "US", + "UY", + "UZ", + "VA", + "VC", + "VE", + "VG", + "VN", + "VU", + "WF", + "WS", + "XK", + "YE", + "YT", + "ZA", + "ZM", + "ZW", + "ZZ" + ], + "type": "string" + }, + "type": "array" + } + }, + "required": ["allowed_countries"], + "title": "shipping_address_collection_params", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Configuration for collecting the customer's shipping address." + }, + "subscription_data": { + "description": "When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.", + "properties": { + "invoice_settings": { + "properties": { + "issuer": { + "properties": { + "account": { "type": "string" }, - "explanation": { - "maxLength": 1500, + "type": { + "enum": ["account", "self"], "type": "string" - }, - "received_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "subscription_data_invoice_settings_params", + "type": "object" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "trial_settings": { + "anyOf": [ + { + "properties": { + "end_behavior": { + "properties": { + "missing_payment_method": { + "enum": [ + "cancel", + "create_invoice", + "pause" + ], "type": "string" } - ] + }, + "required": ["missing_payment_method"], + "title": "end_behavior", + "type": "object" } }, - "title": "service_not_as_described", + "required": ["end_behavior"], + "title": "trial_settings_config", "type": "object" }, { @@ -59418,116 +108936,19 @@ ] } }, - "title": "evidence_param", + "title": "subscription_data_update_params", "type": "object" }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" + "tax_id_collection": { + "description": "Controls tax ID collection during checkout.", + "properties": { + "enabled": { + "type": "boolean" } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.dispute" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/issuing/disputes/{dispute}/submit": { - "post": { - "description": "

Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute’s reason are present. For more details, see Dispute reasons and evidence.

", - "operationId": "PostIssuingDisputesDisputeSubmit", - "parameters": [ - { - "in": "path", - "name": "dispute", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "required": ["enabled"], + "title": "tax_id_collection_params", + "type": "object" } }, "type": "object" @@ -59541,7 +108962,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/issuing.dispute" + "$ref": "#/components/schemas/payment_link" } } }, @@ -59560,44 +108981,11 @@ } } }, - "/v1/issuing/settlements": { + "/v1/payment_links/{payment_link}/line_items": { "get": { - "description": "

Returns a list of Issuing Settlement objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", - "operationId": "GetIssuingSettlements", + "description": "

When retrieving a payment link, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", + "operationId": "GetPaymentLinksPaymentLinkLineItems", "parameters": [ - { - "description": "Only return issuing settlements that were created during the given date interval.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -59634,6 +109022,16 @@ }, "style": "form" }, + { + "in": "path", + "name": "payment_link", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -59651,6 +109049,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -59666,8 +109065,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/issuing.settlement" + "$ref": "#/components/schemas/item" }, "type": "array" }, @@ -59683,11 +109083,11 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/issuing/settlements", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "PaymentLinksResourceListLineItems", "type": "object", "x-expandableFields": ["data"] } @@ -59708,203 +109108,26 @@ } } }, - "/v1/issuing/settlements/{settlement}": { - "get": { - "description": "

Retrieves an Issuing Settlement object.

", - "operationId": "GetIssuingSettlementsSettlement", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "settlement", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.settlement" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates the specified Issuing Settlement object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostIssuingSettlementsSettlement", - "parameters": [ - { - "in": "path", - "name": "settlement", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.settlement" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/issuing/transactions": { + "/v1/payment_method_configurations": { "get": { - "description": "

Returns a list of Issuing Transaction objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", - "operationId": "GetIssuingTransactions", + "description": "

List payment method configurations

", + "operationId": "GetPaymentMethodConfigurations", "parameters": [ { - "description": "Only return transactions that belong to the given card.", - "in": "query", - "name": "card", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return transactions that belong to the given cardholder.", - "in": "query", - "name": "cardholder", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return transactions that were created during the given date interval.", + "description": "The Connect application to filter by.", "explode": true, "in": "query", - "name": "created", + "name": "application", "required": false, "schema": { "anyOf": [ { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" + "maxLength": 100, + "type": "string" }, { - "type": "integer" + "enum": [""], + "type": "string" } ] }, @@ -59956,17 +109179,6 @@ "type": "string" }, "style": "form" - }, - { - "description": "Only return transactions that have the given type. One of `capture` or `refund`.", - "in": "query", - "name": "type", - "required": false, - "schema": { - "enum": ["capture", "refund"], - "type": "string" - }, - "style": "form" } ], "requestBody": { @@ -59974,6 +109186,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -59990,7 +109203,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/issuing.transaction" + "$ref": "#/components/schemas/payment_method_configuration" }, "type": "array" }, @@ -60006,11 +109219,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/issuing/transactions", + "pattern": "^/v1/payment_method_configurations", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "PaymentMethodConfigResourcePaymentMethodConfigurationsList", "type": "object", "x-expandableFields": ["data"] } @@ -60029,104 +109243,475 @@ "description": "Error response." } } - } - }, - "/v1/issuing/transactions/{transaction}": { - "get": { - "description": "

Retrieves an Issuing Transaction object.

", - "operationId": "GetIssuingTransactionsTransaction", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "transaction", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/issuing.transaction" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } }, "post": { - "description": "

Updates the specified Issuing Transaction object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostIssuingTransactionsTransaction", - "parameters": [ - { - "in": "path", - "name": "transaction", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], + "description": "

Creates a payment method configuration

", + "operationId": "PostPaymentMethodConfigurations", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { + "acss_debit": { + "explode": true, + "style": "deepObject" + }, + "affirm": { + "explode": true, + "style": "deepObject" + }, + "afterpay_clearpay": { + "explode": true, + "style": "deepObject" + }, + "alipay": { + "explode": true, + "style": "deepObject" + }, + "amazon_pay": { + "explode": true, + "style": "deepObject" + }, + "apple_pay": { + "explode": true, + "style": "deepObject" + }, + "apple_pay_later": { + "explode": true, + "style": "deepObject" + }, + "au_becs_debit": { + "explode": true, + "style": "deepObject" + }, + "bacs_debit": { + "explode": true, + "style": "deepObject" + }, + "bancontact": { + "explode": true, + "style": "deepObject" + }, + "blik": { + "explode": true, + "style": "deepObject" + }, + "boleto": { + "explode": true, + "style": "deepObject" + }, + "card": { + "explode": true, + "style": "deepObject" + }, + "cartes_bancaires": { + "explode": true, + "style": "deepObject" + }, + "cashapp": { + "explode": true, + "style": "deepObject" + }, + "customer_balance": { + "explode": true, + "style": "deepObject" + }, + "eps": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" }, - "metadata": { + "fpx": { + "explode": true, + "style": "deepObject" + }, + "giropay": { + "explode": true, + "style": "deepObject" + }, + "google_pay": { + "explode": true, + "style": "deepObject" + }, + "grabpay": { + "explode": true, + "style": "deepObject" + }, + "ideal": { + "explode": true, + "style": "deepObject" + }, + "jcb": { + "explode": true, + "style": "deepObject" + }, + "klarna": { + "explode": true, + "style": "deepObject" + }, + "konbini": { + "explode": true, + "style": "deepObject" + }, + "link": { + "explode": true, + "style": "deepObject" + }, + "mobilepay": { + "explode": true, + "style": "deepObject" + }, + "multibanco": { + "explode": true, + "style": "deepObject" + }, + "oxxo": { + "explode": true, + "style": "deepObject" + }, + "p24": { + "explode": true, + "style": "deepObject" + }, + "paynow": { + "explode": true, + "style": "deepObject" + }, + "paypal": { + "explode": true, + "style": "deepObject" + }, + "promptpay": { + "explode": true, + "style": "deepObject" + }, + "revolut_pay": { + "explode": true, + "style": "deepObject" + }, + "sepa_debit": { + "explode": true, + "style": "deepObject" + }, + "sofort": { + "explode": true, + "style": "deepObject" + }, + "swish": { + "explode": true, + "style": "deepObject" + }, + "twint": { + "explode": true, + "style": "deepObject" + }, + "us_bank_account": { + "explode": true, + "style": "deepObject" + }, + "wechat_pay": { + "explode": true, + "style": "deepObject" + }, + "zip": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { + "acss_debit": { + "description": "Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "affirm": { + "description": "[Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "afterpay_clearpay": { + "description": "Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "alipay": { + "description": "Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "amazon_pay": { + "description": "Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "apple_pay": { + "description": "Stripe users can accept [Apple Pay](/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "apple_pay_later": { + "description": "Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "au_becs_debit": { + "description": "Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "bacs_debit": { + "description": "Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "bancontact": { + "description": "Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "blik": { + "description": "BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "boleto": { + "description": "Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "card": { + "description": "Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "cartes_bancaires": { + "description": "Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "cashapp": { + "description": "Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "customer_balance": { + "description": "Uses a customer’s [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "eps": { + "description": "EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -60135,20 +109720,423 @@ }, "type": "array" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" + "fpx": { + "description": "Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "giropay": { + "description": "giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "google_pay": { + "description": "Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "grabpay": { + "description": "GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "ideal": { + "description": "iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "jcb": { + "description": "JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "klarna": { + "description": "Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "konbini": { + "description": "Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "link": { + "description": "[Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "mobilepay": { + "description": "MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "multibanco": { + "description": "Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "name": { + "description": "Configuration name.", + "maxLength": 100, + "type": "string" + }, + "oxxo": { + "description": "OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "p24": { + "description": "Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "parent": { + "description": "Configuration's parent configuration. Specify to create a child configuration.", + "maxLength": 100, + "type": "string" + }, + "paynow": { + "description": "PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "paypal": { + "description": "PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "promptpay": { + "description": "PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "revolut_pay": { + "description": "Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer’s stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "sepa_debit": { + "description": "The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "sofort": { + "description": "Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "swish": { + "description": "Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "twint": { + "description": "Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "us_bank_account": { + "description": "Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-debit) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "wechat_pay": { + "description": "WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "zip": { + "description": "Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } }, + "title": "display_preference_param", "type": "object" - }, - { - "enum": [""], - "type": "string" } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "title": "payment_method_param", + "type": "object" } }, "type": "object" @@ -60162,7 +110150,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/issuing.transaction" + "$ref": "#/components/schemas/payment_method_configuration" } } }, @@ -60181,11 +110169,21 @@ } } }, - "/v1/mandates/{mandate}": { + "/v1/payment_method_configurations/{configuration}": { "get": { - "description": "

Retrieves a Mandate object.

", - "operationId": "GetMandatesMandate", + "description": "

Retrieve payment method configuration

", + "operationId": "GetPaymentMethodConfigurationsConfiguration", "parameters": [ + { + "in": "path", + "name": "configuration", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -60200,15 +110198,6 @@ "type": "array" }, "style": "deepObject" - }, - { - "in": "path", - "name": "mandate", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" } ], "requestBody": { @@ -60216,6 +110205,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -60228,7 +110218,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/mandate" + "$ref": "#/components/schemas/payment_method_configuration" } } }, @@ -60245,204 +110235,913 @@ "description": "Error response." } } - } - }, - "/v1/order_returns": { - "get": { - "description": "

Returns a list of your order returns. The returns are returned sorted by creation date, with the most recently created return appearing first.

", - "operationId": "GetOrderReturns", + }, + "post": { + "description": "

Update payment method configuration

", + "operationId": "PostPaymentMethodConfigurationsConfiguration", "parameters": [ { - "description": "Date this return was created.", - "explode": true, - "in": "query", - "name": "created", - "required": false, + "in": "path", + "name": "configuration", + "required": true, "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "acss_debit": { + "explode": true, + "style": "deepObject" + }, + "affirm": { + "explode": true, + "style": "deepObject" + }, + "afterpay_clearpay": { + "explode": true, + "style": "deepObject" + }, + "alipay": { + "explode": true, + "style": "deepObject" + }, + "amazon_pay": { + "explode": true, + "style": "deepObject" + }, + "apple_pay": { + "explode": true, + "style": "deepObject" + }, + "apple_pay_later": { + "explode": true, + "style": "deepObject" + }, + "au_becs_debit": { + "explode": true, + "style": "deepObject" + }, + "bacs_debit": { + "explode": true, + "style": "deepObject" + }, + "bancontact": { + "explode": true, + "style": "deepObject" + }, + "blik": { + "explode": true, + "style": "deepObject" + }, + "boleto": { + "explode": true, + "style": "deepObject" + }, + "card": { + "explode": true, + "style": "deepObject" + }, + "cartes_bancaires": { + "explode": true, + "style": "deepObject" + }, + "cashapp": { + "explode": true, + "style": "deepObject" + }, + "customer_balance": { + "explode": true, + "style": "deepObject" + }, + "eps": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "fpx": { + "explode": true, + "style": "deepObject" + }, + "giropay": { + "explode": true, + "style": "deepObject" + }, + "google_pay": { + "explode": true, + "style": "deepObject" + }, + "grabpay": { + "explode": true, + "style": "deepObject" + }, + "ideal": { + "explode": true, + "style": "deepObject" + }, + "jcb": { + "explode": true, + "style": "deepObject" + }, + "klarna": { + "explode": true, + "style": "deepObject" + }, + "konbini": { + "explode": true, + "style": "deepObject" + }, + "link": { + "explode": true, + "style": "deepObject" + }, + "mobilepay": { + "explode": true, + "style": "deepObject" + }, + "multibanco": { + "explode": true, + "style": "deepObject" + }, + "oxxo": { + "explode": true, + "style": "deepObject" + }, + "p24": { + "explode": true, + "style": "deepObject" + }, + "paynow": { + "explode": true, + "style": "deepObject" + }, + "paypal": { + "explode": true, + "style": "deepObject" + }, + "promptpay": { + "explode": true, + "style": "deepObject" + }, + "revolut_pay": { + "explode": true, + "style": "deepObject" + }, + "sepa_debit": { + "explode": true, + "style": "deepObject" + }, + "sofort": { + "explode": true, + "style": "deepObject" + }, + "swish": { + "explode": true, + "style": "deepObject" + }, + "twint": { + "explode": true, + "style": "deepObject" + }, + "us_bank_account": { + "explode": true, + "style": "deepObject" + }, + "wechat_pay": { + "explode": true, + "style": "deepObject" + }, + "zip": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "acss_debit": { + "description": "Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "active": { + "description": "Whether the configuration can be used for new payments.", + "type": "boolean" + }, + "affirm": { + "description": "[Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "afterpay_clearpay": { + "description": "Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "alipay": { + "description": "Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "amazon_pay": { + "description": "Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "apple_pay": { + "description": "Stripe users can accept [Apple Pay](/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "apple_pay_later": { + "description": "Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "au_becs_debit": { + "description": "Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "bacs_debit": { + "description": "Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "bancontact": { + "description": "Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "blik": { + "description": "BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "boleto": { + "description": "Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "card": { + "description": "Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "cartes_bancaires": { + "description": "Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "cashapp": { + "description": "Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "customer_balance": { + "description": "Uses a customer’s [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "eps": { + "description": "EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "fpx": { + "description": "Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "giropay": { + "description": "giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "google_pay": { + "description": "Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "grabpay": { + "description": "GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "ideal": { + "description": "iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "jcb": { + "description": "JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "klarna": { + "description": "Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "konbini": { + "description": "Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "link": { + "description": "[Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "mobilepay": { + "description": "MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "multibanco": { + "description": "Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "name": { + "description": "Configuration name.", + "maxLength": 100, + "type": "string" + }, + "oxxo": { + "description": "OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } }, - "gte": { - "type": "integer" + "title": "payment_method_param", + "type": "object" + }, + "p24": { + "description": "Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } }, - "lt": { - "type": "integer" + "title": "payment_method_param", + "type": "object" + }, + "paynow": { + "description": "PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } }, - "lte": { - "type": "integer" - } + "title": "payment_method_param", + "type": "object" }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "The order to retrieve returns for.", - "in": "query", - "name": "order", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/order_return" - }, - "type": "array" + "paypal": { + "description": "PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" + "title": "payment_method_param", + "type": "object" + }, + "promptpay": { + "description": "PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" + "title": "payment_method_param", + "type": "object" + }, + "revolut_pay": { + "description": "Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer’s stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/order_returns", - "type": "string" - } + "title": "payment_method_param", + "type": "object" }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/order_returns/{id}": { - "get": { - "description": "

Retrieves the details of an existing order return. Supply the unique order ID from either an order return creation request or the order return list, and Stripe will return the corresponding order information.

", - "operationId": "GetOrderReturnsId", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, + "sepa_debit": { + "description": "The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "sofort": { + "description": "Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "swish": { + "description": "Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "twint": { + "description": "Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "us_bank_account": { + "description": "Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-debit) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "wechat_pay": { + "description": "WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "zip": { + "description": "Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.", + "properties": { + "display_preference": { + "properties": { + "preference": { + "enum": ["none", "off", "on"], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + } + }, "type": "object" } } @@ -60454,7 +111153,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/order_return" + "$ref": "#/components/schemas/payment_method_configuration" } } }, @@ -60473,247 +111172,48 @@ } } }, - "/v1/orders": { + "/v1/payment_method_domains": { "get": { - "description": "

Returns a list of your orders. The orders are returned sorted by creation date, with the most recently created orders appearing first.

", - "operationId": "GetOrders", + "description": "

Lists the details of existing payment method domains.

", + "operationId": "GetPaymentMethodDomains", "parameters": [ { - "description": "Date this order was created.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return orders for the given customer.", - "in": "query", - "name": "customer", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "Only return orders with the given IDs.", - "explode": true, - "in": "query", - "name": "ids", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return orders that have the given status. One of `created`, `paid`, `fulfilled`, or `refunded`.", - "in": "query", - "name": "status", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Filter orders based on when they were paid, fulfilled, canceled, or returned.", - "explode": true, + "description": "The domain name that this payment method domain object represents.", "in": "query", - "name": "status_transitions", - "required": false, - "schema": { - "properties": { - "canceled": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "fulfilled": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "paid": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "returned": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - } - }, - "title": "order_timestamp_specs", - "type": "object" + "name": "domain_name", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "form" + }, + { + "description": "Whether this payment method domain is enabled. If the domain is not enabled, payment methods will not appear in Elements", + "in": "query", + "name": "enabled", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" }, { - "description": "Only return orders with the given upstream order IDs.", + "description": "Specifies which fields in the response should be expanded.", "explode": true, "in": "query", - "name": "upstream_ids", + "name": "expand", "required": false, "schema": { "items": { @@ -60723,6 +111223,27 @@ "type": "array" }, "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" } ], "requestBody": { @@ -60730,6 +111251,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -60746,7 +111268,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/order" + "$ref": "#/components/schemas/payment_method_domain" }, "type": "array" }, @@ -60762,11 +111284,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/orders", + "pattern": "^/v1/payment_method_domains", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "PaymentMethodDomainResourcePaymentMethodDomainList", "type": "object", "x-expandableFields": ["data"] } @@ -60787,8 +111310,8 @@ } }, "post": { - "description": "

Creates a new order object.

", - "operationId": "PostOrders", + "description": "

Creates a payment method domain.

", + "operationId": "PostPaymentMethodDomains", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -60796,40 +111319,19 @@ "expand": { "explode": true, "style": "deepObject" - }, - "items": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "shipping": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "coupon": { - "description": "A coupon code that represents a discount to be applied to this order. Must be one-time duration and in same currency as the order. An order can have multiple coupons.", - "maxLength": 5000, - "type": "string" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "customer": { - "description": "The ID of an existing customer to use for this order. If provided, the customer email and shipping address will be used to create the order. Subsequently, the customer will also be charged to pay the order. If `email` or `shipping` are also provided, they will override the values retrieved from the customer object.", + "domain_name": { + "description": "The domain name that this payment method domain object represents.", "maxLength": 5000, "type": "string" }, - "email": { - "description": "The email address of the customer placing the order.", - "maxLength": 5000, - "type": "string" + "enabled": { + "description": "Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements.", + "type": "boolean" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -60838,95 +111340,9 @@ "type": "string" }, "type": "array" - }, - "items": { - "description": "List of items constituting the order. An order can have up to 25 items.", - "items": { - "properties": { - "amount": { - "type": "integer" - }, - "currency": { - "type": "string" - }, - "description": { - "maxLength": 1000, - "type": "string" - }, - "parent": { - "maxLength": 5000, - "type": "string" - }, - "quantity": { - "type": "integer" - }, - "type": { - "enum": ["discount", "shipping", "sku", "tax"], - "maxLength": 5000, - "type": "string" - } - }, - "title": "order_item_specs", - "type": "object" - }, - "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "shipping": { - "description": "Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.", - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["line1"], - "title": "address", - "type": "object" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["address", "name"], - "title": "customer_shipping", - "type": "object" } }, - "required": ["currency"], + "required": ["domain_name"], "type": "object" } } @@ -60938,7 +111354,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/order" + "$ref": "#/components/schemas/payment_method_domain" } } }, @@ -60957,10 +111373,10 @@ } } }, - "/v1/orders/{id}": { + "/v1/payment_method_domains/{payment_method_domain}": { "get": { - "description": "

Retrieves the details of an existing order. Supply the unique order ID from either an order creation request or the order list, and Stripe will return the corresponding order information.

", - "operationId": "GetOrdersId", + "description": "

Retrieves the details of an existing payment method domain.

", + "operationId": "GetPaymentMethodDomainsPaymentMethodDomain", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -60979,7 +111395,7 @@ }, { "in": "path", - "name": "id", + "name": "payment_method_domain", "required": true, "schema": { "maxLength": 5000, @@ -60993,6 +111409,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -61005,7 +111422,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/order" + "$ref": "#/components/schemas/payment_method_domain" } } }, @@ -61024,139 +111441,12 @@ } }, "post": { - "description": "

Updates the specific order by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostOrdersId", - "parameters": [ - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "shipping": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "coupon": { - "description": "A coupon code that represents a discount to be applied to this order. Must be one-time duration and in same currency as the order. An order can have multiple coupons.", - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "selected_shipping_method": { - "description": "The shipping method to select for fulfilling this order. If specified, must be one of the `id`s of a shipping method in the `shipping_methods` array. If specified, will overwrite the existing selected shipping method, updating `items` as necessary.", - "maxLength": 5000, - "type": "string" - }, - "shipping": { - "description": "Tracking information once the order has been fulfilled.", - "properties": { - "carrier": { - "maxLength": 5000, - "type": "string" - }, - "tracking_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["carrier", "tracking_number"], - "title": "shipping_tracking_params", - "type": "object" - }, - "status": { - "description": "Current order status. One of `created`, `paid`, `canceled`, `fulfilled`, or `returned`. More detail in the [Orders Guide](https://stripe.com/docs/orders/guide#understanding-order-statuses).", - "enum": [ - "canceled", - "created", - "fulfilled", - "paid", - "returned" - ], - "maxLength": 5000, - "type": "string" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/order" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/orders/{id}/pay": { - "post": { - "description": "

Pay an order by providing a source to create a payment.

", - "operationId": "PostOrdersIdPay", + "description": "

Updates an existing payment method domain.

", + "operationId": "PostPaymentMethodDomainsPaymentMethodDomain", "parameters": [ { "in": "path", - "name": "id", + "name": "payment_method_domain", "required": true, "schema": { "maxLength": 5000, @@ -61172,27 +111462,14 @@ "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "application_fee": { - "description": "A fee in %s that will be applied to the order and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the `Stripe-Account` header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/connect/direct-charges#collecting-fees).", - "type": "integer" - }, - "customer": { - "description": "The ID of an existing customer that will be charged for this order. If no customer was attached to the order at creation, either `source` or `customer` is required. Otherwise, the specified customer will be charged instead of the one attached to the order.", - "maxLength": 5000, - "type": "string" - }, - "email": { - "description": "The email address of the customer placing the order. Required if not previously specified for the order.", - "maxLength": 5000, - "type": "string" + "enabled": { + "description": "Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements.", + "type": "boolean" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -61201,19 +111478,6 @@ "type": "string" }, "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "source": { - "description": "A [Token](https://stripe.com/docs/api#tokens)'s or a [Source](https://stripe.com/docs/api#sources)'s ID, as returned by [Elements](https://stripe.com/docs/elements). If no customer was attached to the order at creation, either `source` or `customer` is required. Otherwise, the specified source will be charged intead of the customer attached to the order.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true } }, "type": "object" @@ -61227,7 +111491,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/order" + "$ref": "#/components/schemas/payment_method_domain" } } }, @@ -61246,14 +111510,14 @@ } } }, - "/v1/orders/{id}/returns": { + "/v1/payment_method_domains/{payment_method_domain}/validate": { "post": { - "description": "

Return all or part of an order. The order must have a status of paid or fulfilled before it can be returned. Once all items have been returned, the order will become canceled or returned depending on which status the order started in.

", - "operationId": "PostOrdersIdReturns", + "description": "

Some payment methods such as Apple Pay require additional steps to verify a domain. If the requirements weren’t satisfied when the domain was created, the payment method will be inactive on the domain.\nThe payment method doesn’t appear in Elements for this domain until it is active.

\n\n

To activate a payment method on an existing payment method domain, complete the required validation steps specific to the payment method, and then validate the payment method domain with this endpoint.

\n\n

Related guides: Payment method domains.

", + "operationId": "PostPaymentMethodDomainsPaymentMethodDomainValidate", "parameters": [ { "in": "path", - "name": "id", + "name": "payment_method_domain", "required": true, "schema": { "maxLength": 5000, @@ -61269,13 +111533,10 @@ "expand": { "explode": true, "style": "deepObject" - }, - "items": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -61284,43 +111545,6 @@ "type": "string" }, "type": "array" - }, - "items": { - "anyOf": [ - { - "items": { - "properties": { - "amount": { - "type": "integer" - }, - "description": { - "maxLength": 1000, - "type": "string" - }, - "parent": { - "maxLength": 5000, - "type": "string" - }, - "quantity": { - "type": "integer" - }, - "type": { - "enum": ["discount", "shipping", "sku", "tax"], - "maxLength": 5000, - "type": "string" - } - }, - "title": "return_order_item_specs", - "type": "object" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "List of items to return." } }, "type": "object" @@ -61334,7 +111558,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/order_return" + "$ref": "#/components/schemas/payment_method_domain" } } }, @@ -61353,46 +111577,13 @@ } } }, - "/v1/payment_intents": { + "/v1/payment_methods": { "get": { - "description": "

Returns a list of PaymentIntents.

", - "operationId": "GetPaymentIntents", + "description": "

Returns a list of PaymentMethods for Treasury flows. If you want to list the PaymentMethods attached to a Customer for payments, you should use the List a Customer’s PaymentMethods API instead.

", + "operationId": "GetPaymentMethods", "parameters": [ { - "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return PaymentIntents for the customer specified by this customer ID.", + "description": "The ID of the customer whose PaymentMethods will be retrieved.", "in": "query", "name": "customer", "required": false, @@ -61408,7 +111599,6 @@ "name": "ending_before", "required": false, "schema": { - "maxLength": 5000, "type": "string" }, "style": "form" @@ -61444,10 +111634,59 @@ "name": "starting_after", "required": false, "schema": { - "maxLength": 5000, "type": "string" }, "style": "form" + }, + { + "description": "An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.", + "in": "query", + "name": "type", + "required": false, + "schema": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "style": "form" } ], "requestBody": { @@ -61455,6 +111694,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -61471,7 +111711,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/payment_intent" + "$ref": "#/components/schemas/payment_method" }, "type": "array" }, @@ -61487,12 +111727,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/payment_intents", + "pattern": "^/v1/payment_methods", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "PaymentFlowsPaymentIntentList", + "title": "PaymentFlowsPaymentMethodList", "type": "object", "x-expandableFields": ["data"] } @@ -61513,591 +111753,307 @@ } }, "post": { - "description": "

Creates a PaymentIntent object.

\n\n

After the PaymentIntent is created, attach a payment method and confirm\nto continue the payment. You can read more about the different payment flows\navailable via the Payment Intents API here.

\n\n

When confirm=true is used during creation, it is equivalent to creating\nand confirming the PaymentIntent in the same call. You may use any parameters\navailable in the confirm API when confirm=true\nis supplied.

", - "operationId": "PostPaymentIntents", + "description": "

Creates a PaymentMethod object. Read the Stripe.js reference to learn how to create PaymentMethods via Stripe.js.

\n\n

Instead of creating a PaymentMethod directly, we recommend using the PaymentIntents API to accept a payment immediately or the SetupIntent API to collect payment method details ahead of a future payment.

", + "operationId": "PostPaymentMethods", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { + "acss_debit": { + "explode": true, + "style": "deepObject" + }, + "affirm": { + "explode": true, + "style": "deepObject" + }, + "afterpay_clearpay": { + "explode": true, + "style": "deepObject" + }, + "alipay": { + "explode": true, + "style": "deepObject" + }, + "amazon_pay": { + "explode": true, + "style": "deepObject" + }, + "au_becs_debit": { + "explode": true, + "style": "deepObject" + }, + "bacs_debit": { + "explode": true, + "style": "deepObject" + }, + "bancontact": { + "explode": true, + "style": "deepObject" + }, + "billing_details": { + "explode": true, + "style": "deepObject" + }, + "blik": { + "explode": true, + "style": "deepObject" + }, + "boleto": { + "explode": true, + "style": "deepObject" + }, + "card": { + "explode": true, + "style": "deepObject" + }, + "cashapp": { + "explode": true, + "style": "deepObject" + }, + "customer_balance": { + "explode": true, + "style": "deepObject" + }, + "eps": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" }, - "mandate_data": { + "fpx": { + "explode": true, + "style": "deepObject" + }, + "giropay": { + "explode": true, + "style": "deepObject" + }, + "grabpay": { + "explode": true, + "style": "deepObject" + }, + "ideal": { + "explode": true, + "style": "deepObject" + }, + "interac_present": { + "explode": true, + "style": "deepObject" + }, + "klarna": { + "explode": true, + "style": "deepObject" + }, + "konbini": { + "explode": true, + "style": "deepObject" + }, + "link": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "mobilepay": { + "explode": true, + "style": "deepObject" + }, + "multibanco": { + "explode": true, + "style": "deepObject" + }, + "oxxo": { + "explode": true, + "style": "deepObject" + }, + "p24": { + "explode": true, + "style": "deepObject" + }, + "paynow": { + "explode": true, + "style": "deepObject" + }, + "paypal": { "explode": true, "style": "deepObject" }, - "metadata": { + "pix": { "explode": true, "style": "deepObject" }, - "off_session": { + "promptpay": { "explode": true, "style": "deepObject" }, - "payment_method_data": { + "radar_options": { "explode": true, "style": "deepObject" }, - "payment_method_options": { + "revolut_pay": { "explode": true, "style": "deepObject" }, - "payment_method_types": { + "sepa_debit": { "explode": true, "style": "deepObject" }, - "shipping": { + "sofort": { "explode": true, "style": "deepObject" }, - "transfer_data": { + "swish": { + "explode": true, + "style": "deepObject" + }, + "twint": { + "explode": true, + "style": "deepObject" + }, + "us_bank_account": { + "explode": true, + "style": "deepObject" + }, + "wechat_pay": { + "explode": true, + "style": "deepObject" + }, + "zip": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "amount": { - "description": "Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", - "type": "integer" - }, - "application_fee_amount": { - "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", - "type": "integer" - }, - "capture_method": { - "description": "Controls when the funds will be captured from the customer's account.", - "enum": ["automatic", "manual"], - "type": "string" - }, - "confirm": { - "description": "Set to `true` to attempt to [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, parameters available in the [confirm](https://stripe.com/docs/api/payment_intents/confirm) API may also be provided.", - "type": "boolean" - }, - "confirmation_method": { - "enum": ["automatic", "manual"], - "type": "string" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "customer": { - "description": "ID of the Customer this PaymentIntent belongs to, if one exists.\n\nPayment methods attached to other Customers cannot be used with this PaymentIntent.\n\nIf present in combination with [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage), this PaymentIntent's payment method will be attached to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete.", - "maxLength": 5000, - "type": "string" + "acss_debit": { + "description": "If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.", + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "institution_number": { + "maxLength": 5000, + "type": "string" + }, + "transit_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "account_number", + "institution_number", + "transit_number" + ], + "title": "payment_method_param", + "type": "object" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 1000, - "type": "string" + "affirm": { + "description": "If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.", + "properties": {}, + "title": "param", + "type": "object" }, - "error_on_requires_action": { - "description": "Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. This parameter is intended for simpler integrations that do not handle customer actions, like [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).", - "type": "boolean" + "afterpay_clearpay": { + "description": "If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.", + "properties": {}, + "title": "param", + "type": "object" }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "alipay": { + "description": "If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.", + "properties": {}, + "title": "param", + "type": "object" }, - "mandate": { - "description": "ID of the mandate to be used for this payment. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).", - "maxLength": 5000, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": ["always", "limited", "unspecified"], "type": "string" }, - "mandate_data": { - "description": "This hash contains details about the Mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).", - "properties": { - "customer_acceptance": { - "properties": { - "accepted_at": { - "format": "unix-time", - "type": "integer" - }, - "offline": { - "properties": {}, - "title": "offline_param", - "type": "object" - }, - "online": { - "properties": { - "ip_address": { - "type": "string" - }, - "user_agent": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["ip_address", "user_agent"], - "title": "online_param", - "type": "object" - }, - "type": { - "enum": ["offline", "online"], - "maxLength": 5000, - "type": "string" - } - }, - "required": ["type"], - "title": "customer_acceptance_param", - "type": "object" - } - }, - "required": ["customer_acceptance"], - "title": "secret_key_param", - "type": "object" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "amazon_pay": { + "description": "If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.", + "properties": {}, + "title": "param", "type": "object" }, - "off_session": { - "anyOf": [ - { - "type": "boolean" + "au_becs_debit": { + "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" }, - { - "enum": ["one_off", "recurring"], + "bsb_number": { "maxLength": 5000, "type": "string" } - ], - "description": "Set to `true` to indicate that the customer is not in your checkout flow during this payment attempt, and therefore is unable to authenticate. This parameter is intended for scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm)." - }, - "on_behalf_of": { - "description": "The Stripe account ID for which these funds are intended. For details, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", - "type": "string" - }, - "payment_method": { - "description": "ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.\n\nIf this parameter is omitted with `confirm=true`, `customer.default_source` will be attached as this PaymentIntent's payment instrument to improve the migration experience for users of the Charges API. We recommend that you explicitly provide the `payment_method` going forward.", - "maxLength": 5000, - "type": "string" + }, + "required": ["account_number", "bsb_number"], + "title": "param", + "type": "object" }, - "payment_method_data": { - "description": "If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear\nin the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)\nproperty on the PaymentIntent.", + "bacs_debit": { + "description": "If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.", "properties": { - "afterpay_clearpay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "alipay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "au_becs_debit": { - "properties": { - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "bsb_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "bsb_number"], - "title": "param", - "type": "object" - }, - "bacs_debit": { - "properties": { - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "sort_code": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "bancontact": { - "properties": {}, - "title": "param", - "type": "object" - }, - "billing_details": { - "properties": { - "address": { - "anyOf": [ - { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "billing_details_address", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "billing_details_inner_params", - "type": "object" - }, - "eps": { - "properties": { - "bank": { - "enum": [ - "arzte_und_apotheker_bank", - "austrian_anadi_bank_ag", - "bank_austria", - "bankhaus_carl_spangler", - "bankhaus_schelhammer_und_schattera_ag", - "bawag_psk_ag", - "bks_bank_ag", - "brull_kallmus_bank_ag", - "btv_vier_lander_bank", - "capital_bank_grawe_gruppe_ag", - "dolomitenbank", - "easybank_ag", - "erste_bank_und_sparkassen", - "hypo_alpeadriabank_international_ag", - "hypo_bank_burgenland_aktiengesellschaft", - "hypo_noe_lb_fur_niederosterreich_u_wien", - "hypo_oberosterreich_salzburg_steiermark", - "hypo_tirol_bank_ag", - "hypo_vorarlberg_bank_ag", - "marchfelder_bank", - "oberbank_ag", - "raiffeisen_bankengruppe_osterreich", - "schoellerbank_ag", - "sparda_bank_wien", - "volksbank_gruppe", - "volkskreditbank_ag", - "vr_bank_braunau" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "fpx": { - "properties": { - "bank": { - "enum": [ - "affin_bank", - "alliance_bank", - "ambank", - "bank_islam", - "bank_muamalat", - "bank_rakyat", - "bsn", - "cimb", - "deutsche_bank", - "hong_leong_bank", - "hsbc", - "kfh", - "maybank2e", - "maybank2u", - "ocbc", - "pb_enterprise", - "public_bank", - "rhb", - "standard_chartered", - "uob" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - } - }, - "required": ["bank"], - "title": "param", - "type": "object" - }, - "giropay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "grabpay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "ideal": { - "properties": { - "bank": { - "enum": [ - "abn_amro", - "asn_bank", - "bunq", - "handelsbanken", - "ing", - "knab", - "moneyou", - "rabobank", - "regiobank", - "revolut", - "sns_bank", - "triodos_bank", - "van_lanschot" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "interac_present": { - "properties": {}, - "title": "param", - "type": "object" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "oxxo": { - "properties": {}, - "title": "param", - "type": "object" - }, - "p24": { - "properties": { - "bank": { - "enum": [ - "alior_bank", - "bank_millennium", - "bank_nowy_bfg_sa", - "bank_pekao_sa", - "banki_spbdzielcze", - "blik", - "bnp_paribas", - "boz", - "citi_handlowy", - "credit_agricole", - "envelobank", - "etransfer_pocztowy24", - "getin_bank", - "ideabank", - "ing", - "inteligo", - "mbank_mtransfer", - "nest_przelew", - "noble_pay", - "pbac_z_ipko", - "plus_bank", - "santander_przelew24", - "tmobile_usbugi_bankowe", - "toyota_bank", - "volkswagen_bank" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "sepa_debit": { - "properties": { - "iban": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["iban"], - "title": "param", - "type": "object" - }, - "sofort": { - "properties": { - "country": { - "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], - "type": "string" - } - }, - "required": ["country"], - "title": "param", - "type": "object" + "account_number": { + "maxLength": 5000, + "type": "string" }, - "type": { - "enum": [ - "afterpay_clearpay", - "alipay", - "au_becs_debit", - "bacs_debit", - "bancontact", - "eps", - "fpx", - "giropay", - "grabpay", - "ideal", - "oxxo", - "p24", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true + "sort_code": { + "maxLength": 5000, + "type": "string" } }, - "required": ["type"], - "title": "payment_method_data_params", + "title": "param", "type": "object" }, - "payment_method_options": { - "description": "Payment-method-specific configuration for this PaymentIntent.", + "bancontact": { + "description": "If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "billing_details": { + "description": "Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.", "properties": { - "alipay": { - "anyOf": [ - { - "properties": {}, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "bancontact": { + "address": { "anyOf": [ { "properties": { - "preferred_language": { - "enum": ["de", "en", "fr", "nl"], + "city": { + "maxLength": 5000, "type": "string" - } - }, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "card": { - "anyOf": [ - { - "properties": { - "cvc_token": { + }, + "country": { "maxLength": 5000, "type": "string" }, - "installments": { - "properties": { - "enabled": { - "type": "boolean" - }, - "plan": { - "anyOf": [ - { - "properties": { - "count": { - "type": "integer" - }, - "interval": { - "enum": ["month"], - "type": "string" - }, - "type": { - "enum": ["fixed_count"], - "type": "string" - } - }, - "required": [ - "count", - "interval", - "type" - ], - "title": "installment_plan", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "installments_param", - "type": "object" + "line1": { + "maxLength": 5000, + "type": "string" }, - "network": { - "enum": [ - "amex", - "cartes_bancaires", - "diners", - "discover", - "interac", - "jcb", - "mastercard", - "unionpay", - "unknown", - "visa" - ], + "line2": { "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" }, - "request_three_d_secure": { - "enum": ["any", "automatic"], + "postal_code": { "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" } }, - "title": "payment_intent_param", + "title": "billing_details_address", "type": "object" }, { @@ -62106,16 +112062,10 @@ } ] }, - "oxxo": { + "email": { "anyOf": [ { - "properties": { - "expires_after_days": { - "type": "integer" - } - }, - "title": "payment_method_options_param", - "type": "object" + "type": "string" }, { "enum": [""], @@ -62123,16 +112073,11 @@ } ] }, - "p24": { + "name": { "anyOf": [ { - "properties": { - "tos_shown_and_accepted": { - "type": "boolean" - } - }, - "title": "payment_method_options_param", - "type": "object" + "maxLength": 5000, + "type": "string" }, { "enum": [""], @@ -62140,177 +112085,519 @@ } ] }, - "sepa_debit": { + "phone": { "anyOf": [ { - "properties": { - "mandate_options": { - "properties": {}, - "title": "payment_method_options_mandate_options_param", - "type": "object" - } - }, - "title": "payment_intent_payment_method_options_param", - "type": "object" + "maxLength": 5000, + "type": "string" }, { "enum": [""], "type": "string" } ] - }, - "sofort": { - "anyOf": [ - { + } + }, + "title": "billing_details_inner_params", + "type": "object" + }, + "blik": { + "description": "If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "boleto": { + "description": "If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.", + "properties": { + "tax_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "param", + "type": "object" + }, + "card": { + "anyOf": [ + { + "properties": { + "cvc": { + "maxLength": 5000, + "type": "string" + }, + "exp_month": { + "type": "integer" + }, + "exp_year": { + "type": "integer" + }, + "networks": { "properties": { - "preferred_language": { + "preferred": { "enum": [ - "de", - "en", - "es", - "fr", - "it", - "nl", - "pl" + "cartes_bancaires", + "mastercard", + "visa" ], "type": "string" } }, - "title": "payment_method_options_param", + "title": "networks_params", "type": "object" }, - { - "enum": [""], + "number": { + "maxLength": 5000, "type": "string" } - ] + }, + "required": ["exp_month", "exp_year", "number"], + "title": "card_details_params", + "type": "object" + }, + { + "properties": { + "token": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["token"], + "title": "token_params", + "type": "object" + } + ], + "description": "If this is a `card` PaymentMethod, this hash contains the user's card details. For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format `card: {token: \"tok_visa\"}`. When providing a card number, you must meet the requirements for [PCI compliance](https://stripe.com/docs/security#validating-pci-compliance). We strongly recommend using Stripe.js instead of interacting with this API directly.", + "x-stripeBypassValidation": true + }, + "cashapp": { + "description": "If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "customer": { + "description": "The `Customer` to whom the original PaymentMethod is attached.", + "maxLength": 5000, + "type": "string" + }, + "customer_balance": { + "description": "If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "eps": { + "description": "If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.", + "properties": { + "bank": { + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "maxLength": 5000, + "type": "string" } }, - "title": "payment_method_options_param", + "title": "param", "type": "object" }, - "payment_method_types": { - "description": "The list of payment method types (e.g. card) that this PaymentIntent is allowed to use. If this is not provided, defaults to [\"card\"].", + "expand": { + "description": "Specifies which fields in the response should be expanded.", "items": { "maxLength": 5000, "type": "string" }, "type": "array" }, - "receipt_email": { - "description": "Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).", - "type": "string" + "fpx": { + "description": "If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.", + "properties": { + "bank": { + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["bank"], + "title": "param", + "type": "object" }, - "return_url": { - "description": "The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).", - "type": "string" + "giropay": { + "description": "If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.", + "properties": {}, + "title": "param", + "type": "object" }, - "setup_future_usage": { - "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", - "enum": ["off_session", "on_session"], - "type": "string" + "grabpay": { + "description": "If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.", + "properties": {}, + "title": "param", + "type": "object" }, - "shipping": { - "description": "Shipping information for this PaymentIntent.", + "ideal": { + "description": "If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.", "properties": { - "address": { + "bank": { + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "interac_present": { + "description": "If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "klarna": { + "description": "If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.", + "properties": { + "dob": { "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" + "day": { + "type": "integer" }, - "postal_code": { - "maxLength": 5000, - "type": "string" + "month": { + "type": "integer" }, - "state": { - "maxLength": 5000, - "type": "string" + "year": { + "type": "integer" } }, - "required": ["line1"], - "title": "address", + "required": ["day", "month", "year"], + "title": "date_of_birth", "type": "object" - }, - "carrier": { - "maxLength": 5000, - "type": "string" - }, - "name": { + } + }, + "title": "param", + "type": "object" + }, + "konbini": { + "description": "If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "link": { + "description": "If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "mobilepay": { + "description": "If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "multibanco": { + "description": "If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "oxxo": { + "description": "If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "p24": { + "description": "If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.", + "properties": { + "bank": { + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "param", + "type": "object" + }, + "payment_method": { + "description": "The PaymentMethod to share.", + "maxLength": 5000, + "type": "string" + }, + "paynow": { + "description": "If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "paypal": { + "description": "If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "pix": { + "description": "If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "promptpay": { + "description": "If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "radar_options": { + "description": "Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.", + "properties": { + "session": { "maxLength": 5000, "type": "string" - }, - "phone": { + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "revolut_pay": { + "description": "If this is a `Revolut Pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, + "sepa_debit": { + "description": "If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.", + "properties": { + "iban": { "maxLength": 5000, "type": "string" - }, - "tracking_number": { - "maxLength": 5000, + } + }, + "required": ["iban"], + "title": "param", + "type": "object" + }, + "sofort": { + "description": "If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.", + "properties": { + "country": { + "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], "type": "string" } }, - "required": ["address", "name"], - "title": "shipping", + "required": ["country"], + "title": "param", "type": "object" }, - "statement_descriptor": { - "description": "For non-card charges, you can use this value as the complete description that appears on your customers’ statements. Must contain at least one letter, maximum 22 characters.", - "maxLength": 22, - "type": "string" + "swish": { + "description": "If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.", + "properties": {}, + "title": "param", + "type": "object" }, - "statement_descriptor_suffix": { - "description": "Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.", - "maxLength": 22, - "type": "string" + "twint": { + "description": "If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.", + "properties": {}, + "title": "param", + "type": "object" }, - "transfer_data": { - "description": "The parameters used to automatically create a Transfer when the payment succeeds.\nFor more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "type": { + "description": "The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.", + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "description": "If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.", "properties": { - "amount": { - "type": "integer" + "account_holder_type": { + "enum": ["company", "individual"], + "type": "string" }, - "destination": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "savings"], + "type": "string" + }, + "financial_connections_account": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, "type": "string" } }, - "required": ["destination"], - "title": "transfer_data_creation_params", + "title": "payment_method_param", "type": "object" }, - "transfer_group": { - "description": "A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details.", - "type": "string" + "wechat_pay": { + "description": "If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.", + "properties": {}, + "title": "param", + "type": "object" }, - "use_stripe_sdk": { - "description": "Set to `true` only when using manual confirmation and the iOS or Android SDKs to handle additional authentication steps.", - "type": "boolean" + "zip": { + "description": "If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.", + "properties": {}, + "title": "param", + "type": "object" } }, - "required": ["amount", "currency"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_intent" + "$ref": "#/components/schemas/payment_method" } } }, @@ -62329,22 +112616,11 @@ } } }, - "/v1/payment_intents/{intent}": { + "/v1/payment_methods/{payment_method}": { "get": { - "description": "

Retrieves the details of a PaymentIntent that has previously been created.

\n\n

Client-side retrieval using a publishable key is allowed when the client_secret is provided in the query string.

\n\n

When retrieved with a publishable key, only a subset of properties will be returned. Please refer to the payment intent object reference for more details.

", - "operationId": "GetPaymentIntentsIntent", + "description": "

Retrieves a PaymentMethod object attached to the StripeAccount. To retrieve a payment method attached to a Customer, you should use Retrieve a Customer’s PaymentMethods

", + "operationId": "GetPaymentMethodsPaymentMethod", "parameters": [ - { - "description": "The client secret of the PaymentIntent. Required if a publishable key is used to retrieve the source.", - "in": "query", - "name": "client_secret", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -62362,7 +112638,7 @@ }, { "in": "path", - "name": "intent", + "name": "payment_method", "required": true, "schema": { "maxLength": 5000, @@ -62376,6 +112652,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -62388,7 +112665,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_intent" + "$ref": "#/components/schemas/payment_method" } } }, @@ -62407,12 +112684,12 @@ } }, "post": { - "description": "

Updates properties on a PaymentIntent object without confirming.

\n\n

Depending on which properties you update, you may need to confirm the\nPaymentIntent again. For example, updating the payment_method will\nalways require you to confirm the PaymentIntent again. If you prefer to\nupdate and confirm at the same time, we recommend updating properties via\nthe confirm API instead.

", - "operationId": "PostPaymentIntentsIntent", + "description": "

Updates a PaymentMethod object. A PaymentMethod must be attached a customer to be updated.

", + "operationId": "PostPaymentMethodsPaymentMethod", "parameters": [ { "in": "path", - "name": "intent", + "name": "payment_method", "required": true, "schema": { "maxLength": 5000, @@ -62425,519 +112702,72 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "application_fee_amount": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "payment_method_data": { + "billing_details": { "explode": true, "style": "deepObject" }, - "payment_method_options": { + "card": { "explode": true, "style": "deepObject" }, - "payment_method_types": { + "expand": { "explode": true, "style": "deepObject" }, - "receipt_email": { + "link": { "explode": true, "style": "deepObject" }, - "shipping": { + "metadata": { "explode": true, "style": "deepObject" }, - "transfer_data": { + "us_bank_account": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "amount": { - "description": "Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).", - "type": "integer" - }, - "application_fee_amount": { - "anyOf": [ - { - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts)." - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, - "customer": { - "description": "ID of the Customer this PaymentIntent belongs to, if one exists.\n\nPayment methods attached to other Customers cannot be used with this PaymentIntent.\n\nIf present in combination with [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage), this PaymentIntent's payment method will be attached to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete.", - "maxLength": 5000, - "type": "string" - }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 1000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "payment_method": { - "description": "ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.", - "maxLength": 5000, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": ["always", "limited", "unspecified"], "type": "string" }, - "payment_method_data": { - "description": "If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear\nin the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)\nproperty on the PaymentIntent.", - "properties": { - "afterpay_clearpay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "alipay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "au_becs_debit": { - "properties": { - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "bsb_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "bsb_number"], - "title": "param", - "type": "object" - }, - "bacs_debit": { - "properties": { - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "sort_code": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "bancontact": { - "properties": {}, - "title": "param", - "type": "object" - }, - "billing_details": { - "properties": { - "address": { - "anyOf": [ - { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "billing_details_address", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "billing_details_inner_params", - "type": "object" - }, - "eps": { - "properties": { - "bank": { - "enum": [ - "arzte_und_apotheker_bank", - "austrian_anadi_bank_ag", - "bank_austria", - "bankhaus_carl_spangler", - "bankhaus_schelhammer_und_schattera_ag", - "bawag_psk_ag", - "bks_bank_ag", - "brull_kallmus_bank_ag", - "btv_vier_lander_bank", - "capital_bank_grawe_gruppe_ag", - "dolomitenbank", - "easybank_ag", - "erste_bank_und_sparkassen", - "hypo_alpeadriabank_international_ag", - "hypo_bank_burgenland_aktiengesellschaft", - "hypo_noe_lb_fur_niederosterreich_u_wien", - "hypo_oberosterreich_salzburg_steiermark", - "hypo_tirol_bank_ag", - "hypo_vorarlberg_bank_ag", - "marchfelder_bank", - "oberbank_ag", - "raiffeisen_bankengruppe_osterreich", - "schoellerbank_ag", - "sparda_bank_wien", - "volksbank_gruppe", - "volkskreditbank_ag", - "vr_bank_braunau" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "fpx": { - "properties": { - "bank": { - "enum": [ - "affin_bank", - "alliance_bank", - "ambank", - "bank_islam", - "bank_muamalat", - "bank_rakyat", - "bsn", - "cimb", - "deutsche_bank", - "hong_leong_bank", - "hsbc", - "kfh", - "maybank2e", - "maybank2u", - "ocbc", - "pb_enterprise", - "public_bank", - "rhb", - "standard_chartered", - "uob" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - } - }, - "required": ["bank"], - "title": "param", - "type": "object" - }, - "giropay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "grabpay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "ideal": { - "properties": { - "bank": { - "enum": [ - "abn_amro", - "asn_bank", - "bunq", - "handelsbanken", - "ing", - "knab", - "moneyou", - "rabobank", - "regiobank", - "revolut", - "sns_bank", - "triodos_bank", - "van_lanschot" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "interac_present": { - "properties": {}, - "title": "param", - "type": "object" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "oxxo": { - "properties": {}, - "title": "param", - "type": "object" - }, - "p24": { - "properties": { - "bank": { - "enum": [ - "alior_bank", - "bank_millennium", - "bank_nowy_bfg_sa", - "bank_pekao_sa", - "banki_spbdzielcze", - "blik", - "bnp_paribas", - "boz", - "citi_handlowy", - "credit_agricole", - "envelobank", - "etransfer_pocztowy24", - "getin_bank", - "ideabank", - "ing", - "inteligo", - "mbank_mtransfer", - "nest_przelew", - "noble_pay", - "pbac_z_ipko", - "plus_bank", - "santander_przelew24", - "tmobile_usbugi_bankowe", - "toyota_bank", - "volkswagen_bank" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "sepa_debit": { - "properties": { - "iban": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["iban"], - "title": "param", - "type": "object" - }, - "sofort": { - "properties": { - "country": { - "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], - "type": "string" - } - }, - "required": ["country"], - "title": "param", - "type": "object" - }, - "type": { - "enum": [ - "afterpay_clearpay", - "alipay", - "au_becs_debit", - "bacs_debit", - "bancontact", - "eps", - "fpx", - "giropay", - "grabpay", - "ideal", - "oxxo", - "p24", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true - } - }, - "required": ["type"], - "title": "payment_method_data_params", - "type": "object" - }, - "payment_method_options": { - "description": "Payment-method-specific configuration for this PaymentIntent.", + "billing_details": { + "description": "Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.", "properties": { - "alipay": { - "anyOf": [ - { - "properties": {}, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "bancontact": { - "anyOf": [ - { - "properties": { - "preferred_language": { - "enum": ["de", "en", "fr", "nl"], - "type": "string" - } - }, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "card": { + "address": { "anyOf": [ { "properties": { - "cvc_token": { + "city": { "maxLength": 5000, - "type": "string" - }, - "installments": { - "properties": { - "enabled": { - "type": "boolean" - }, - "plan": { - "anyOf": [ - { - "properties": { - "count": { - "type": "integer" - }, - "interval": { - "enum": ["month"], - "type": "string" - }, - "type": { - "enum": ["fixed_count"], - "type": "string" - } - }, - "required": [ - "count", - "interval", - "type" - ], - "title": "installment_plan", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "installments_param", - "type": "object" + "type": "string" }, - "network": { - "enum": [ - "amex", - "cartes_bancaires", - "diners", - "discover", - "interac", - "jcb", - "mastercard", - "unionpay", - "unknown", - "visa" - ], + "country": { "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" }, - "request_three_d_secure": { - "enum": ["any", "automatic"], + "line1": { "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" } }, - "title": "payment_intent_param", + "title": "billing_details_address", "type": "object" }, { @@ -62946,16 +112776,10 @@ } ] }, - "oxxo": { + "email": { "anyOf": [ { - "properties": { - "expires_after_days": { - "type": "integer" - } - }, - "title": "payment_method_options_param", - "type": "object" + "type": "string" }, { "enum": [""], @@ -62963,16 +112787,11 @@ } ] }, - "p24": { + "name": { "anyOf": [ { - "properties": { - "tos_shown_and_accepted": { - "type": "boolean" - } - }, - "title": "payment_method_options_param", - "type": "object" + "maxLength": 5000, + "type": "string" }, { "enum": [""], @@ -62980,134 +112799,70 @@ } ] }, - "sepa_debit": { + "phone": { "anyOf": [ { - "properties": { - "mandate_options": { - "properties": {}, - "title": "payment_method_options_mandate_options_param", - "type": "object" - } - }, - "title": "payment_intent_payment_method_options_param", - "type": "object" + "maxLength": 5000, + "type": "string" }, { "enum": [""], "type": "string" } ] + } + }, + "title": "billing_details_inner_params", + "type": "object" + }, + "card": { + "description": "If this is a `card` PaymentMethod, this hash contains the user's card details.", + "properties": { + "exp_month": { + "type": "integer" }, - "sofort": { - "anyOf": [ - { - "properties": { - "preferred_language": { - "enum": [ - "de", - "en", - "es", - "fr", - "it", - "nl", - "pl" - ], - "type": "string" - } - }, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], + "exp_year": { + "type": "integer" + }, + "networks": { + "properties": { + "preferred": { + "enum": [ + "", + "cartes_bancaires", + "mastercard", + "visa" + ], "type": "string" } - ] + }, + "title": "networks_update_api_param", + "type": "object" } }, - "title": "payment_method_options_param", + "title": "update_api_param", "type": "object" }, - "payment_method_types": { - "description": "The list of payment method types (e.g. card) that this PaymentIntent is allowed to use.", + "expand": { + "description": "Specifies which fields in the response should be expanded.", "items": { "maxLength": 5000, "type": "string" }, "type": "array" }, - "receipt_email": { - "anyOf": [ - { - "type": "string" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails)." - }, - "setup_future_usage": { - "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).\n\nIf `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.", - "enum": ["", "off_session", "on_session"], - "type": "string" + "link": { + "description": "If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.", + "properties": {}, + "title": "param", + "type": "object" }, - "shipping": { + "metadata": { "anyOf": [ { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["line1"], - "title": "address", - "type": "object" - }, - "carrier": { - "maxLength": 5000, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - }, - "tracking_number": { - "maxLength": 5000, - "type": "string" - } + "additionalProperties": { + "type": "string" }, - "required": ["address", "name"], - "title": "shipping", "type": "object" }, { @@ -63115,31 +112870,22 @@ "type": "string" } ], - "description": "Shipping information for this PaymentIntent." - }, - "statement_descriptor": { - "description": "For non-card charges, you can use this value as the complete description that appears on your customers’ statements. Must contain at least one letter, maximum 22 characters.", - "maxLength": 22, - "type": "string" - }, - "statement_descriptor_suffix": { - "description": "Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.", - "maxLength": 22, - "type": "string" + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "transfer_data": { - "description": "The parameters used to automatically create a Transfer when the payment succeeds. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", + "us_bank_account": { + "description": "If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.", "properties": { - "amount": { - "type": "integer" + "account_holder_type": { + "enum": ["company", "individual"], + "type": "string" + }, + "account_type": { + "enum": ["checking", "savings"], + "type": "string" } }, - "title": "transfer_data_update_params", + "title": "update_param", "type": "object" - }, - "transfer_group": { - "description": "A string that identifies the resulting payment as part of a group. `transfer_group` may only be provided if it has not been set. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details.", - "type": "string" } }, "type": "object" @@ -63153,7 +112899,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_intent" + "$ref": "#/components/schemas/payment_method" } } }, @@ -63172,14 +112918,14 @@ } } }, - "/v1/payment_intents/{intent}/cancel": { + "/v1/payment_methods/{payment_method}/attach": { "post": { - "description": "

A PaymentIntent object can be canceled when it is in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, or requires_action.

\n\n

Once canceled, no additional charges will be made by the PaymentIntent and any operations on the PaymentIntent will fail with an error. For PaymentIntents with status=’requires_capture’, the remaining amount_capturable will automatically be refunded.

", - "operationId": "PostPaymentIntentsIntentCancel", + "description": "

Attaches a PaymentMethod object to a Customer.

\n\n

To attach a new PaymentMethod to a customer for future payments, we recommend you use a SetupIntent\nor a PaymentIntent with setup_future_usage.\nThese approaches will perform any necessary steps to set up the PaymentMethod for future payments. Using the /v1/payment_methods/:id/attach\nendpoint without first using a SetupIntent or PaymentIntent with setup_future_usage does not optimize the PaymentMethod for\nfuture use, which makes later declines and payment friction more likely.\nSee Optimizing cards for future payments for more information about setting up\nfuture payments.

\n\n

To use this PaymentMethod as the default for invoice or subscription payments,\nset invoice_settings.default_payment_method,\non the Customer to the PaymentMethod’s ID.

", + "operationId": "PostPaymentMethodsPaymentMethodAttach", "parameters": [ { "in": "path", - "name": "intent", + "name": "payment_method", "required": true, "schema": { "maxLength": 5000, @@ -63198,18 +112944,12 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "cancellation_reason": { - "description": "Reason for canceling this PaymentIntent. Possible values are `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`", - "enum": [ - "abandoned", - "duplicate", - "fraudulent", - "requested_by_customer" - ], + "customer": { + "description": "The ID of the customer to which to attach the PaymentMethod.", "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -63220,18 +112960,19 @@ "type": "array" } }, + "required": ["customer"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_intent" + "$ref": "#/components/schemas/payment_method" } } }, @@ -63250,14 +112991,14 @@ } } }, - "/v1/payment_intents/{intent}/capture": { + "/v1/payment_methods/{payment_method}/detach": { "post": { - "description": "

Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.

\n\n

Uncaptured PaymentIntents will be canceled exactly seven days after they are created.

\n\n

Learn more about separate authorization and capture.

", - "operationId": "PostPaymentIntentsIntentCapture", + "description": "

Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.

", + "operationId": "PostPaymentMethodsPaymentMethodDetach", "parameters": [ { "in": "path", - "name": "intent", + "name": "payment_method", "required": true, "schema": { "maxLength": 5000, @@ -63273,21 +113014,288 @@ "expand": { "explode": true, "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } }, - "transfer_data": { + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payment_method" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/payouts": { + "get": { + "description": "

Returns a list of existing payouts sent to third-party bank accounts or payouts that Stripe sent to you. The payouts return in sorted order, with the most recently created payouts appearing first.

", + "operationId": "GetPayouts", + "parameters": [ + { + "description": "Only return payouts that are expected to arrive during the given date interval.", + "explode": true, + "in": "query", + "name": "arrival_date", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return payouts that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "The ID of an external account - only return payouts sent to this external account.", + "in": "query", + "name": "destination", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return payouts that have the given status: `pending`, `paid`, `failed`, or `canceled`.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/payout" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/payouts", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PayoutList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

To send funds to your own bank account, create a new payout object. Your Stripe balance must cover the payout amount. If it doesn’t, you receive an “Insufficient Funds” error.

\n\n

If your API key is in test mode, money won’t actually be sent, though every other action occurs as if you’re in live mode.

\n\n

If you create a manual payout on a Stripe account that uses multiple payment source types, you need to specify the source type balance that the payout draws from. The balance object details available and pending amounts by source type.

", + "operationId": "PostPayouts", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "amount_to_capture": { - "description": "The amount to capture from the PaymentIntent, which must be less than or equal to the original amount. Any additional amount will be automatically refunded. Defaults to the full `amount_capturable` if not provided.", + "amount": { + "description": "A positive integer in cents representing how much to payout.", "type": "integer" }, - "application_fee_amount": { - "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", - "type": "integer" + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "type": "string" + }, + "destination": { + "description": "The ID of a bank account or a card to send the payout to. If you don't provide a destination, we use the default external account for the specified currency.", + "type": "string" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -63297,39 +113305,47 @@ }, "type": "array" }, - "statement_descriptor": { - "description": "For non-card charges, you can use this value as the complete description that appears on your customers’ statements. Must contain at least one letter, maximum 22 characters.", - "maxLength": 22, - "type": "string" - }, - "statement_descriptor_suffix": { - "description": "Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.", - "maxLength": 22, - "type": "string" - }, - "transfer_data": { - "description": "The parameters used to automatically create a Transfer when the payment\nis captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).", - "properties": { - "amount": { - "type": "integer" - } + "metadata": { + "additionalProperties": { + "type": "string" }, - "title": "transfer_data_update_params", + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" + }, + "method": { + "description": "The method used to send this payout, which is `standard` or `instant`. We support `instant` for payouts to debit cards and bank accounts in certain countries. Learn more about [bank support for Instant Payouts](https://stripe.com/docs/payouts/instant-payouts-banks).", + "enum": ["instant", "standard"], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "source_type": { + "description": "The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the Balances API. One of `bank_account`, `card`, or `fpx`.", + "enum": ["bank_account", "card", "fpx"], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "statement_descriptor": { + "description": "A string that displays on the recipient's bank or card statement (up to 22 characters). A `statement_descriptor` that's longer than 22 characters return an error. Most banks truncate this information and display it inconsistently. Some banks might not display it at all.", + "maxLength": 22, + "type": "string", + "x-stripeBypassValidation": true } }, + "required": ["amount", "currency"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_intent" + "$ref": "#/components/schemas/payout" } } }, @@ -63348,14 +113364,29 @@ } } }, - "/v1/payment_intents/{intent}/confirm": { - "post": { - "description": "

Confirm that your customer intends to pay with current or provided\npayment method. Upon confirmation, the PaymentIntent will attempt to initiate\na payment.

\n\n

If the selected payment method requires additional authentication steps, the\nPaymentIntent will transition to the requires_action status and\nsuggest additional actions via next_action. If payment fails,\nthe PaymentIntent will transition to the requires_payment_method status. If\npayment succeeds, the PaymentIntent will transition to the succeeded\nstatus (or requires_capture, if capture_method is set to manual).

\n\n

If the confirmation_method is automatic, payment may be attempted\nusing our client SDKs\nand the PaymentIntent’s client_secret.\nAfter next_actions are handled by the client, no additional\nconfirmation is required to complete the payment.

\n\n

If the confirmation_method is manual, all payment attempts must be\ninitiated using a secret key.\nIf any actions are required for the payment, the PaymentIntent will\nreturn to the requires_confirmation state\nafter those actions are completed. Your server needs to then\nexplicitly re-confirm the PaymentIntent to initiate the next payment\nattempt. Read the expanded documentation\nto learn more about manual confirmation.

", - "operationId": "PostPaymentIntentsIntentConfirm", + "/v1/payouts/{payout}": { + "get": { + "description": "

Retrieves the details of an existing payout. Supply the unique payout ID from either a payout creation request or the payout list. Stripe returns the corresponding payout information.

", + "operationId": "GetPayoutsPayout", "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, { "in": "path", - "name": "intent", + "name": "payout", "required": true, "schema": { "maxLength": 5000, @@ -63367,751 +113398,857 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "mandate_data": { - "explode": true, - "style": "deepObject" - }, - "off_session": { - "explode": true, - "style": "deepObject" - }, - "payment_method_data": { - "explode": true, - "style": "deepObject" - }, - "payment_method_options": { - "explode": true, - "style": "deepObject" - }, - "payment_method_types": { - "explode": true, - "style": "deepObject" - }, - "receipt_email": { - "explode": true, - "style": "deepObject" - }, - "shipping": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "client_secret": { - "description": "The client secret of the PaymentIntent.", - "maxLength": 5000, - "type": "string" - }, - "error_on_requires_action": { - "description": "Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. This parameter is intended for simpler integrations that do not handle customer actions, like [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication).", - "type": "boolean" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "mandate": { - "description": "ID of the mandate to be used for this payment.", - "maxLength": 5000, - "type": "string" - }, - "mandate_data": { - "anyOf": [ - { - "properties": { - "customer_acceptance": { - "properties": { - "accepted_at": { - "format": "unix-time", - "type": "integer" - }, - "offline": { - "properties": {}, - "title": "offline_param", - "type": "object" - }, - "online": { - "properties": { - "ip_address": { - "type": "string" - }, - "user_agent": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["ip_address", "user_agent"], - "title": "online_param", - "type": "object" - }, - "type": { - "enum": ["offline", "online"], - "maxLength": 5000, - "type": "string" - } - }, - "required": ["type"], - "title": "customer_acceptance_param", - "type": "object" - } - }, - "required": ["customer_acceptance"], - "title": "secret_key_param", - "type": "object" - }, - { - "properties": { - "customer_acceptance": { - "properties": { - "online": { - "properties": { - "ip_address": { - "type": "string" - }, - "user_agent": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "online_param", - "type": "object" - }, - "type": { - "enum": ["online"], - "maxLength": 5000, - "type": "string" - } - }, - "required": ["online", "type"], - "title": "customer_acceptance_param", - "type": "object" - } - }, - "required": ["customer_acceptance"], - "title": "client_key_param", - "type": "object" - } - ], - "description": "This hash contains details about the Mandate to create" - }, - "off_session": { - "anyOf": [ - { - "type": "boolean" - }, - { - "enum": ["one_off", "recurring"], - "maxLength": 5000, - "type": "string" - } - ], - "description": "Set to `true` to indicate that the customer is not in your checkout flow during this payment attempt, and therefore is unable to authenticate. This parameter is intended for scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards)." - }, - "payment_method": { - "description": "ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.", - "maxLength": 5000, - "type": "string" - }, - "payment_method_data": { - "description": "If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear\nin the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)\nproperty on the PaymentIntent.", - "properties": { - "afterpay_clearpay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "alipay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "au_becs_debit": { - "properties": { - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "bsb_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "bsb_number"], - "title": "param", - "type": "object" - }, - "bacs_debit": { - "properties": { - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "sort_code": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "bancontact": { - "properties": {}, - "title": "param", - "type": "object" - }, - "billing_details": { - "properties": { - "address": { - "anyOf": [ - { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "billing_details_address", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "billing_details_inner_params", - "type": "object" - }, - "eps": { - "properties": { - "bank": { - "enum": [ - "arzte_und_apotheker_bank", - "austrian_anadi_bank_ag", - "bank_austria", - "bankhaus_carl_spangler", - "bankhaus_schelhammer_und_schattera_ag", - "bawag_psk_ag", - "bks_bank_ag", - "brull_kallmus_bank_ag", - "btv_vier_lander_bank", - "capital_bank_grawe_gruppe_ag", - "dolomitenbank", - "easybank_ag", - "erste_bank_und_sparkassen", - "hypo_alpeadriabank_international_ag", - "hypo_bank_burgenland_aktiengesellschaft", - "hypo_noe_lb_fur_niederosterreich_u_wien", - "hypo_oberosterreich_salzburg_steiermark", - "hypo_tirol_bank_ag", - "hypo_vorarlberg_bank_ag", - "marchfelder_bank", - "oberbank_ag", - "raiffeisen_bankengruppe_osterreich", - "schoellerbank_ag", - "sparda_bank_wien", - "volksbank_gruppe", - "volkskreditbank_ag", - "vr_bank_braunau" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "fpx": { - "properties": { - "bank": { - "enum": [ - "affin_bank", - "alliance_bank", - "ambank", - "bank_islam", - "bank_muamalat", - "bank_rakyat", - "bsn", - "cimb", - "deutsche_bank", - "hong_leong_bank", - "hsbc", - "kfh", - "maybank2e", - "maybank2u", - "ocbc", - "pb_enterprise", - "public_bank", - "rhb", - "standard_chartered", - "uob" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - } - }, - "required": ["bank"], - "title": "param", - "type": "object" - }, - "giropay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "grabpay": { - "properties": {}, - "title": "param", - "type": "object" - }, - "ideal": { - "properties": { - "bank": { - "enum": [ - "abn_amro", - "asn_bank", - "bunq", - "handelsbanken", - "ing", - "knab", - "moneyou", - "rabobank", - "regiobank", - "revolut", - "sns_bank", - "triodos_bank", - "van_lanschot" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "interac_present": { - "properties": {}, - "title": "param", - "type": "object" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "oxxo": { - "properties": {}, - "title": "param", - "type": "object" - }, - "p24": { - "properties": { - "bank": { - "enum": [ - "alior_bank", - "bank_millennium", - "bank_nowy_bfg_sa", - "bank_pekao_sa", - "banki_spbdzielcze", - "blik", - "bnp_paribas", - "boz", - "citi_handlowy", - "credit_agricole", - "envelobank", - "etransfer_pocztowy24", - "getin_bank", - "ideabank", - "ing", - "inteligo", - "mbank_mtransfer", - "nest_przelew", - "noble_pay", - "pbac_z_ipko", - "plus_bank", - "santander_przelew24", - "tmobile_usbugi_bankowe", - "toyota_bank", - "volkswagen_bank" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "sepa_debit": { - "properties": { - "iban": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["iban"], - "title": "param", - "type": "object" - }, - "sofort": { - "properties": { - "country": { - "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], - "type": "string" - } + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payout" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the specified payout by setting the values of the parameters you pass. We don’t change parameters that you don’t provide. This request only accepts the metadata as arguments.

", + "operationId": "PostPayoutsPayout", + "parameters": [ + { + "in": "path", + "name": "payout", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" }, - "required": ["country"], - "title": "param", "type": "object" }, - "type": { - "enum": [ - "afterpay_clearpay", - "alipay", - "au_becs_debit", - "bacs_debit", - "bancontact", - "eps", - "fpx", - "giropay", - "grabpay", - "ideal", - "oxxo", - "p24", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true + { + "enum": [""], + "type": "string" } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payout" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/payouts/{payout}/cancel": { + "post": { + "description": "

You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can’t cancel automatic Stripe payouts.

", + "operationId": "PostPayoutsPayoutCancel", + "parameters": [ + { + "in": "path", + "name": "payout", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "required": ["type"], - "title": "payment_method_data_params", + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payout" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/payouts/{payout}/reverse": { + "post": { + "description": "

Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.

\n\n

By requesting a reversal through /v1/payouts/:id/reverse, you confirm that the authorized signatory of the selected bank account authorizes the debit on the bank account and that no other authorization is required.

", + "operationId": "PostPayoutsPayoutReverse", + "parameters": [ + { + "in": "path", + "name": "payout", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/payout" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/plans": { + "get": { + "description": "

Returns a list of your plans.

", + "operationId": "GetPlans", + "parameters": [ + { + "description": "Only return plans that are active or inactive (e.g., pass `false` to list all inactive plans).", + "in": "query", + "name": "active", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } }, - "payment_method_options": { - "description": "Payment-method-specific configuration for this PaymentIntent.", - "properties": { - "alipay": { - "anyOf": [ - { - "properties": {}, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "bancontact": { - "anyOf": [ - { - "properties": { - "preferred_language": { - "enum": ["de", "en", "fr", "nl"], - "type": "string" - } - }, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "card": { - "anyOf": [ - { - "properties": { - "cvc_token": { - "maxLength": 5000, - "type": "string" - }, - "installments": { - "properties": { - "enabled": { - "type": "boolean" - }, - "plan": { - "anyOf": [ - { - "properties": { - "count": { - "type": "integer" - }, - "interval": { - "enum": ["month"], - "type": "string" - }, - "type": { - "enum": ["fixed_count"], - "type": "string" - } - }, - "required": [ - "count", - "interval", - "type" - ], - "title": "installment_plan", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "installments_param", - "type": "object" - }, - "network": { - "enum": [ - "amex", - "cartes_bancaires", - "diners", - "discover", - "interac", - "jcb", - "mastercard", - "unionpay", - "unknown", - "visa" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "request_three_d_secure": { - "enum": ["any", "automatic"], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - } - }, - "title": "payment_intent_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "oxxo": { - "anyOf": [ - { - "properties": { - "expires_after_days": { - "type": "integer" - } - }, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "p24": { - "anyOf": [ - { - "properties": { - "tos_shown_and_accepted": { - "type": "boolean" - } - }, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "sepa_debit": { - "anyOf": [ - { - "properties": { - "mandate_options": { - "properties": {}, - "title": "payment_method_options_mandate_options_param", - "type": "object" - } - }, - "title": "payment_intent_payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Only return plans for the given product.", + "in": "query", + "name": "product", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/plan" }, - "sofort": { - "anyOf": [ - { - "properties": { - "preferred_language": { - "enum": [ - "de", - "en", - "es", - "fr", - "it", - "nl", - "pl" - ], - "type": "string" - } - }, - "title": "payment_method_options_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - } + "type": "array" }, - "title": "payment_method_options_param", - "type": "object" + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/plans", + "type": "string" + } }, - "payment_method_types": { - "description": "The list of payment method types (e.g. card) that this PaymentIntent is allowed to use.", + "required": ["data", "has_more", "object", "url"], + "title": "PlanList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

You can now model subscriptions more flexibly using the Prices API. It replaces the Plans API and is backwards compatible to simplify your migration.

", + "operationId": "PostPlans", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "product": { + "explode": true, + "style": "deepObject" + }, + "tiers": { + "explode": true, + "style": "deepObject" + }, + "transform_usage": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Whether the plan is currently available for new subscriptions. Defaults to `true`.", + "type": "boolean" + }, + "aggregate_usage": { + "description": "Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`.", + "enum": ["last_during_period", "last_ever", "max", "sum"], + "type": "string" + }, + "amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free plan) representing how much to charge on a recurring basis.", + "type": "integer" + }, + "amount_decimal": { + "description": "Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set.", + "format": "decimal", + "type": "string" + }, + "billing_scheme": { + "description": "Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.", + "enum": ["per_unit", "tiered"], + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", "items": { "maxLength": 5000, "type": "string" }, "type": "array" }, - "receipt_email": { + "id": { + "description": "An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes.", + "maxLength": 5000, + "type": "string" + }, + "interval": { + "description": "Specifies billing frequency. Either `day`, `week`, `month` or `year`.", + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).", + "type": "integer" + }, + "metadata": { "anyOf": [ { - "type": "string" + "additionalProperties": { + "type": "string" + }, + "type": "object" }, { "enum": [""], "type": "string" } ], - "description": "Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails)." + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "return_url": { - "description": "The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.\nIf you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.\nThis parameter is only used for cards and other redirect-based payment methods.", + "meter": { + "description": "The meter tracking the usage of a metered price", + "maxLength": 5000, "type": "string" }, - "setup_future_usage": { - "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).\n\nIf `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.", - "enum": ["", "off_session", "on_session"], + "nickname": { + "description": "A brief description of the plan, hidden from customers.", + "maxLength": 5000, "type": "string" }, - "shipping": { + "product": { "anyOf": [ { + "description": "The product whose pricing the created plan will represent. This can either be the ID of an existing product, or a dictionary containing fields used to create a [service product](https://stripe.com/docs/api#product_object-type).", "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["line1"], - "title": "address", - "type": "object" + "active": { + "type": "boolean" }, - "carrier": { + "id": { + "deprecated": true, "maxLength": 5000, "type": "string" }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, "name": { "maxLength": 5000, "type": "string" }, - "phone": { - "maxLength": 5000, + "statement_descriptor": { + "maxLength": 22, "type": "string" }, - "tracking_number": { + "tax_code": { "maxLength": 5000, "type": "string" + }, + "unit_label": { + "maxLength": 12, + "type": "string" } }, - "required": ["address", "name"], - "title": "shipping", + "required": ["name"], + "title": "inline_product_params", + "type": "object" + }, + { + "description": "The ID of the product whose pricing the created plan will represent.", + "maxLength": 5000, + "type": "string" + } + ] + }, + "tiers": { + "description": "Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.", + "items": { + "properties": { + "flat_amount": { + "type": "integer" + }, + "flat_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "up_to": { + "anyOf": [ + { + "enum": ["inf"], + "maxLength": 5000, + "type": "string" + }, + { + "type": "integer" + } + ] + } + }, + "required": ["up_to"], + "title": "tier", + "type": "object" + }, + "type": "array" + }, + "tiers_mode": { + "description": "Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.", + "enum": ["graduated", "volume"], + "type": "string" + }, + "transform_usage": { + "description": "Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.", + "properties": { + "divide_by": { + "type": "integer" + }, + "round": { + "enum": ["down", "up"], + "type": "string" + } + }, + "required": ["divide_by", "round"], + "title": "transform_usage_param", + "type": "object" + }, + "trial_period_days": { + "description": "Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).", + "type": "integer" + }, + "usage_type": { + "description": "Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.", + "enum": ["licensed", "metered"], + "type": "string" + } + }, + "required": ["currency", "interval"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/plan" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/plans/{plan}": { + "delete": { + "description": "

Deleting plans means new subscribers can’t be added. Existing subscribers aren’t affected.

", + "operationId": "DeletePlansPlan", + "parameters": [ + { + "in": "path", + "name": "plan", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_plan" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves the plan with the given ID.

", + "operationId": "GetPlansPlan", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "plan", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/plan" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the specified plan by setting the values of the parameters passed. Any parameters not provided are left unchanged. By design, you cannot change a plan’s ID, amount, currency, or billing cycle.

", + "operationId": "PostPlansPlan", + "parameters": [ + { + "in": "path", + "name": "plan", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Whether the plan is currently available for new subscriptions.", + "type": "boolean" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, "type": "object" }, { @@ -64119,11 +114256,21 @@ "type": "string" } ], - "description": "Shipping information for this PaymentIntent." + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "use_stripe_sdk": { - "description": "Set to `true` only when using manual confirmation and the iOS or Android SDKs to handle additional authentication steps.", - "type": "boolean" + "nickname": { + "description": "A brief description of the plan, hidden from customers.", + "maxLength": 5000, + "type": "string" + }, + "product": { + "description": "The product the plan belongs to. This cannot be changed once it has been used in a subscription or subscription schedule.", + "maxLength": 5000, + "type": "string" + }, + "trial_period_days": { + "description": "Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).", + "type": "integer" } }, "type": "object" @@ -64137,7 +114284,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_intent" + "$ref": "#/components/schemas/plan" } } }, @@ -64156,18 +114303,60 @@ } } }, - "/v1/payment_methods": { + "/v1/prices": { "get": { - "description": "

Returns a list of PaymentMethods for a given Customer

", - "operationId": "GetPaymentMethods", + "description": "

Returns a list of your active prices, excluding inline prices. For the list of inactive prices, set active to false.

", + "operationId": "GetPrices", "parameters": [ { - "description": "The ID of the customer whose PaymentMethods will be retrieved.", + "description": "Only return prices that are active or inactive (e.g., pass `false` to list all inactive prices).", "in": "query", - "name": "customer", - "required": true, + "name": "active", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return prices for the given currency.", + "in": "query", + "name": "currency", + "required": false, "schema": { - "maxLength": 5000, "type": "string" }, "style": "form" @@ -64178,6 +114367,7 @@ "name": "ending_before", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" @@ -64207,41 +114397,77 @@ }, "style": "form" }, + { + "description": "Only return the price with these lookup_keys, if any exist. You can specify up to 10 lookup_keys.", + "explode": true, + "in": "query", + "name": "lookup_keys", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "Only return prices for the given product.", + "in": "query", + "name": "product", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return prices with these recurring fields.", + "explode": true, + "in": "query", + "name": "recurring", + "required": false, + "schema": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "meter": { + "maxLength": 5000, + "type": "string" + }, + "usage_type": { + "enum": ["licensed", "metered"], + "type": "string" + } + }, + "title": "all_prices_recurring_params", + "type": "object" + }, + "style": "deepObject" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", "name": "starting_after", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" }, { - "description": "A required filter on the list, based on the object `type` field.", + "description": "Only return prices of type `recurring` or `one_time`.", "in": "query", "name": "type", - "required": true, + "required": false, "schema": { - "enum": [ - "afterpay_clearpay", - "alipay", - "au_becs_debit", - "bacs_debit", - "bancontact", - "card", - "eps", - "fpx", - "giropay", - "grabpay", - "ideal", - "oxxo", - "p24", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true + "enum": ["one_time", "recurring"], + "type": "string" }, "style": "form" } @@ -64251,6 +114477,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -64266,8 +114493,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/price" }, "type": "array" }, @@ -64283,12 +114511,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/payment_methods", + "pattern": "^/v1/prices", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "PaymentFlowsPaymentMethodList", + "title": "PriceList", "type": "object", "x-expandableFields": ["data"] } @@ -64309,41 +114537,17 @@ } }, "post": { - "description": "

Creates a PaymentMethod object. Read the Stripe.js reference to learn how to create PaymentMethods via Stripe.js.

", - "operationId": "PostPaymentMethods", + "description": "

Creates a new price for an existing product. The price can be recurring or one-time.

", + "operationId": "PostPrices", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "afterpay_clearpay": { + "currency_options": { "explode": true, "style": "deepObject" }, - "alipay": { - "explode": true, - "style": "deepObject" - }, - "au_becs_debit": { - "explode": true, - "style": "deepObject" - }, - "bacs_debit": { - "explode": true, - "style": "deepObject" - }, - "bancontact": { - "explode": true, - "style": "deepObject" - }, - "billing_details": { - "explode": true, - "style": "deepObject" - }, - "card": { - "explode": true, - "style": "deepObject" - }, - "eps": { + "custom_unit_amount": { "explode": true, "style": "deepObject" }, @@ -64351,324 +114555,152 @@ "explode": true, "style": "deepObject" }, - "fpx": { - "explode": true, - "style": "deepObject" - }, - "giropay": { - "explode": true, - "style": "deepObject" - }, - "grabpay": { - "explode": true, - "style": "deepObject" - }, - "ideal": { - "explode": true, - "style": "deepObject" - }, - "interac_present": { - "explode": true, - "style": "deepObject" - }, "metadata": { "explode": true, "style": "deepObject" }, - "oxxo": { + "product_data": { "explode": true, "style": "deepObject" }, - "p24": { + "recurring": { "explode": true, "style": "deepObject" }, - "sepa_debit": { + "tiers": { "explode": true, "style": "deepObject" }, - "sofort": { + "transform_quantity": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "afterpay_clearpay": { - "description": "If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.", - "properties": {}, - "title": "param", - "type": "object" - }, - "alipay": { - "description": "If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.", - "properties": {}, - "title": "param", - "type": "object" - }, - "au_becs_debit": { - "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", - "properties": { - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "bsb_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "bsb_number"], - "title": "param", - "type": "object" + "active": { + "description": "Whether the price can be used for new purchases. Defaults to `true`.", + "type": "boolean" }, - "bacs_debit": { - "description": "If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.", - "properties": { - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "sort_code": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" + "billing_scheme": { + "description": "Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.", + "enum": ["per_unit", "tiered"], + "type": "string" }, - "bancontact": { - "description": "If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.", - "properties": {}, - "title": "param", - "type": "object" + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" }, - "billing_details": { - "description": "Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.", - "properties": { - "address": { - "anyOf": [ - { + "currency_options": { + "additionalProperties": { + "properties": { + "custom_unit_amount": { + "properties": { + "enabled": { + "type": "boolean" + }, + "maximum": { + "type": "integer" + }, + "minimum": { + "type": "integer" + }, + "preset": { + "type": "integer" + } + }, + "required": ["enabled"], + "title": "custom_unit_amount", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tiers": { + "items": { "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" + "flat_amount": { + "type": "integer" }, - "line1": { - "maxLength": 5000, + "flat_amount_decimal": { + "format": "decimal", "type": "string" }, - "line2": { - "maxLength": 5000, - "type": "string" + "unit_amount": { + "type": "integer" }, - "postal_code": { - "maxLength": 5000, + "unit_amount_decimal": { + "format": "decimal", "type": "string" }, - "state": { - "maxLength": 5000, - "type": "string" + "up_to": { + "anyOf": [ + { + "enum": ["inf"], + "maxLength": 5000, + "type": "string" + }, + { + "type": "integer" + } + ] } }, - "title": "billing_details_address", + "required": ["up_to"], + "title": "tier", "type": "object" }, - { - "enum": [""], - "type": "string" - } - ] - }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "billing_details_inner_params", - "type": "object" - }, - "card": { - "anyOf": [ - { - "properties": { - "cvc": { - "maxLength": 5000, - "type": "string" - }, - "exp_month": { - "type": "integer" - }, - "exp_year": { - "type": "integer" - }, - "number": { - "maxLength": 5000, - "type": "string" - } + "type": "array" }, - "required": ["exp_month", "exp_year", "number"], - "title": "card_details_params", - "type": "object" - }, - { - "properties": { - "token": { - "maxLength": 5000, - "type": "string" - } + "unit_amount": { + "type": "integer" }, - "required": ["token"], - "title": "token_params", - "type": "object" - } - ], - "description": "If this is a `card` PaymentMethod, this hash contains the user's card details. For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format `card: {token: \"tok_visa\"}`. When providing a card number, you must meet the requirements for [PCI compliance](https://stripe.com/docs/security#validating-pci-compliance). We strongly recommend using Stripe.js instead of interacting with this API directly.", - "x-stripeBypassValidation": true - }, - "customer": { - "description": "The `Customer` to whom the original PaymentMethod is attached.", - "maxLength": 5000, - "type": "string" - }, - "eps": { - "description": "If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.", - "properties": { - "bank": { - "enum": [ - "arzte_und_apotheker_bank", - "austrian_anadi_bank_ag", - "bank_austria", - "bankhaus_carl_spangler", - "bankhaus_schelhammer_und_schattera_ag", - "bawag_psk_ag", - "bks_bank_ag", - "brull_kallmus_bank_ag", - "btv_vier_lander_bank", - "capital_bank_grawe_gruppe_ag", - "dolomitenbank", - "easybank_ag", - "erste_bank_und_sparkassen", - "hypo_alpeadriabank_international_ag", - "hypo_bank_burgenland_aktiengesellschaft", - "hypo_noe_lb_fur_niederosterreich_u_wien", - "hypo_oberosterreich_salzburg_steiermark", - "hypo_tirol_bank_ag", - "hypo_vorarlberg_bank_ag", - "marchfelder_bank", - "oberbank_ag", - "raiffeisen_bankengruppe_osterreich", - "schoellerbank_ag", - "sparda_bank_wien", - "volksbank_gruppe", - "volkskreditbank_ag", - "vr_bank_braunau" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "param", - "type": "object" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "fpx": { - "description": "If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.", - "properties": { - "bank": { - "enum": [ - "affin_bank", - "alliance_bank", - "ambank", - "bank_islam", - "bank_muamalat", - "bank_rakyat", - "bsn", - "cimb", - "deutsche_bank", - "hong_leong_bank", - "hsbc", - "kfh", - "maybank2e", - "maybank2u", - "ocbc", - "pb_enterprise", - "public_bank", - "rhb", - "standard_chartered", - "uob" - ], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - } - }, - "required": ["bank"], - "title": "param", - "type": "object" - }, - "giropay": { - "description": "If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.", - "properties": {}, - "title": "param", - "type": "object" - }, - "grabpay": { - "description": "If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.", - "properties": {}, - "title": "param", - "type": "object" - }, - "ideal": { - "description": "If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.", - "properties": { - "bank": { - "enum": [ - "abn_amro", - "asn_bank", - "bunq", - "handelsbanken", - "ing", - "knab", - "moneyou", - "rabobank", - "regiobank", - "revolut", - "sns_bank", - "triodos_bank", - "van_lanschot" - ], - "maxLength": 5000, - "type": "string" - } + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "currency_option", + "type": "object" }, - "title": "param", + "description": "Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).", "type": "object" }, - "interac_present": { - "description": "If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.", - "properties": {}, - "title": "param", + "custom_unit_amount": { + "description": "When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.", + "properties": { + "enabled": { + "type": "boolean" + }, + "maximum": { + "type": "integer" + }, + "minimum": { + "type": "integer" + }, + "preset": { + "type": "integer" + } + }, + "required": ["enabled"], + "title": "custom_unit_amount", "type": "object" }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "lookup_key": { + "description": "A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.", + "maxLength": 200, + "type": "string" + }, "metadata": { "additionalProperties": { "type": "string" @@ -64676,114 +114708,175 @@ "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" }, - "oxxo": { - "description": "If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.", - "properties": {}, - "title": "param", - "type": "object" + "nickname": { + "description": "A brief description of the price, hidden from customers.", + "maxLength": 5000, + "type": "string" }, - "p24": { - "description": "If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.", + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "product_data": { + "description": "These fields can be used to create a new product that this price will belong to.", "properties": { - "bank": { - "enum": [ - "alior_bank", - "bank_millennium", - "bank_nowy_bfg_sa", - "bank_pekao_sa", - "banki_spbdzielcze", - "blik", - "bnp_paribas", - "boz", - "citi_handlowy", - "credit_agricole", - "envelobank", - "etransfer_pocztowy24", - "getin_bank", - "ideabank", - "ing", - "inteligo", - "mbank_mtransfer", - "nest_przelew", - "noble_pay", - "pbac_z_ipko", - "plus_bank", - "santander_przelew24", - "tmobile_usbugi_bankowe", - "toyota_bank", - "volkswagen_bank" - ], + "active": { + "type": "boolean" + }, + "id": { + "deprecated": true, + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "statement_descriptor": { + "maxLength": 22, + "type": "string" + }, + "tax_code": { "maxLength": 5000, "type": "string" + }, + "unit_label": { + "maxLength": 12, + "type": "string" } }, - "title": "param", + "required": ["name"], + "title": "inline_product_params", "type": "object" }, - "payment_method": { - "description": "The PaymentMethod to share.", - "maxLength": 5000, - "type": "string" - }, - "sepa_debit": { - "description": "If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.", + "recurring": { + "description": "The recurring components of a price such as `interval` and `usage_type`.", "properties": { - "iban": { + "aggregate_usage": { + "enum": [ + "last_during_period", + "last_ever", + "max", + "sum" + ], + "type": "string" + }, + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + }, + "meter": { "maxLength": 5000, "type": "string" + }, + "usage_type": { + "enum": ["licensed", "metered"], + "type": "string" } }, - "required": ["iban"], - "title": "param", + "required": ["interval"], + "title": "recurring", "type": "object" }, - "sofort": { - "description": "If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.", + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tiers": { + "description": "Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.", + "items": { + "properties": { + "flat_amount": { + "type": "integer" + }, + "flat_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "up_to": { + "anyOf": [ + { + "enum": ["inf"], + "maxLength": 5000, + "type": "string" + }, + { + "type": "integer" + } + ] + } + }, + "required": ["up_to"], + "title": "tier", + "type": "object" + }, + "type": "array" + }, + "tiers_mode": { + "description": "Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.", + "enum": ["graduated", "volume"], + "type": "string" + }, + "transfer_lookup_key": { + "description": "If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.", + "type": "boolean" + }, + "transform_quantity": { + "description": "Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.", "properties": { - "country": { - "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], + "divide_by": { + "type": "integer" + }, + "round": { + "enum": ["down", "up"], "type": "string" } }, - "required": ["country"], - "title": "param", + "required": ["divide_by", "round"], + "title": "transform_usage_param", "type": "object" }, - "type": { - "description": "The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.", - "enum": [ - "afterpay_clearpay", - "alipay", - "au_becs_debit", - "bacs_debit", - "bancontact", - "card", - "eps", - "fpx", - "giropay", - "grabpay", - "ideal", - "oxxo", - "p24", - "sepa_debit", - "sofort" - ], - "type": "string", - "x-stripeBypassValidation": true + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required, unless `billing_scheme=tiered`.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" } }, + "required": ["currency"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/price" } } }, @@ -64802,10 +114895,10 @@ } } }, - "/v1/payment_methods/{payment_method}": { + "/v1/prices/search": { "get": { - "description": "

Retrieves a PaymentMethod object.

", - "operationId": "GetPaymentMethodsPaymentMethod", + "description": "

Search for prices you’ve previously created using Stripe’s Search Query Language.\nDon’t use search in read-after-write flows where strict consistency is necessary. Under normal operating\nconditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up\nto an hour behind during outages. Search functionality is not available to merchants in India.

", + "operationId": "GetPricesSearch", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -64823,14 +114916,36 @@ "style": "deepObject" }, { - "in": "path", - "name": "payment_method", + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.", + "in": "query", + "name": "page", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for prices](https://stripe.com/docs/search#query-fields-for-prices).", + "in": "query", + "name": "query", "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" } ], "requestBody": { @@ -64838,6 +114953,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -64850,7 +114966,40 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_method" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/price" + }, + "type": "array" + }, + "has_more": { + "type": "boolean" + }, + "next_page": { + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["search_result"], + "type": "string" + }, + "total_count": { + "description": "The total number of objects that match the query, only accurate up to 10,000.", + "type": "integer" + }, + "url": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SearchResult", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -64867,14 +115016,31 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates a PaymentMethod object. A PaymentMethod must be attached a customer to be updated.

", - "operationId": "PostPaymentMethodsPaymentMethod", + } + }, + "/v1/prices/{price}": { + "get": { + "description": "

Retrieves the price with the given ID.

", + "operationId": "GetPricesPrice", "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, { "in": "path", - "name": "payment_method", + "name": "price", "required": true, "schema": { "maxLength": 5000, @@ -64886,119 +115052,10 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "billing_details": { - "explode": true, - "style": "deepObject" - }, - "card": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "billing_details": { - "description": "Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.", - "properties": { - "address": { - "anyOf": [ - { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "billing_details_address", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "billing_details_inner_params", - "type": "object" - }, - "card": { - "description": "If this is a `card` PaymentMethod, this hash contains the user's card details.", - "properties": { - "exp_month": { - "type": "integer" - }, - "exp_year": { - "type": "integer" - } - }, - "title": "update_api_param", - "type": "object" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -65010,7 +115067,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/price" } } }, @@ -65027,16 +115084,14 @@ "description": "Error response." } } - } - }, - "/v1/payment_methods/{payment_method}/attach": { + }, "post": { - "description": "

Attaches a PaymentMethod object to a Customer.

\n\n

To attach a new PaymentMethod to a customer for future payments, we recommend you use a SetupIntent\nor a PaymentIntent with setup_future_usage.\nThese approaches will perform any necessary steps to ensure that the PaymentMethod can be used in a future payment. Using the\n/v1/payment_methods/:id/attach endpoint does not ensure that future payments can be made with the attached PaymentMethod.\nSee Optimizing cards for future payments for more information about setting up future payments.

\n\n

To use this PaymentMethod as the default for invoice or subscription payments,\nset invoice_settings.default_payment_method,\non the Customer to the PaymentMethod’s ID.

", - "operationId": "PostPaymentMethodsPaymentMethodAttach", + "description": "

Updates the specified price by setting the values of the parameters passed. Any parameters not provided are left unchanged.

", + "operationId": "PostPricesPrice", "parameters": [ { "in": "path", - "name": "payment_method", + "name": "price", "required": true, "schema": { "maxLength": 5000, @@ -65049,17 +115104,109 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { + "currency_options": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "customer": { - "description": "The ID of the customer to which to attach the PaymentMethod.", - "maxLength": 5000, - "type": "string" + "active": { + "description": "Whether the price can be used for new purchases. Defaults to `true`.", + "type": "boolean" + }, + "currency_options": { + "anyOf": [ + { + "additionalProperties": { + "properties": { + "custom_unit_amount": { + "properties": { + "enabled": { + "type": "boolean" + }, + "maximum": { + "type": "integer" + }, + "minimum": { + "type": "integer" + }, + "preset": { + "type": "integer" + } + }, + "required": ["enabled"], + "title": "custom_unit_amount", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tiers": { + "items": { + "properties": { + "flat_amount": { + "type": "integer" + }, + "flat_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "up_to": { + "anyOf": [ + { + "enum": ["inf"], + "maxLength": 5000, + "type": "string" + }, + { + "type": "integer" + } + ] + } + }, + "required": ["up_to"], + "title": "tier", + "type": "object" + }, + "type": "array" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "currency_option", + "type": "object" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies)." }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -65068,73 +115215,40 @@ "type": "string" }, "type": "array" - } - }, - "required": ["customer"], - "type": "object" - } - } - }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/payment_method" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/payment_methods/{payment_method}/detach": { - "post": { - "description": "

Detaches a PaymentMethod object from a Customer.

", - "operationId": "PostPaymentMethodsPaymentMethodDetach", - "parameters": [ - { - "in": "path", - "name": "payment_method", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + }, + "lookup_key": { + "description": "A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.", + "maxLength": 200, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "nickname": { + "description": "A brief description of the price, hidden from customers.", + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "transfer_lookup_key": { + "description": "If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.", + "type": "boolean" } }, "type": "object" @@ -65148,7 +115262,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payment_method" + "$ref": "#/components/schemas/price" } } }, @@ -65167,44 +115281,23 @@ } } }, - "/v1/payouts": { + "/v1/products": { "get": { - "description": "

Returns a list of existing payouts sent to third-party bank accounts or that Stripe has sent you. The payouts are returned in sorted order, with the most recently created payouts appearing first.

", - "operationId": "GetPayouts", + "description": "

Returns a list of your products. The products are returned sorted by creation date, with the most recently created products appearing first.

", + "operationId": "GetProducts", "parameters": [ { - "explode": true, + "description": "Only return products that are active or inactive (e.g., pass `false` to list all inactive products).", "in": "query", - "name": "arrival_date", + "name": "active", "required": false, "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] + "type": "boolean" }, - "style": "deepObject" + "style": "form" }, { + "description": "Only return products that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -65237,31 +115330,36 @@ "style": "deepObject" }, { - "description": "The ID of an external account - only return payouts sent to this external account.", + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", - "name": "destination", + "name": "ending_before", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" }, { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "description": "Specifies which fields in the response should be expanded.", + "explode": true, "in": "query", - "name": "ending_before", + "name": "expand", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "style": "form" + "style": "deepObject" }, { - "description": "Specifies which fields in the response should be expanded.", + "description": "Only return products with the given IDs. Cannot be used with [starting_after](https://stripe.com/docs/api#list_products-starting_after) or [ending_before](https://stripe.com/docs/api#list_products-ending_before).", "explode": true, "in": "query", - "name": "expand", + "name": "ids", "required": false, "schema": { "items": { @@ -65282,6 +115380,16 @@ }, "style": "form" }, + { + "description": "Only return products that can be shipped (i.e., physical, not digital products).", + "in": "query", + "name": "shippable", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -65294,9 +115402,9 @@ "style": "form" }, { - "description": "Only return payouts that have the given status: `pending`, `paid`, `failed`, or `canceled`.", + "description": "Only return products with the given url.", "in": "query", - "name": "status", + "name": "url", "required": false, "schema": { "maxLength": 5000, @@ -65310,6 +115418,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -65325,8 +115434,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/payout" + "$ref": "#/components/schemas/product" }, "type": "array" }, @@ -65342,12 +115452,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/payouts", + "pattern": "^/v1/products", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "PayoutList", + "title": "ProductList", "type": "object", "x-expandableFields": ["data"] } @@ -65368,38 +115478,158 @@ } }, "post": { - "description": "

To send funds to your own bank account, you create a new payout object. Your Stripe balance must be able to cover the payout amount, or you’ll receive an “Insufficient Funds” error.

\n\n

If your API key is in test mode, money won’t actually be sent, though everything else will occur as if in live mode.

\n\n

If you are creating a manual payout on a Stripe account that uses multiple payment source types, you’ll need to specify the source type balance that the payout should draw from. The balance object details available and pending amounts by source type.

", - "operationId": "PostPayouts", + "description": "

Creates a new product object.

", + "operationId": "PostProducts", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { + "default_price_data": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" }, + "images": { + "explode": true, + "style": "deepObject" + }, + "marketing_features": { + "explode": true, + "style": "deepObject" + }, "metadata": { "explode": true, "style": "deepObject" + }, + "package_dimensions": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "amount": { - "description": "A positive integer in cents representing how much to payout.", - "type": "integer" + "active": { + "description": "Whether the product is currently available for purchase. Defaults to `true`.", + "type": "boolean" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" + "default_price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object. This Price will be set as the default price for this product.", + "properties": { + "currency": { + "type": "string" + }, + "currency_options": { + "additionalProperties": { + "properties": { + "custom_unit_amount": { + "properties": { + "enabled": { + "type": "boolean" + }, + "maximum": { + "type": "integer" + }, + "minimum": { + "type": "integer" + }, + "preset": { + "type": "integer" + } + }, + "required": ["enabled"], + "title": "custom_unit_amount", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tiers": { + "items": { + "properties": { + "flat_amount": { + "type": "integer" + }, + "flat_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "up_to": { + "anyOf": [ + { + "enum": ["inf"], + "maxLength": 5000, + "type": "string" + }, + { + "type": "integer" + } + ] + } + }, + "required": ["up_to"], + "title": "tier", + "type": "object" + }, + "type": "array" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "currency_option", + "type": "object" + }, + "type": "object" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency"], + "title": "price_data_without_product", + "type": "object" }, "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 5000, - "type": "string" - }, - "destination": { - "description": "The ID of a bank account or a card to send the payout to. If no destination is supplied, the default external account for the specified currency will be used.", + "description": "The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.", + "maxLength": 40000, "type": "string" }, "expand": { @@ -65410,6 +115640,33 @@ }, "type": "array" }, + "id": { + "description": "An identifier will be randomly generated by Stripe. You can optionally override this ID, but the ID must be unique across all products in your Stripe account.", + "maxLength": 5000, + "type": "string" + }, + "images": { + "description": "A list of up to 8 URLs of images for this product, meant to be displayable to the customer.", + "items": { + "type": "string" + }, + "type": "array" + }, + "marketing_features": { + "description": "A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).", + "items": { + "properties": { + "name": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["name"], + "title": "features", + "type": "object" + }, + "type": "array" + }, "metadata": { "additionalProperties": { "type": "string" @@ -65417,28 +115674,56 @@ "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" }, - "method": { - "description": "The method used to send this payout, which can be `standard` or `instant`. `instant` is only supported for payouts to debit cards. (See [Instant payouts for marketplaces for more information](https://stripe.com/blog/instant-payouts-for-marketplaces).)", - "enum": ["instant", "standard"], + "name": { + "description": "The product's name, meant to be displayable to the customer.", "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" }, - "source_type": { - "description": "The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the balances API. One of `bank_account`, `card`, or `fpx`.", - "enum": ["bank_account", "card", "fpx"], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "package_dimensions": { + "description": "The dimensions of this product for shipping purposes.", + "properties": { + "height": { + "type": "number" + }, + "length": { + "type": "number" + }, + "weight": { + "type": "number" + }, + "width": { + "type": "number" + } + }, + "required": ["height", "length", "weight", "width"], + "title": "package_dimensions_specs", + "type": "object" + }, + "shippable": { + "description": "Whether this product is shipped (i.e., physical goods).", + "type": "boolean" }, "statement_descriptor": { - "description": "A string to be displayed on the recipient's bank or card statement. This may be at most 22 characters. Attempting to use a `statement_descriptor` longer than 22 characters will return an error. Note: Most banks will truncate this information and/or display it inconsistently. Some may not display it at all.", + "description": "An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.\n\nThis may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `\"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.\n It must contain at least one letter. Only used for subscription payments.", "maxLength": 22, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" + }, + "tax_code": { + "description": "A [tax code](https://stripe.com/docs/tax/tax-categories) ID.", + "type": "string" + }, + "unit_label": { + "description": "A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.", + "maxLength": 12, + "type": "string" + }, + "url": { + "description": "A URL of a publicly-accessible webpage for this product.", + "maxLength": 5000, + "type": "string" } }, - "required": ["amount", "currency"], + "required": ["name"], "type": "object" } } @@ -65450,7 +115735,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payout" + "$ref": "#/components/schemas/product" } } }, @@ -65469,10 +115754,10 @@ } } }, - "/v1/payouts/{payout}": { + "/v1/products/search": { "get": { - "description": "

Retrieves the details of an existing payout. Supply the unique payout ID from either a payout creation request or the payout list, and Stripe will return the corresponding payout information.

", - "operationId": "GetPayoutsPayout", + "description": "

Search for products you’ve previously created using Stripe’s Search Query Language.\nDon’t use search in read-after-write flows where strict consistency is necessary. Under normal operating\nconditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up\nto an hour behind during outages. Search functionality is not available to merchants in India.

", + "operationId": "GetProductsSearch", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -65490,14 +115775,36 @@ "style": "deepObject" }, { - "in": "path", - "name": "payout", + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.", + "in": "query", + "name": "page", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for products](https://stripe.com/docs/search#query-fields-for-products).", + "in": "query", + "name": "query", "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" } ], "requestBody": { @@ -65505,6 +115812,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -65517,7 +115825,40 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payout" + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/product" + }, + "type": "array" + }, + "has_more": { + "type": "boolean" + }, + "next_page": { + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["search_result"], + "type": "string" + }, + "total_count": { + "description": "The total number of objects that match the query, only accurate up to 10,000.", + "type": "integer" + }, + "url": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SearchResult", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -65534,14 +115875,16 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates the specified payout by setting the values of the parameters passed. Any parameters not provided will be left unchanged. This request accepts only the metadata as arguments.

", - "operationId": "PostPayoutsPayout", + } + }, + "/v1/products/{id}": { + "delete": { + "description": "

Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.

", + "operationId": "DeleteProductsId", "parameters": [ { "in": "path", - "name": "payout", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -65553,42 +115896,10 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -65600,7 +115911,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payout" + "$ref": "#/components/schemas/deleted_product" } } }, @@ -65617,16 +115928,29 @@ "description": "Error response." } } - } - }, - "/v1/payouts/{payout}/cancel": { - "post": { - "description": "

A previously created payout can be canceled if it has not yet been paid out. Funds will be refunded to your available balance. You may not cancel automatic Stripe payouts.

", - "operationId": "PostPayoutsPayoutCancel", + }, + "get": { + "description": "

Retrieves the details of an existing product. Supply the unique product ID from either a product creation request or the product list, and Stripe will return the corresponding product information.

", + "operationId": "GetProductsId", "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, { "in": "path", - "name": "payout", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -65634,27 +115958,14 @@ }, "style": "simple" } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -65666,7 +115977,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payout" + "$ref": "#/components/schemas/product" } } }, @@ -65683,16 +115994,14 @@ "description": "Error response." } } - } - }, - "/v1/payouts/{payout}/reverse": { + }, "post": { - "description": "

Reverses a payout by debiting the destination bank account. Only payouts for connected accounts to US bank accounts may be reversed at this time. If the payout is in the pending status, /v1/payouts/:id/cancel should be used instead.

\n\n

By requesting a reversal via /v1/payouts/:id/reverse, you confirm that the authorized signatory of the selected bank account has authorized the debit on the bank account and that no other authorization is required.

", - "operationId": "PostPayoutsPayoutReverse", + "description": "

Updates the specific product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", + "operationId": "PostProductsId", "parameters": [ { "in": "path", - "name": "payout", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -65705,17 +116014,68 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { + "description": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" }, + "images": { + "explode": true, + "style": "deepObject" + }, + "marketing_features": { + "explode": true, + "style": "deepObject" + }, "metadata": { "explode": true, "style": "deepObject" + }, + "package_dimensions": { + "explode": true, + "style": "deepObject" + }, + "tax_code": { + "explode": true, + "style": "deepObject" + }, + "unit_label": { + "explode": true, + "style": "deepObject" + }, + "url": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { + "active": { + "description": "Whether the product is available for purchase.", + "type": "boolean" + }, + "default_price": { + "description": "The ID of the [Price](https://stripe.com/docs/api/prices) object that is the default price for this product.", + "maxLength": 5000, + "type": "string" + }, + "description": { + "anyOf": [ + { + "maxLength": 40000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes." + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -65724,12 +116084,137 @@ }, "type": "array" }, + "images": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A list of up to 8 URLs of images for this product, meant to be displayable to the customer." + }, + "marketing_features": { + "anyOf": [ + { + "items": { + "properties": { + "name": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["name"], + "title": "features", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table)." + }, "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "name": { + "description": "The product's name, meant to be displayable to the customer.", + "maxLength": 5000, + "type": "string" + }, + "package_dimensions": { + "anyOf": [ + { + "properties": { + "height": { + "type": "number" + }, + "length": { + "type": "number" + }, + "weight": { + "type": "number" + }, + "width": { + "type": "number" + } + }, + "required": ["height", "length", "weight", "width"], + "title": "package_dimensions_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The dimensions of this product for shipping purposes." + }, + "shippable": { + "description": "Whether this product is shipped (i.e., physical goods).", + "type": "boolean" + }, + "statement_descriptor": { + "description": "An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.\n\nThis may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `\"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.\n It must contain at least one letter. May only be set if `type=service`. Only used for subscription payments.", + "maxLength": 22, + "type": "string" + }, + "tax_code": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A [tax code](https://stripe.com/docs/tax/tax-categories) ID." + }, + "unit_label": { + "anyOf": [ + { + "maxLength": 12, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal. May only be set if `type=service`." + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A URL of a publicly-accessible webpage for this product." } }, "type": "object" @@ -65743,7 +116228,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/payout" + "$ref": "#/components/schemas/product" } } }, @@ -65762,54 +116247,11 @@ } } }, - "/v1/plans": { + "/v1/products/{product}/features": { "get": { - "description": "

Returns a list of your plans.

", - "operationId": "GetPlans", + "description": "

Retrieve a list of features for a product

", + "operationId": "GetProductsProductFeatures", "parameters": [ - { - "description": "Only return plans that are active or inactive (e.g., pass `false` to list all inactive plans).", - "in": "query", - "name": "active", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, - { - "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -65847,15 +116289,14 @@ "style": "form" }, { - "description": "Only return plans for the given product.", - "in": "query", + "in": "path", "name": "product", - "required": false, + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", @@ -65874,6 +116315,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -65889,9 +116331,8 @@ "description": "", "properties": { "data": { - "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/plan" + "$ref": "#/components/schemas/product_feature" }, "type": "array" }, @@ -65907,12 +116348,11 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/plans", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "PlanList", + "title": "EntitlementsResourceProductFeatureList", "type": "object", "x-expandableFields": ["data"] } @@ -65933,8 +116373,20 @@ } }, "post": { - "description": "

You can now model subscriptions more flexibly using the Prices API. It replaces the Plans API and is backwards compatible to simplify your migration.

", - "operationId": "PostPlans", + "description": "

Creates a product_feature, which represents a feature attachment to a product

", + "operationId": "PostProductsProductFeatures", + "parameters": [ + { + "in": "path", + "name": "product", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -65942,51 +116394,14 @@ "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "product": { - "explode": true, - "style": "deepObject" - }, - "tiers": { - "explode": true, - "style": "deepObject" - }, - "transform_usage": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Whether the plan is currently available for new subscriptions. Defaults to `true`.", - "type": "boolean" - }, - "aggregate_usage": { - "description": "Specifies a usage aggregation strategy for plans of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`.", - "enum": ["last_during_period", "last_ever", "max", "sum"], - "type": "string" - }, - "amount": { - "description": "A positive integer in %s (or 0 for a free plan) representing how much to charge on a recurring basis.", - "type": "integer" - }, - "amount_decimal": { - "description": "Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set.", - "format": "decimal", - "type": "string" - }, - "billing_scheme": { - "description": "Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.", - "enum": ["per_unit", "tiered"], - "type": "string" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "entitlement_feature": { + "description": "The ID of the [Feature](https://stripe.com/docs/api/entitlements/feature) object attached to this product.", + "maxLength": 5000, "type": "string" }, "expand": { @@ -65996,151 +116411,9 @@ "type": "string" }, "type": "array" - }, - "id": { - "description": "An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes.", - "maxLength": 5000, - "type": "string" - }, - "interval": { - "description": "Specifies billing frequency. Either `day`, `week`, `month` or `year`.", - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "description": "The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).", - "type": "integer" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "nickname": { - "description": "A brief description of the plan, hidden from customers.", - "maxLength": 5000, - "type": "string" - }, - "product": { - "anyOf": [ - { - "description": "The product whose pricing the created plan will represent. This can either be the ID of an existing product, or a dictionary containing fields used to create a [service product](https://stripe.com/docs/api#product_object-type).", - "properties": { - "active": { - "type": "boolean" - }, - "id": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "statement_descriptor": { - "maxLength": 22, - "type": "string" - }, - "unit_label": { - "maxLength": 12, - "type": "string" - } - }, - "required": ["name"], - "title": "inline_product_params", - "type": "object" - }, - { - "description": "The ID of the product whose pricing the created plan will represent.", - "maxLength": 5000, - "type": "string" - } - ] - }, - "tiers": { - "description": "Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.", - "items": { - "properties": { - "flat_amount": { - "type": "integer" - }, - "flat_amount_decimal": { - "format": "decimal", - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - }, - "up_to": { - "anyOf": [ - { - "enum": ["inf"], - "maxLength": 5000, - "type": "string" - }, - { - "type": "integer" - } - ] - } - }, - "required": ["up_to"], - "title": "tier", - "type": "object" - }, - "type": "array" - }, - "tiers_mode": { - "description": "Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.", - "enum": ["graduated", "volume"], - "type": "string" - }, - "transform_usage": { - "description": "Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.", - "properties": { - "divide_by": { - "type": "integer" - }, - "round": { - "enum": ["down", "up"], - "type": "string" - } - }, - "required": ["divide_by", "round"], - "title": "transform_usage_param", - "type": "object" - }, - "trial_period_days": { - "description": "Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).", - "type": "integer" - }, - "usage_type": { - "description": "Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.", - "enum": ["licensed", "metered"], - "type": "string" } }, - "required": ["currency", "interval"], + "required": ["entitlement_feature"], "type": "object" } } @@ -66152,7 +116425,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/plan" + "$ref": "#/components/schemas/product_feature" } } }, @@ -66171,14 +116444,24 @@ } } }, - "/v1/plans/{plan}": { + "/v1/products/{product}/features/{id}": { "delete": { - "description": "

Deleting plans means new subscribers can’t be added. Existing subscribers aren’t affected.

", - "operationId": "DeletePlansPlan", + "description": "

Deletes the feature attachment to a product

", + "operationId": "DeleteProductsProductFeaturesId", "parameters": [ { "in": "path", - "name": "plan", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "product", "required": true, "schema": { "maxLength": 5000, @@ -66192,6 +116475,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -66204,7 +116488,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_plan" + "$ref": "#/components/schemas/deleted_product_feature" } } }, @@ -66223,8 +116507,8 @@ } }, "get": { - "description": "

Retrieves the plan with the given ID.

", - "operationId": "GetPlansPlan", + "description": "

Retrieves a product_feature, which represents a feature attachment to a product

", + "operationId": "GetProductsProductFeaturesId", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -66242,58 +116526,20 @@ "style": "deepObject" }, { + "description": "The ID of the product_feature.", "in": "path", - "name": "plan", + "name": "id", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/plan" - } - } - }, - "description": "Successful response." }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates the specified plan by setting the values of the parameters passed. Any parameters not provided are left unchanged. By design, you cannot change a plan’s ID, amount, currency, or billing cycle.

", - "operationId": "PostPlansPlan", - "parameters": [ { + "description": "The ID of the product.", "in": "path", - "name": "plan", + "name": "product", "required": true, "schema": { "maxLength": 5000, @@ -66305,60 +116551,10 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "active": { - "description": "Whether the plan is currently available for new subscriptions.", - "type": "boolean" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "nickname": { - "description": "A brief description of the plan, hidden from customers.", - "maxLength": 5000, - "type": "string" - }, - "product": { - "description": "The product the plan belongs to. This cannot be changed once it has been used in a subscription or subscription schedule.", - "maxLength": 5000, - "type": "string" - }, - "trial_period_days": { - "description": "Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).", - "type": "integer" - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -66370,7 +116566,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/plan" + "$ref": "#/components/schemas/product_feature" } } }, @@ -66389,13 +116585,13 @@ } } }, - "/v1/prices": { + "/v1/promotion_codes": { "get": { - "description": "

Returns a list of your prices.

", - "operationId": "GetPrices", + "description": "

Returns a list of your promotion codes.

", + "operationId": "GetPromotionCodes", "parameters": [ { - "description": "Only return prices that are active or inactive (e.g., pass `false` to list all inactive prices).", + "description": "Filter promotion codes by whether they are active.", "in": "query", "name": "active", "required": false, @@ -66404,6 +116600,28 @@ }, "style": "form" }, + { + "description": "Only return promotion codes that have this case-insensitive code.", + "in": "query", + "name": "code", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return promotion codes for this coupon.", + "in": "query", + "name": "coupon", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", "explode": true, @@ -66438,11 +116656,12 @@ "style": "deepObject" }, { - "description": "Only return prices for the given currency.", + "description": "Only return promotion codes that are restricted to this customer.", "in": "query", - "name": "currency", + "name": "customer", "required": false, "schema": { + "maxLength": 5000, "type": "string" }, "style": "form" @@ -66483,54 +116702,6 @@ }, "style": "form" }, - { - "description": "Only return the price with these lookup_keys, if any exist.", - "explode": true, - "in": "query", - "name": "lookup_keys", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "Only return prices for the given product.", - "in": "query", - "name": "product", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return prices with these recurring fields.", - "explode": true, - "in": "query", - "name": "recurring", - "required": false, - "schema": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "usage_type": { - "enum": ["licensed", "metered"], - "type": "string" - } - }, - "title": "all_prices_recurring_params", - "type": "object" - }, - "style": "deepObject" - }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -66541,17 +116712,6 @@ "type": "string" }, "style": "form" - }, - { - "description": "Only return prices of type `recurring` or `one_time`.", - "in": "query", - "name": "type", - "required": false, - "schema": { - "enum": ["one_time", "recurring"], - "type": "string" - }, - "style": "form" } ], "requestBody": { @@ -66559,6 +116719,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -66574,9 +116735,8 @@ "description": "", "properties": { "data": { - "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/price" + "$ref": "#/components/schemas/promotion_code" }, "type": "array" }, @@ -66592,12 +116752,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/prices", + "pattern": "^/v1/promotion_codes", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "PriceList", + "title": "PromotionCodesResourcePromotionCodeList", "type": "object", "x-expandableFields": ["data"] } @@ -66618,8 +116778,8 @@ } }, "post": { - "description": "

Creates a new price for an existing product. The price can be recurring or one-time.

", - "operationId": "PostPrices", + "description": "

A promotion code points to a coupon. You can optionally restrict the code to a specific customer, redemption limit, and expiration date.

", + "operationId": "PostPromotionCodes", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -66632,36 +116792,31 @@ "explode": true, "style": "deepObject" }, - "product_data": { - "explode": true, - "style": "deepObject" - }, - "recurring": { - "explode": true, - "style": "deepObject" - }, - "tiers": { - "explode": true, - "style": "deepObject" - }, - "transform_quantity": { + "restrictions": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "active": { - "description": "Whether the price can be used for new purchases. Defaults to `true`.", + "description": "Whether the promotion code is currently active.", "type": "boolean" }, - "billing_scheme": { - "description": "Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.", - "enum": ["per_unit", "tiered"], + "code": { + "description": "The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for a specific customer. If left blank, we will generate one automatically.", + "maxLength": 500, "type": "string" }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "coupon": { + "description": "The coupon for this promotion code.", + "maxLength": 5000, + "type": "string" + }, + "customer": { + "description": "The customer that this promotion code can be used by. If not set, the promotion code can be used by all customers.", + "maxLength": 5000, "type": "string" }, "expand": { @@ -66672,10 +116827,14 @@ }, "type": "array" }, - "lookup_key": { - "description": "A lookup key used to retrieve prices dynamically from a static string.", - "maxLength": 5000, - "type": "string" + "expires_at": { + "description": "The timestamp at which this promotion code will expire. If the coupon has specified a `redeems_by`, then this value cannot be after the coupon's `redeems_by`.", + "format": "unix-time", + "type": "integer" + }, + "max_redemptions": { + "description": "A positive integer specifying the number of times the promotion code can be redeemed. If the coupon has specified a `max_redemptions`, then this value cannot be greater than the coupon's `max_redemptions`.", + "type": "integer" }, "metadata": { "additionalProperties": { @@ -66684,149 +116843,36 @@ "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" }, - "nickname": { - "description": "A brief description of the price, hidden from customers.", - "maxLength": 5000, - "type": "string" - }, - "product": { - "description": "The ID of the product that this price will belong to.", - "maxLength": 5000, - "type": "string" - }, - "product_data": { - "description": "These fields can be used to create a new product that this price will belong to.", + "restrictions": { + "description": "Settings that restrict the redemption of the promotion code.", "properties": { - "active": { - "type": "boolean" - }, - "id": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { + "currency_options": { "additionalProperties": { - "type": "string" + "properties": { + "minimum_amount": { + "type": "integer" + } + }, + "title": "currency_option", + "type": "object" }, "type": "object" }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "statement_descriptor": { - "maxLength": 22, - "type": "string" - }, - "unit_label": { - "maxLength": 12, - "type": "string" - } - }, - "required": ["name"], - "title": "inline_product_params", - "type": "object" - }, - "recurring": { - "description": "The recurring components of a price such as `interval` and `usage_type`.", - "properties": { - "aggregate_usage": { - "enum": [ - "last_during_period", - "last_ever", - "max", - "sum" - ], - "type": "string" - }, - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - }, - "usage_type": { - "enum": ["licensed", "metered"], - "type": "string" - } - }, - "required": ["interval"], - "title": "recurring", - "type": "object" - }, - "tiers": { - "description": "Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.", - "items": { - "properties": { - "flat_amount": { - "type": "integer" - }, - "flat_amount_decimal": { - "format": "decimal", - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - }, - "up_to": { - "anyOf": [ - { - "enum": ["inf"], - "maxLength": 5000, - "type": "string" - }, - { - "type": "integer" - } - ] - } + "first_time_transaction": { + "type": "boolean" }, - "required": ["up_to"], - "title": "tier", - "type": "object" - }, - "type": "array" - }, - "tiers_mode": { - "description": "Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.", - "enum": ["graduated", "volume"], - "type": "string" - }, - "transfer_lookup_key": { - "description": "If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.", - "type": "boolean" - }, - "transform_quantity": { - "description": "Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.", - "properties": { - "divide_by": { + "minimum_amount": { "type": "integer" }, - "round": { - "enum": ["down", "up"], + "minimum_amount_currency": { "type": "string" } }, - "required": ["divide_by", "round"], - "title": "transform_usage_param", + "title": "restrictions_params", "type": "object" - }, - "unit_amount": { - "description": "A positive integer in %s (or 0 for a free price) representing how much to charge.", - "type": "integer" - }, - "unit_amount_decimal": { - "description": "Same as `unit_amount`, but accepts a decimal value in %s with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", - "format": "decimal", - "type": "string" } }, - "required": ["currency"], + "required": ["coupon"], "type": "object" } } @@ -66838,7 +116884,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/price" + "$ref": "#/components/schemas/promotion_code" } } }, @@ -66857,10 +116903,10 @@ } } }, - "/v1/prices/{price}": { + "/v1/promotion_codes/{promotion_code}": { "get": { - "description": "

Retrieves the price with the given ID.

", - "operationId": "GetPricesPrice", + "description": "

Retrieves the promotion code with the given ID. In order to retrieve a promotion code by the customer-facing code use list with the desired code.

", + "operationId": "GetPromotionCodesPromotionCode", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -66879,7 +116925,7 @@ }, { "in": "path", - "name": "price", + "name": "promotion_code", "required": true, "schema": { "maxLength": 5000, @@ -66893,6 +116939,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -66905,7 +116952,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/price" + "$ref": "#/components/schemas/promotion_code" } } }, @@ -66924,12 +116971,12 @@ } }, "post": { - "description": "

Updates the specified price by setting the values of the parameters passed. Any parameters not provided are left unchanged.

", - "operationId": "PostPricesPrice", + "description": "

Updates the specified promotion code by setting the values of the parameters passed. Most fields are, by design, not editable.

", + "operationId": "PostPromotionCodesPromotionCode", "parameters": [ { "in": "path", - "name": "price", + "name": "promotion_code", "required": true, "schema": { "maxLength": 5000, @@ -66949,12 +116996,17 @@ "metadata": { "explode": true, "style": "deepObject" + }, + "restrictions": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "active": { - "description": "Whether the price can be used for new purchases. Defaults to `true`.", + "description": "Whether the promotion code is currently active. A promotion code can only be reactivated when the coupon is still valid and the promotion code is otherwise redeemable.", "type": "boolean" }, "expand": { @@ -66965,11 +117017,6 @@ }, "type": "array" }, - "lookup_key": { - "description": "A lookup key used to retrieve prices dynamically from a static string.", - "maxLength": 5000, - "type": "string" - }, "metadata": { "anyOf": [ { @@ -66985,14 +117032,24 @@ ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "nickname": { - "description": "A brief description of the price, hidden from customers.", - "maxLength": 5000, - "type": "string" - }, - "transfer_lookup_key": { - "description": "If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.", - "type": "boolean" + "restrictions": { + "description": "Settings that restrict the redemption of the promotion code.", + "properties": { + "currency_options": { + "additionalProperties": { + "properties": { + "minimum_amount": { + "type": "integer" + } + }, + "title": "currency_option", + "type": "object" + }, + "type": "object" + } + }, + "title": "restrictions_params", + "type": "object" } }, "type": "object" @@ -67006,7 +117063,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/price" + "$ref": "#/components/schemas/promotion_code" } } }, @@ -67025,54 +117082,22 @@ } } }, - "/v1/products": { + "/v1/quotes": { "get": { - "description": "

Returns a list of your products. The products are returned sorted by creation date, with the most recently created products appearing first.

", - "operationId": "GetProducts", + "description": "

Returns a list of your quotes.

", + "operationId": "GetQuotes", "parameters": [ { - "description": "Only return products that are active or inactive (e.g., pass `false` to list all inactive products).", + "description": "The ID of the customer whose quotes will be retrieved.", "in": "query", - "name": "active", + "name": "customer", "required": false, "schema": { - "type": "boolean" + "maxLength": 5000, + "type": "string" }, "style": "form" }, - { - "description": "Only return products that were created during the given date interval.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -67099,21 +117124,6 @@ }, "style": "deepObject" }, - { - "description": "Only return products with the given IDs.", - "explode": true, - "in": "query", - "name": "ids", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, { "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", @@ -67125,30 +117135,32 @@ "style": "form" }, { - "description": "Only return products that can be shipped (i.e., physical, not digital products).", + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", - "name": "shippable", + "name": "starting_after", "required": false, "schema": { - "type": "boolean" + "maxLength": 5000, + "type": "string" }, "style": "form" }, { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "The status of the quote.", "in": "query", - "name": "starting_after", + "name": "status", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "enum": ["accepted", "canceled", "draft", "open"], + "type": "string", + "x-stripeBypassValidation": true }, "style": "form" }, { - "description": "Only return products with the given url.", + "description": "Provides a list of quotes that are associated with the specified test clock. The response will not include quotes with test clocks if this and the customer parameter is not set.", "in": "query", - "name": "url", + "name": "test_clock", "required": false, "schema": { "maxLength": 5000, @@ -67162,6 +117174,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -67178,7 +117191,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/product" + "$ref": "#/components/schemas/quote" }, "type": "array" }, @@ -67194,11 +117207,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/products", + "pattern": "^/v1/quotes", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "QuotesResourceQuoteList", "type": "object", "x-expandableFields": ["data"] } @@ -67219,40 +117233,198 @@ } }, "post": { - "description": "

Creates a new product object.

", - "operationId": "PostProducts", + "description": "

A quote models prices and services for a customer. Default options for header, description, footer, and expires_at can be set in the dashboard via the quote template.

", + "operationId": "PostQuotes", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { + "application_fee_amount": { + "explode": true, + "style": "deepObject" + }, + "application_fee_percent": { + "explode": true, + "style": "deepObject" + }, + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "default_tax_rates": { + "explode": true, + "style": "deepObject" + }, + "description": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" }, - "images": { + "footer": { + "explode": true, + "style": "deepObject" + }, + "from_quote": { + "explode": true, + "style": "deepObject" + }, + "header": { + "explode": true, + "style": "deepObject" + }, + "invoice_settings": { + "explode": true, + "style": "deepObject" + }, + "line_items": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "on_behalf_of": { "explode": true, "style": "deepObject" }, - "metadata": { + "subscription_data": { "explode": true, "style": "deepObject" }, - "package_dimensions": { + "transfer_data": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Whether the product is currently available for purchase. Defaults to `true`.", - "type": "boolean" + "application_fee_amount": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field." }, - "description": { - "description": "The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.", - "maxLength": 40000, + "application_fee_percent": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field." + }, + "automatic_tax": { + "description": "Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_param", + "type": "object" + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "customer": { + "description": "The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.", + "maxLength": 5000, "type": "string" }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The tax rates that will apply to any line item that does not have `tax_rates` set." + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A description that will be displayed on the quote PDF. If no value is passed, the default description configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The discounts applied to the quote. You can only set up to one discount." + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -67261,15 +117433,173 @@ }, "type": "array" }, - "id": { - "description": "An identifier will be randomly generated by Stripe. You can optionally override this ID, but the ID must be unique across all products in your Stripe account.", - "maxLength": 5000, - "type": "string" + "expires_at": { + "description": "A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch. If no value is passed, the default expiration date configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.", + "format": "unix-time", + "type": "integer" }, - "images": { - "description": "A list of up to 8 URLs of images for this product, meant to be displayable to the customer.", + "footer": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A footer that will be displayed on the quote PDF. If no value is passed, the default footer configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used." + }, + "from_quote": { + "description": "Clone an existing quote. The new quote will be created in `status=draft`. When using this parameter, you cannot specify any other parameters except for `expires_at`.", + "properties": { + "is_revision": { + "type": "boolean" + }, + "quote": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["quote"], + "title": "from_quote_params", + "type": "object" + }, + "header": { + "anyOf": [ + { + "maxLength": 50, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A header that will be displayed on the quote PDF. If no value is passed, the default header configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used." + }, + "invoice_settings": { + "description": "All invoices will be billed using the specified settings.", + "properties": { + "days_until_due": { + "type": "integer" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "quote_param", + "type": "object" + }, + "line_items": { + "description": "A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.", "items": { - "type": "string" + "properties": { + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "line_item_create_params", + "type": "object" }, "type": "array" }, @@ -67280,64 +117610,106 @@ "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" }, - "name": { - "description": "The product's name, meant to be displayable to the customer. Whenever this product is sold via a subscription, name will show up on associated invoice line item descriptions.", - "maxLength": 5000, - "type": "string" + "on_behalf_of": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The account on behalf of which to charge." }, - "package_dimensions": { - "description": "The dimensions of this product for shipping purposes.", + "subscription_data": { + "description": "When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.", "properties": { - "height": { - "type": "number" + "description": { + "maxLength": 500, + "type": "string" }, - "length": { - "type": "number" + "effective_date": { + "anyOf": [ + { + "enum": ["current_period_end"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] }, - "weight": { - "type": "number" + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" }, - "width": { - "type": "number" + "trial_period_days": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] } }, - "required": ["height", "length", "weight", "width"], - "title": "package_dimensions_specs", + "title": "subscription_data_create_params", "type": "object" }, - "shippable": { - "description": "Whether this product is shipped (i.e., physical goods).", - "type": "boolean" - }, - "statement_descriptor": { - "description": "An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.\n\nThis may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `\"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.\n It must contain at least one letter.", - "maxLength": 22, - "type": "string" - }, - "unit_label": { - "description": "A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions.", - "maxLength": 12, - "type": "string" - }, - "url": { - "description": "A URL of a publicly-accessible webpage for this product.", + "test_clock": { + "description": "ID of the test clock to attach to the quote.", "maxLength": 5000, "type": "string" + }, + "transfer_data": { + "anyOf": [ + { + "properties": { + "amount": { + "type": "integer" + }, + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The data with which to automatically create a Transfer for each of the invoices." } }, - "required": ["name"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/product" + "$ref": "#/components/schemas/quote" } } }, @@ -67356,60 +117728,10 @@ } } }, - "/v1/products/{id}": { - "delete": { - "description": "

Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.

", - "operationId": "DeleteProductsId", - "parameters": [ - { - "in": "path", - "name": "id", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/deleted_product" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, + "/v1/quotes/{quote}": { "get": { - "description": "

Retrieves the details of an existing product. Supply the unique product ID from either a product creation request or the product list, and Stripe will return the corresponding product information.

", - "operationId": "GetProductsId", + "description": "

Retrieves the quote with the given ID.

", + "operationId": "GetQuotesQuote", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -67428,7 +117750,7 @@ }, { "in": "path", - "name": "id", + "name": "quote", "required": true, "schema": { "maxLength": 5000, @@ -67442,6 +117764,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -67454,7 +117777,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/product" + "$ref": "#/components/schemas/quote" } } }, @@ -67473,12 +117796,12 @@ } }, "post": { - "description": "

Updates the specific product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostProductsId", + "description": "

A quote models prices and services for a customer.

", + "operationId": "PostQuotesQuote", "parameters": [ { "in": "path", - "name": "id", + "name": "quote", "required": true, "schema": { "maxLength": 5000, @@ -67491,11 +117814,47 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { + "application_fee_amount": { + "explode": true, + "style": "deepObject" + }, + "application_fee_percent": { + "explode": true, + "style": "deepObject" + }, + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "default_tax_rates": { + "explode": true, + "style": "deepObject" + }, + "description": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" }, - "images": { + "footer": { + "explode": true, + "style": "deepObject" + }, + "header": { + "explode": true, + "style": "deepObject" + }, + "invoice_settings": { + "explode": true, + "style": "deepObject" + }, + "line_items": { "explode": true, "style": "deepObject" }, @@ -67503,21 +117862,139 @@ "explode": true, "style": "deepObject" }, - "package_dimensions": { + "on_behalf_of": { + "explode": true, + "style": "deepObject" + }, + "subscription_data": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Whether the product is available for purchase.", - "type": "boolean" + "application_fee_amount": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field." + }, + "application_fee_percent": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field." + }, + "automatic_tax": { + "description": "Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_param", + "type": "object" + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "customer": { + "description": "The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.", + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The tax rates that will apply to any line item that does not have `tax_rates` set." }, "description": { - "description": "The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.", - "maxLength": 40000, - "type": "string" + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A description that will be displayed on the quote PDF." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The discounts applied to the quote. You can only set up to one discount." }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -67527,60 +118004,253 @@ }, "type": "array" }, - "images": { + "expires_at": { + "description": "A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + }, + "footer": { "anyOf": [ { - "items": { - "type": "string" - }, - "type": "array" + "maxLength": 500, + "type": "string" }, { "enum": [""], "type": "string" } ], - "description": "A list of up to 8 URLs of images for this product, meant to be displayable to the customer." + "description": "A footer that will be displayed on the quote PDF." }, - "metadata": { + "header": { "anyOf": [ { - "additionalProperties": { - "type": "string" + "maxLength": 50, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A header that will be displayed on the quote PDF." + }, + "invoice_settings": { + "description": "All invoices will be billed using the specified settings.", + "properties": { + "days_until_due": { + "type": "integer" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } }, + "required": ["type"], + "title": "param", "type": "object" + } + }, + "title": "quote_param", + "type": "object" + }, + "line_items": { + "description": "A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.", + "items": { + "properties": { + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "id": { + "maxLength": 5000, + "type": "string" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "line_item_update_params", + "type": "object" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "on_behalf_of": { + "anyOf": [ + { + "type": "string" }, { "enum": [""], "type": "string" } ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "description": "The account on behalf of which to charge." }, - "name": { - "description": "The product's name, meant to be displayable to the customer. Whenever this product is sold via a subscription, name will show up on associated invoice line item descriptions.", - "maxLength": 5000, - "type": "string" + "subscription_data": { + "description": "When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.", + "properties": { + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "effective_date": { + "anyOf": [ + { + "enum": ["current_period_end"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "trial_period_days": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "subscription_data_update_params", + "type": "object" }, - "package_dimensions": { + "transfer_data": { "anyOf": [ { "properties": { - "height": { - "type": "number" - }, - "length": { - "type": "number" + "amount": { + "type": "integer" }, - "weight": { + "amount_percent": { "type": "number" }, - "width": { - "type": "number" + "destination": { + "type": "string" } }, - "required": ["height", "length", "weight", "width"], - "title": "package_dimensions_specs", + "required": ["destination"], + "title": "transfer_data_specs", "type": "object" }, { @@ -67588,25 +118258,7 @@ "type": "string" } ], - "description": "The dimensions of this product for shipping purposes." - }, - "shippable": { - "description": "Whether this product is shipped (i.e., physical goods).", - "type": "boolean" - }, - "statement_descriptor": { - "description": "An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.\n\nThis may be up to 22 characters. The statement description may not include `<`, `>`, `\\`, `\"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.\n It must contain at least one letter. May only be set if `type=service`.", - "maxLength": 22, - "type": "string" - }, - "unit_label": { - "description": "A label that represents units of this product in Stripe and on customers’ receipts and invoices. When set, this will be included in associated invoice line item descriptions. May only be set if `type=service`.", - "maxLength": 12, - "type": "string" - }, - "url": { - "description": "A URL of a publicly-accessible webpage for this product.", - "type": "string" + "description": "The data with which to automatically create a Transfer for each of the invoices." } }, "type": "object" @@ -67620,7 +118272,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/product" + "$ref": "#/components/schemas/quote" } } }, @@ -67639,141 +118291,43 @@ } } }, - "/v1/promotion_codes": { - "get": { - "description": "

Returns a list of your promotion codes.

", - "operationId": "GetPromotionCodes", + "/v1/quotes/{quote}/accept": { + "post": { + "description": "

Accepts the specified quote.

", + "operationId": "PostQuotesQuoteAccept", "parameters": [ { - "description": "Filter promotion codes by whether they are active.", - "in": "query", - "name": "active", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, - { - "description": "Only return promotion codes that have this case-insensitive code.", - "in": "query", - "name": "code", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return promotion codes for this coupon.", - "in": "query", - "name": "coupon", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return promotion codes that are restricted to this customer.", - "in": "query", - "name": "customer", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, + "in": "path", + "name": "quote", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -67785,33 +118339,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/promotion_code" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/promotion_codes", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/quote" } } }, @@ -67828,10 +118356,24 @@ "description": "Error response." } } - }, + } + }, + "/v1/quotes/{quote}/cancel": { "post": { - "description": "

A promotion code points to a coupon. You can optionally restrict the code to a specific customer, redemption limit, and expiration date.

", - "operationId": "PostPromotionCodes", + "description": "

Cancels the quote.

", + "operationId": "PostQuotesQuoteCancel", + "parameters": [ + { + "in": "path", + "name": "quote", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -67839,91 +118381,32 @@ "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "restrictions": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Whether the promotion code is currently active.", - "type": "boolean" - }, - "code": { - "description": "The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for a specific customer. If left blank, we will generate one automatically.", - "maxLength": 500, - "type": "string" - }, - "coupon": { - "description": "The coupon for this promotion code.", - "maxLength": 5000, - "type": "string" - }, - "customer": { - "description": "The customer that this promotion code can be used by. If not set, the promotion code can be used by all customers.", - "maxLength": 5000, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "expires_at": { - "description": "The timestamp at which this promotion code will expire. If the coupon has specified a `redeems_by`, then this value cannot be after the coupon's `redeems_by`.", - "format": "unix-time", - "type": "integer" - }, - "max_redemptions": { - "description": "A positive integer specifying the number of times the promotion code can be redeemed. If the coupon has specified a `max_redemptions`, then this value cannot be greater than the coupon's `max_redemptions`.", - "type": "integer" - }, - "metadata": { - "additionalProperties": { + "maxLength": 5000, "type": "string" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "restrictions": { - "description": "Settings that restrict the redemption of the promotion code.", - "properties": { - "first_time_transaction": { - "type": "boolean" - }, - "minimum_amount": { - "type": "integer" - }, - "minimum_amount_currency": { - "type": "string" - } - }, - "title": "restrictions_params", - "type": "object" + "type": "array" } }, - "required": ["coupon"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/promotion_code" + "$ref": "#/components/schemas/quote" } } }, @@ -67942,11 +118425,22 @@ } } }, - "/v1/promotion_codes/{promotion_code}": { + "/v1/quotes/{quote}/computed_upfront_line_items": { "get": { - "description": "

Retrieves the promotion code with the given ID.

", - "operationId": "GetPromotionCodesPromotionCode", + "description": "

When retrieving a quote, there is an includable computed.upfront.line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of upfront line items.

", + "operationId": "GetQuotesQuoteComputedUpfrontLineItems", "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -67962,15 +118456,36 @@ }, "style": "deepObject" }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, { "in": "path", - "name": "promotion_code", + "name": "quote", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" } ], "requestBody": { @@ -67978,6 +118493,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -67990,7 +118506,34 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/promotion_code" + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "QuotesResourceListLineItems", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -68007,14 +118550,16 @@ "description": "Error response." } } - }, + } + }, + "/v1/quotes/{quote}/finalize": { "post": { - "description": "

Updates the specified promotion code by setting the values of the parameters passed. Most fields are, by design, not editable.

", - "operationId": "PostPromotionCodesPromotionCode", + "description": "

Finalizes the quote.

", + "operationId": "PostQuotesQuoteFinalize", "parameters": [ { "in": "path", - "name": "promotion_code", + "name": "quote", "required": true, "schema": { "maxLength": 5000, @@ -68030,18 +118575,11 @@ "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Whether the promotion code is currently active. A promotion code can only be reactivated when the coupon is still valid and the promotion code is otherwise redeemable.", - "type": "boolean" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -68050,20 +118588,10 @@ }, "type": "array" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "expires_at": { + "description": "A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" } }, "type": "object" @@ -68077,7 +118605,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/promotion_code" + "$ref": "#/components/schemas/quote" } } }, @@ -68096,21 +118624,11 @@ } } }, - "/v1/radar/early_fraud_warnings": { + "/v1/quotes/{quote}/line_items": { "get": { - "description": "

Returns a list of early fraud warnings.

", - "operationId": "GetRadarEarlyFraudWarnings", + "description": "

When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.

", + "operationId": "GetQuotesQuoteLineItems", "parameters": [ - { - "description": "Only return early fraud warnings for the charge specified by this charge ID.", - "in": "query", - "name": "charge", - "required": false, - "schema": { - "type": "string" - }, - "style": "form" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -68147,6 +118665,16 @@ }, "style": "form" }, + { + "in": "path", + "name": "quote", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -68164,6 +118692,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -68179,8 +118708,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/radar.early_fraud_warning" + "$ref": "#/components/schemas/item" }, "type": "array" }, @@ -68196,12 +118726,11 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/radar/early_fraud_warnings", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "RadarEarlyFraudWarningList", + "title": "QuotesResourceListLineItems", "type": "object", "x-expandableFields": ["data"] } @@ -68222,21 +118751,11 @@ } } }, - "/v1/radar/early_fraud_warnings/{early_fraud_warning}": { + "/v1/quotes/{quote}/pdf": { "get": { - "description": "

Retrieves the details of an early fraud warning that has previously been created.

\n\n

Please refer to the early fraud warning object reference for more details.

", - "operationId": "GetRadarEarlyFraudWarningsEarlyFraudWarning", + "description": "

Download the PDF for a finalized quote. Explanation for special handling can be found here

", + "operationId": "GetQuotesQuotePdf", "parameters": [ - { - "in": "path", - "name": "early_fraud_warning", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -68251,6 +118770,16 @@ "type": "array" }, "style": "deepObject" + }, + { + "in": "path", + "name": "quote", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" } ], "requestBody": { @@ -68258,6 +118787,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -68268,9 +118798,10 @@ "responses": { "200": { "content": { - "application/json": { + "application/pdf": { "schema": { - "$ref": "#/components/schemas/radar.early_fraud_warning" + "format": "binary", + "type": "string" } } }, @@ -68286,15 +118817,31 @@ }, "description": "Error response." } - } + }, + "servers": [ + { + "url": "https://files.stripe.com/" + } + ] } }, - "/v1/radar/value_list_items": { + "/v1/radar/early_fraud_warnings": { "get": { - "description": "

Returns a list of ValueListItem objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", - "operationId": "GetRadarValueListItems", + "description": "

Returns a list of early fraud warnings.

", + "operationId": "GetRadarEarlyFraudWarnings", "parameters": [ { + "description": "Only return early fraud warnings for the charge specified by this charge ID.", + "in": "query", + "name": "charge", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return early fraud warnings that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -68363,9 +118910,9 @@ "style": "form" }, { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "Only return early fraud warnings for charges that were created by the PaymentIntent specified by this PaymentIntent ID.", "in": "query", - "name": "starting_after", + "name": "payment_intent", "required": false, "schema": { "maxLength": 5000, @@ -68374,21 +118921,10 @@ "style": "form" }, { - "description": "Return items belonging to the parent list whose value matches the specified value (using an \"is like\" match).", + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", - "name": "value", + "name": "starting_after", "required": false, - "schema": { - "maxLength": 800, - "type": "string" - }, - "style": "form" - }, - { - "description": "Identifier for the parent value list this item belongs to.", - "in": "query", - "name": "value_list", - "required": true, "schema": { "maxLength": 5000, "type": "string" @@ -68401,6 +118937,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -68417,7 +118954,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/radar.value_list_item" + "$ref": "#/components/schemas/radar.early_fraud_warning" }, "type": "array" }, @@ -68433,11 +118970,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/radar/value_list_items", + "pattern": "^/v1/radar/early_fraud_warnings", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "RadarEarlyFraudWarningList", "type": "object", "x-expandableFields": ["data"] } @@ -68456,126 +118994,23 @@ "description": "Error response." } } - }, - "post": { - "description": "

Creates a new ValueListItem object, which is added to the specified parent value list.

", - "operationId": "PostRadarValueListItems", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "value": { - "description": "The value of the item (whose type must match the type of the parent value list).", - "maxLength": 800, - "type": "string" - }, - "value_list": { - "description": "The identifier of the value list which the created item will be added to.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["value", "value_list"], - "type": "object" - } - } - }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/radar.value_list_item" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } } }, - "/v1/radar/value_list_items/{item}": { - "delete": { - "description": "

Deletes a ValueListItem object, removing it from its parent value list.

", - "operationId": "DeleteRadarValueListItemsItem", + "/v1/radar/early_fraud_warnings/{early_fraud_warning}": { + "get": { + "description": "

Retrieves the details of an early fraud warning that has previously been created.

\n\n

Please refer to the early fraud warning object reference for more details.

", + "operationId": "GetRadarEarlyFraudWarningsEarlyFraudWarning", "parameters": [ { "in": "path", - "name": "item", + "name": "early_fraud_warning", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/deleted_radar.value_list_item" - } - } - }, - "description": "Successful response." }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "get": { - "description": "

Retrieves a ValueListItem object.

", - "operationId": "GetRadarValueListItemsItem", - "parameters": [ { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -68590,16 +119025,6 @@ "type": "array" }, "style": "deepObject" - }, - { - "in": "path", - "name": "item", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" } ], "requestBody": { @@ -68607,6 +119032,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -68619,7 +119045,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/radar.value_list_item" + "$ref": "#/components/schemas/radar.early_fraud_warning" } } }, @@ -68638,34 +119064,13 @@ } } }, - "/v1/radar/value_lists": { + "/v1/radar/value_list_items": { "get": { - "description": "

Returns a list of ValueList objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", - "operationId": "GetRadarValueLists", + "description": "

Returns a list of ValueListItem objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetRadarValueListItems", "parameters": [ { - "description": "The alias used to reference the value list when writing rules.", - "in": "query", - "name": "alias", - "required": false, - "schema": { - "maxLength": 100, - "type": "string" - }, - "style": "form" - }, - { - "description": "A value contained within a value list - returns all value lists containing this value.", - "in": "query", - "name": "contains", - "required": false, - "schema": { - "maxLength": 800, - "type": "string" - }, - "style": "form" - }, - { + "description": "Only return items that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -68743,6 +119148,28 @@ "type": "string" }, "style": "form" + }, + { + "description": "Return items belonging to the parent list whose value matches the specified value (using an \"is like\" match).", + "in": "query", + "name": "value", + "required": false, + "schema": { + "maxLength": 800, + "type": "string" + }, + "style": "form" + }, + { + "description": "Identifier for the parent value list this item belongs to.", + "in": "query", + "name": "value_list", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" } ], "requestBody": { @@ -68750,6 +119177,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -68766,7 +119194,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/radar.value_list" + "$ref": "#/components/schemas/radar.value_list_item" }, "type": "array" }, @@ -68782,11 +119210,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/radar/value_lists", + "pattern": "^/v1/radar/value_list_items", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "RadarListListItemList", "type": "object", "x-expandableFields": ["data"] } @@ -68807,8 +119236,8 @@ } }, "post": { - "description": "

Creates a new ValueList object, which can then be referenced in rules.

", - "operationId": "PostRadarValueLists", + "description": "

Creates a new ValueListItem object, which is added to the specified parent value list.

", + "operationId": "PostRadarValueListItems", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -68816,19 +119245,11 @@ "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "alias": { - "description": "The name of the value list for use in rules.", - "maxLength": 100, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -68837,34 +119258,18 @@ }, "type": "array" }, - "item_type": { - "description": "Type of the items in the value list. One of `card_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, or `case_sensitive_string`. Use `string` if the item type is unknown or mixed.", - "enum": [ - "card_bin", - "card_fingerprint", - "case_sensitive_string", - "country", - "email", - "ip_address", - "string" - ], - "maxLength": 5000, + "value": { + "description": "The value of the item (whose type must match the type of the parent value list).", + "maxLength": 800, "type": "string" }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "name": { - "description": "The human-readable name of the value list.", - "maxLength": 100, + "value_list": { + "description": "The identifier of the value list which the created item will be added to.", + "maxLength": 5000, "type": "string" } }, - "required": ["alias", "name"], + "required": ["value", "value_list"], "type": "object" } } @@ -68876,7 +119281,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/radar.value_list" + "$ref": "#/components/schemas/radar.value_list_item" } } }, @@ -68895,79 +119300,14 @@ } } }, - "/v1/radar/value_lists/{value_list}": { + "/v1/radar/value_list_items/{item}": { "delete": { - "description": "

Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.

", - "operationId": "DeleteRadarValueListsValueList", - "parameters": [ - { - "in": "path", - "name": "value_list", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/deleted_radar.value_list" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "get": { - "description": "

Retrieves a ValueList object.

", - "operationId": "GetRadarValueListsValueList", + "description": "

Deletes a ValueListItem object, removing it from its parent value list.

", + "operationId": "DeleteRadarValueListItemsItem", "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, { "in": "path", - "name": "value_list", + "name": "item", "required": true, "schema": { "maxLength": 5000, @@ -68981,6 +119321,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -68993,7 +119334,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/radar.value_list" + "$ref": "#/components/schemas/deleted_radar.value_list_item" } } }, @@ -69011,13 +119352,28 @@ } } }, - "post": { - "description": "

Updates a ValueList object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Note that item_type is immutable.

", - "operationId": "PostRadarValueListsValueList", + "get": { + "description": "

Retrieves a ValueListItem object.

", + "operationId": "GetRadarValueListItemsItem", "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, { "in": "path", - "name": "value_list", + "name": "item", "required": true, "schema": { "maxLength": 5000, @@ -69029,44 +119385,10 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "alias": { - "description": "The name of the value list for use in rules.", - "maxLength": 100, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "name": { - "description": "The human-readable name of the value list.", - "maxLength": 100, - "type": "string" - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -69078,7 +119400,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/radar.value_list" + "$ref": "#/components/schemas/radar.value_list_item" } } }, @@ -69097,13 +119419,35 @@ } } }, - "/v1/recipients": { + "/v1/radar/value_lists": { "get": { - "deprecated": true, - "description": "

Returns a list of your recipients. The recipients are returned sorted by creation date, with the most recently created recipients appearing first.

", - "operationId": "GetRecipients", + "description": "

Returns a list of ValueList objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetRadarValueLists", "parameters": [ { + "description": "The alias used to reference the value list when writing rules.", + "in": "query", + "name": "alias", + "required": false, + "schema": { + "maxLength": 100, + "type": "string" + }, + "style": "form" + }, + { + "description": "A value contained within a value list - returns all value lists containing this value.", + "in": "query", + "name": "contains", + "required": false, + "schema": { + "maxLength": 800, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return value lists that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -69181,27 +119525,6 @@ "type": "string" }, "style": "form" - }, - { - "in": "query", - "name": "type", - "required": false, - "schema": { - "enum": ["corporation", "individual"], - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Only return recipients that are verified or unverified.", - "in": "query", - "name": "verified", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" } ], "requestBody": { @@ -69209,6 +119532,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -69225,7 +119549,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/recipient" + "$ref": "#/components/schemas/radar.value_list" }, "type": "array" }, @@ -69241,11 +119565,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/recipients", + "pattern": "^/v1/radar/value_lists", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "RadarListListList", "type": "object", "x-expandableFields": ["data"] } @@ -69266,9 +119591,8 @@ } }, "post": { - "deprecated": true, - "description": "

Creates a new Recipient object and verifies the recipient’s identity.\nAlso verifies the recipient’s bank account information or debit card, if either is provided.

", - "operationId": "PostRecipients", + "description": "

Creates a new ValueList object, which can then be referenced in rules.

", + "operationId": "PostRadarValueLists", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -69283,27 +119607,11 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "bank_account": { - "description": "A bank account to attach to the recipient. You can provide either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe-js), or a dictionary containing a user's bank account details, with the options described below.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "card": { - "description": "A U.S. Visa or MasterCard debit card (_not_ prepaid) to attach to the recipient. If the debit card is not valid, recipient creation will fail. You can provide either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe-js), or a dictionary containing a user's debit card details, with the options described below. Although not all information is required, the extra info helps prevent fraud.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "description": { - "description": "An arbitrary string which you can attach to a `Recipient` object. It is displayed alongside the recipient in the web interface.", - "maxLength": 5000, - "type": "string" - }, - "email": { - "description": "The recipient's email address. It is displayed alongside the recipient in the web interface, and can be useful for searching and tracking.", - "maxLength": 5000, + "alias": { + "description": "The name of the value list for use in rules.", + "maxLength": 100, "type": "string" }, "expand": { @@ -69314,38 +119622,37 @@ }, "type": "array" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } + "item_type": { + "description": "Type of the items in the value list. One of `card_fingerprint`, `us_bank_account_fingerprint`, `sepa_debit_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, `case_sensitive_string`, or `customer_id`. Use `string` if the item type is unknown or mixed.", + "enum": [ + "card_bin", + "card_fingerprint", + "case_sensitive_string", + "country", + "customer_id", + "email", + "ip_address", + "sepa_debit_fingerprint", + "string", + "us_bank_account_fingerprint" ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "name": { - "description": "The recipient's full, legal name. For type `individual`, should be in the format `First Last`, `First Middle Last`, or `First M Last` (no prefixes or suffixes). For `corporation`, the full, incorporated name.", "maxLength": 5000, "type": "string" }, - "tax_id": { - "description": "The recipient's tax ID, as a string. For type `individual`, the full SSN; for type `corporation`, the full EIN.", - "maxLength": 5000, - "type": "string" + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" }, - "type": { - "description": "Type of the recipient: either `individual` or `corporation`.", - "maxLength": 5000, + "name": { + "description": "The human-readable name of the value list.", + "maxLength": 100, "type": "string" } }, - "required": ["name", "type"], + "required": ["alias", "name"], "type": "object" } } @@ -69357,7 +119664,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/recipient" + "$ref": "#/components/schemas/radar.value_list" } } }, @@ -69376,15 +119683,14 @@ } } }, - "/v1/recipients/{id}": { + "/v1/radar/value_lists/{value_list}": { "delete": { - "deprecated": true, - "description": "

Permanently deletes a recipient. It cannot be undone.

", - "operationId": "DeleteRecipientsId", + "description": "

Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.

", + "operationId": "DeleteRadarValueListsValueList", "parameters": [ { "in": "path", - "name": "id", + "name": "value_list", "required": true, "schema": { "maxLength": 5000, @@ -69398,6 +119704,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -69410,7 +119717,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_recipient" + "$ref": "#/components/schemas/deleted_radar.value_list" } } }, @@ -69429,9 +119736,8 @@ } }, "get": { - "deprecated": true, - "description": "

Retrieves the details of an existing recipient. You need only supply the unique recipient identifier that was returned upon recipient creation.

", - "operationId": "GetRecipientsId", + "description": "

Retrieves a ValueList object.

", + "operationId": "GetRadarValueListsValueList", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -69450,7 +119756,7 @@ }, { "in": "path", - "name": "id", + "name": "value_list", "required": true, "schema": { "maxLength": 5000, @@ -69464,6 +119770,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -69476,14 +119783,7 @@ "content": { "application/json": { "schema": { - "anyOf": [ - { - "$ref": "#/components/schemas/recipient" - }, - { - "$ref": "#/components/schemas/deleted_recipient" - } - ] + "$ref": "#/components/schemas/radar.value_list" } } }, @@ -69502,13 +119802,12 @@ } }, "post": { - "deprecated": true, - "description": "

Updates the specified recipient by setting the values of the parameters passed.\nAny parameters not provided will be left unchanged.

\n\n

If you update the name or tax ID, the identity verification will automatically be rerun.\nIf you update the bank account, the bank account validation will automatically be rerun.

", - "operationId": "PostRecipientsId", + "description": "

Updates a ValueList object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Note that item_type is immutable.

", + "operationId": "PostRadarValueListsValueList", "parameters": [ { "in": "path", - "name": "id", + "name": "value_list", "required": true, "schema": { "maxLength": 5000, @@ -69531,32 +119830,11 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "bank_account": { - "description": "A bank account to attach to the recipient. You can provide either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe-js), or a dictionary containing a user's bank account details, with the options described below.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "card": { - "description": "A U.S. Visa or MasterCard debit card (not prepaid) to attach to the recipient. You can provide either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/stripe-js), or a dictionary containing a user's debit card details, with the options described below. Passing `card` will create a new card, make it the new recipient default card, and delete the old recipient default (if one exists). If you want to add additional debit cards instead of replacing the existing default, use the [card creation API](https://stripe.com/docs/api#create_card). Whenever you attach a card to a recipient, Stripe will automatically validate the debit card.", - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "default_card": { - "description": "ID of the card to set as the recipient's new default for payouts.", - "maxLength": 5000, - "type": "string" - }, - "description": { - "description": "An arbitrary string which you can attach to a `Recipient` object. It is displayed alongside the recipient in the web interface.", - "maxLength": 5000, - "type": "string" - }, - "email": { - "description": "The recipient's email address. It is displayed alongside the recipient in the web interface, and can be useful for searching and tracking.", - "maxLength": 5000, + "alias": { + "description": "The name of the value list for use in rules.", + "maxLength": 100, "type": "string" }, "expand": { @@ -69568,28 +119846,15 @@ "type": "array" }, "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" }, "name": { - "description": "The recipient's full, legal name. For type `individual`, should be in the format `First Last`, `First Middle Last`, or `First M Last` (no prefixes or suffixes). For `corporation`, the full, incorporated name.", - "maxLength": 5000, - "type": "string" - }, - "tax_id": { - "description": "The recipient's tax ID, as a string. For type `individual`, the full SSN; for type `corporation`, the full EIN.", - "maxLength": 5000, + "description": "The human-readable name of the value list.", + "maxLength": 100, "type": "string" } }, @@ -69604,7 +119869,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/recipient" + "$ref": "#/components/schemas/radar.value_list" } } }, @@ -69625,7 +119890,7 @@ }, "/v1/refunds": { "get": { - "description": "

Returns a list of all refunds you’ve previously created. The refunds are returned in sorted order, with the most recent refunds appearing first. For convenience, the 10 most recent refunds are always available by default on the charge object.

", + "description": "

Returns a list of all refunds you created. We return the refunds in sorted order, with the most recent refunds appearing first. The 10 most recent refunds are always available by default on the Charge object.

", "operationId": "GetRefunds", "parameters": [ { @@ -69639,6 +119904,7 @@ "style": "form" }, { + "description": "Only return refunds that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -69732,6 +119998,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -69769,6 +120036,7 @@ } }, "required": ["data", "has_more", "object", "url"], + "title": "APIMethodRefundList", "type": "object", "x-expandableFields": ["data"] } @@ -69789,7 +120057,7 @@ } }, "post": { - "description": "

Create a refund.

", + "description": "

When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.

\n\n

Creating a new refund will refund a charge that has previously been created but not yet refunded.\nFunds will be refunded to the credit or debit card that was originally charged.

\n\n

You can optionally refund only part of a charge.\nYou can do so multiple times, until the entire charge has been refunded.

\n\n

Once entirely refunded, a charge can’t be refunded again.\nThis method will raise an error when called on an already-refunded charge,\nor when trying to refund more money than is left on a charge.

", "operationId": "PostRefunds", "requestBody": { "content": { @@ -69805,11 +120073,22 @@ } }, "schema": { + "additionalProperties": false, "properties": { "amount": { "type": "integer" }, "charge": { + "description": "The identifier of the charge to refund.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "Customer whose customer balance to refund from.", "maxLength": 5000, "type": "string" }, @@ -69821,6 +120100,10 @@ }, "type": "array" }, + "instructions_email": { + "description": "For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions.", + "type": "string" + }, "metadata": { "anyOf": [ { @@ -69836,11 +120119,18 @@ ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, + "origin": { + "description": "Origin of the refund", + "enum": ["customer_balance"], + "type": "string" + }, "payment_intent": { + "description": "The identifier of the PaymentIntent to refund.", "maxLength": 5000, "type": "string" }, "reason": { + "description": "String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.", "enum": [ "duplicate", "fraudulent", @@ -69850,9 +120140,11 @@ "type": "string" }, "refund_application_fee": { + "description": "Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.", "type": "boolean" }, "reverse_transfer": { + "description": "Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).

A transfer can be reversed only by the application that created the charge.", "type": "boolean" } }, @@ -69921,6 +120213,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -69950,10 +120243,95 @@ "description": "Error response." } } - }, + }, + "post": { + "description": "

Updates the refund that you specify by setting the values of the passed parameters. Any parameters that you don’t provide remain unchanged.

\n\n

This request only accepts metadata as an argument.

", + "operationId": "PostRefundsRefund", + "parameters": [ + { + "in": "path", + "name": "refund", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/refund" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/refunds/{refund}/cancel": { "post": { - "description": "

Updates the specified refund by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

This request only accepts metadata as an argument.

", - "operationId": "PostRefundsRefund", + "description": "

Cancels a refund with a status of requires_action.

\n\n

You can’t cancel refunds in other states. Only refunds for payment methods that require customer action can enter the requires_action state.

", + "operationId": "PostRefundsRefundCancel", "parameters": [ { "in": "path", @@ -69972,13 +120350,10 @@ "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -69987,21 +120362,6 @@ "type": "string" }, "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." } }, "type": "object" @@ -70036,10 +120396,11 @@ }, "/v1/reporting/report_runs": { "get": { - "description": "

Returns a list of Report Runs, with the most recent appearing first. (Requires a live-mode API key.)

", + "description": "

Returns a list of Report Runs, with the most recent appearing first.

", "operationId": "GetReportingReportRuns", "parameters": [ { + "description": "Only return Report Runs that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -70124,6 +120485,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -70161,6 +120523,7 @@ } }, "required": ["data", "has_more", "object", "url"], + "title": "FinancialReportingFinanceReportRunList", "type": "object", "x-expandableFields": ["data"] } @@ -70181,7 +120544,7 @@ } }, "post": { - "description": "

Creates a new object and begin running the report. (Requires a live-mode API key.)

", + "description": "

Creates a new object and begin running the report. (Certain report types require a live-mode API key.)

", "operationId": "PostReportingReportRuns", "requestBody": { "content": { @@ -70197,6 +120560,7 @@ } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -70240,6 +120604,8 @@ "anticipation_repayment", "charge", "charge_failure", + "climate_order_purchase", + "climate_order_refund", "connect_collection_transfer", "connect_reserved_funds", "contribution", @@ -70268,7 +120634,8 @@ "topup", "topup_reversal", "transfer", - "transfer_reversal" + "transfer_reversal", + "unreconciled_customer_funds" ], "maxLength": 5000, "type": "string", @@ -70371,6 +120738,7 @@ "America/Cayman", "America/Chicago", "America/Chihuahua", + "America/Ciudad_Juarez", "America/Coral_Harbour", "America/Cordoba", "America/Costa_Rica", @@ -70451,6 +120819,7 @@ "America/North_Dakota/Beulah", "America/North_Dakota/Center", "America/North_Dakota/New_Salem", + "America/Nuuk", "America/Ojinaga", "America/Panama", "America/Pangnirtung", @@ -70724,6 +121093,7 @@ "Europe/Kaliningrad", "Europe/Kiev", "Europe/Kirov", + "Europe/Kyiv", "Europe/Lisbon", "Europe/Ljubljana", "Europe/London", @@ -70819,6 +121189,7 @@ "Pacific/Guam", "Pacific/Honolulu", "Pacific/Johnston", + "Pacific/Kanton", "Pacific/Kiritimati", "Pacific/Kosrae", "Pacific/Kwajalein", @@ -70874,16 +121245,17677 @@ "maxLength": 5000, "type": "string" } - }, - "title": "run_parameter_specs", - "type": "object" + }, + "title": "run_parameter_specs", + "type": "object" + }, + "report_type": { + "description": "The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `\"balance.summary.1\"`.", + "type": "string" + } + }, + "required": ["report_type"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/reporting.report_run" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/reporting/report_runs/{report_run}": { + "get": { + "description": "

Retrieves the details of an existing Report Run.

", + "operationId": "GetReportingReportRunsReportRun", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "report_run", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/reporting.report_run" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/reporting/report_types": { + "get": { + "description": "

Returns a full list of Report Types.

", + "operationId": "GetReportingReportTypes", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/reporting.report_type" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "FinancialReportingFinanceReportTypeList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/reporting/report_types/{report_type}": { + "get": { + "description": "

Retrieves the details of a Report Type. (Certain report types require a live-mode API key.)

", + "operationId": "GetReportingReportTypesReportType", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "report_type", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/reporting.report_type" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/reviews": { + "get": { + "description": "

Returns a list of Review objects that have open set to true. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", + "operationId": "GetReviews", + "parameters": [ + { + "description": "Only return reviews that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/review" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "RadarReviewList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/reviews/{review}": { + "get": { + "description": "

Retrieves a Review object.

", + "operationId": "GetReviewsReview", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "review", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/review" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/reviews/{review}/approve": { + "post": { + "description": "

Approves a Review object, closing it and removing it from the list of reviews.

", + "operationId": "PostReviewsReviewApprove", + "parameters": [ + { + "in": "path", + "name": "review", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/review" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/setup_attempts": { + "get": { + "description": "

Returns a list of SetupAttempts that associate with a provided SetupIntent.

", + "operationId": "GetSetupAttempts", + "parameters": [ + { + "description": "A filter on the list, based on the object `created` field. The value\ncan be a string with an integer Unix timestamp or a\ndictionary with a number of different query options.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Only return SetupAttempts created by the SetupIntent specified by\nthis ID.", + "in": "query", + "name": "setup_intent", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/setup_attempt" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/setup_attempts", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PaymentFlowsSetupIntentSetupAttemptList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/setup_intents": { + "get": { + "description": "

Returns a list of SetupIntents.

", + "operationId": "GetSetupIntents", + "parameters": [ + { + "description": "If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.\n\nIt can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.", + "in": "query", + "name": "attach_to_self", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return SetupIntents for the customer specified by this customer ID.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Only return SetupIntents that associate with the specified payment method.", + "in": "query", + "name": "payment_method", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/setup_intent" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/setup_intents", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "PaymentFlowsSetupIntentList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a SetupIntent object.

\n\n

After you create the SetupIntent, attach a payment method and confirm\nit to collect any required permissions to charge the payment method later.

", + "operationId": "PostSetupIntents", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "automatic_payment_methods": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "flow_directions": { + "explode": true, + "style": "deepObject" + }, + "mandate_data": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "payment_method_data": { + "explode": true, + "style": "deepObject" + }, + "payment_method_options": { + "explode": true, + "style": "deepObject" + }, + "payment_method_types": { + "explode": true, + "style": "deepObject" + }, + "single_use": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "attach_to_self": { + "description": "If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.\n\nIt can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.", + "type": "boolean" + }, + "automatic_payment_methods": { + "description": "When you enable this parameter, this SetupIntent accepts payment methods that you enable in the Dashboard and that are compatible with its other parameters.", + "properties": { + "allow_redirects": { + "enum": ["always", "never"], + "type": "string" + }, + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "automatic_payment_methods_param", + "type": "object" + }, + "confirm": { + "description": "Set to `true` to attempt to confirm this SetupIntent immediately. This parameter defaults to `false`. If a card is the attached payment method, you can provide a `return_url` in case further authentication is necessary.", + "type": "boolean" + }, + "confirmation_token": { + "description": "ID of the ConfirmationToken used to confirm this SetupIntent.\n\nIf the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.", + "maxLength": 5000, + "type": "string" + }, + "customer": { + "description": "ID of the Customer this SetupIntent belongs to, if one exists.\n\nIf present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 1000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "flow_directions": { + "description": "Indicates the directions of money movement for which this payment method is intended to be used.\n\nInclude `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.", + "items": { + "enum": ["inbound", "outbound"], + "type": "string" + }, + "type": "array" + }, + "mandate_data": { + "anyOf": [ + { + "properties": { + "customer_acceptance": { + "properties": { + "accepted_at": { + "format": "unix-time", + "type": "integer" + }, + "offline": { + "properties": {}, + "title": "offline_param", + "type": "object" + }, + "online": { + "properties": { + "ip_address": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["ip_address", "user_agent"], + "title": "online_param", + "type": "object" + }, + "type": { + "enum": ["offline", "online"], + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "customer_acceptance_param", + "type": "object" + } + }, + "required": ["customer_acceptance"], + "title": "secret_key_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "This hash contains details about the mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm)." + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "on_behalf_of": { + "description": "The Stripe account ID created for this SetupIntent.", + "type": "string" + }, + "payment_method": { + "description": "ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.", + "maxLength": 5000, + "type": "string" + }, + "payment_method_configuration": { + "description": "The ID of the payment method configuration to use with this SetupIntent.", + "maxLength": 100, + "type": "string" + }, + "payment_method_data": { + "description": "When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)\nvalue in the SetupIntent.", + "properties": { + "acss_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "institution_number": { + "maxLength": 5000, + "type": "string" + }, + "transit_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "account_number", + "institution_number", + "transit_number" + ], + "title": "payment_method_param", + "type": "object" + }, + "affirm": { + "properties": {}, + "title": "param", + "type": "object" + }, + "afterpay_clearpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "alipay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "allow_redisplay": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "amazon_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "au_becs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "bsb_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "bsb_number"], + "title": "param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "sort_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "bancontact": { + "properties": {}, + "title": "param", + "type": "object" + }, + "billing_details": { + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "billing_details_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "name": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "billing_details_inner_params", + "type": "object" + }, + "blik": { + "properties": {}, + "title": "param", + "type": "object" + }, + "boleto": { + "properties": { + "tax_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "param", + "type": "object" + }, + "cashapp": { + "properties": {}, + "title": "param", + "type": "object" + }, + "customer_balance": { + "properties": {}, + "title": "param", + "type": "object" + }, + "eps": { + "properties": { + "bank": { + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "fpx": { + "properties": { + "bank": { + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["bank"], + "title": "param", + "type": "object" + }, + "giropay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "grabpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "ideal": { + "properties": { + "bank": { + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "interac_present": { + "properties": {}, + "title": "param", + "type": "object" + }, + "klarna": { + "properties": { + "dob": { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth", + "type": "object" + } + }, + "title": "param", + "type": "object" + }, + "konbini": { + "properties": {}, + "title": "param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "param", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "mobilepay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "multibanco": { + "properties": {}, + "title": "param", + "type": "object" + }, + "oxxo": { + "properties": {}, + "title": "param", + "type": "object" + }, + "p24": { + "properties": { + "bank": { + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "param", + "type": "object" + }, + "paynow": { + "properties": {}, + "title": "param", + "type": "object" + }, + "paypal": { + "properties": {}, + "title": "param", + "type": "object" + }, + "pix": { + "properties": {}, + "title": "param", + "type": "object" + }, + "promptpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "radar_options": { + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "revolut_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "iban": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["iban"], + "title": "param", + "type": "object" + }, + "sofort": { + "properties": { + "country": { + "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], + "type": "string" + } + }, + "required": ["country"], + "title": "param", + "type": "object" + }, + "swish": { + "properties": {}, + "title": "param", + "type": "object" + }, + "twint": { + "properties": {}, + "title": "param", + "type": "object" + }, + "type": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "properties": { + "account_holder_type": { + "enum": ["company", "individual"], + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "savings"], + "type": "string" + }, + "financial_connections_account": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "wechat_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "zip": { + "properties": {}, + "title": "param", + "type": "object" + } + }, + "required": ["type"], + "title": "payment_method_data_params", + "type": "object" + }, + "payment_method_options": { + "description": "Payment method-specific configuration for this SetupIntent.", + "properties": { + "acss_debit": { + "properties": { + "currency": { + "enum": ["cad", "usd"], + "type": "string" + }, + "mandate_options": { + "properties": { + "custom_mandate_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "default_for": { + "items": { + "enum": ["invoice", "subscription"], + "type": "string" + }, + "type": "array" + }, + "interval_description": { + "maxLength": 500, + "type": "string" + }, + "payment_schedule": { + "enum": ["combined", "interval", "sporadic"], + "type": "string" + }, + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "setup_intent_payment_method_options_mandate_options_param", + "type": "object" + }, + "verification_method": { + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "amazon_pay": { + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "card": { + "properties": { + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "currency": { + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + }, + "end_date": { + "format": "unix-time", + "type": "integer" + }, + "interval": { + "enum": [ + "day", + "month", + "sporadic", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "type": "integer" + }, + "reference": { + "maxLength": 80, + "type": "string" + }, + "start_date": { + "format": "unix-time", + "type": "integer" + }, + "supported_types": { + "items": { + "enum": ["india"], + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "amount", + "amount_type", + "currency", + "interval", + "reference", + "start_date" + ], + "title": "setup_intent_mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string", + "x-stripeBypassValidation": true + }, + "three_d_secure": { + "properties": { + "ares_trans_status": { + "enum": ["A", "C", "I", "N", "R", "U", "Y"], + "type": "string" + }, + "cryptogram": { + "maxLength": 5000, + "type": "string" + }, + "electronic_commerce_indicator": { + "enum": ["01", "02", "05", "06", "07"], + "type": "string", + "x-stripeBypassValidation": true + }, + "network_options": { + "properties": { + "cartes_bancaires": { + "properties": { + "cb_avalgo": { + "enum": ["0", "1", "2", "3", "4", "A"], + "type": "string" + }, + "cb_exemption": { + "maxLength": 4, + "type": "string" + }, + "cb_score": { + "type": "integer" + } + }, + "required": ["cb_avalgo"], + "title": "cartes_bancaires_network_options_param", + "type": "object" + } + }, + "title": "network_options_param", + "type": "object" + }, + "requestor_challenge_indicator": { + "maxLength": 2, + "type": "string" + }, + "transaction_id": { + "maxLength": 5000, + "type": "string" + }, + "version": { + "enum": ["1.0.2", "2.1.0", "2.2.0"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + } + }, + "title": "setup_intent_param", + "type": "object" + }, + "card_present": { + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "paypal": { + "properties": { + "billing_agreement_id": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "us_bank_account": { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "title": "linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "return_url": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "linked_account_options_param", + "type": "object" + }, + "mandate_options": { + "properties": { + "collection_method": { + "enum": ["", "paper"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "networks": { + "properties": { + "requested": { + "items": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "type": "array" + } + }, + "title": "networks_options_param", + "type": "object" + }, + "verification_method": { + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "payment_method_types": { + "description": "The list of payment method types (for example, card) that this SetupIntent can use. If you don't provide this, it defaults to [\"card\"].", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "return_url": { + "description": "The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. To redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).", + "type": "string" + }, + "single_use": { + "description": "If you populate this hash, this SetupIntent generates a `single_use` mandate after successful completion.", + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + } + }, + "required": ["amount", "currency"], + "title": "setup_intent_single_use_params", + "type": "object" + }, + "usage": { + "description": "Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`.", + "enum": ["off_session", "on_session"], + "type": "string" + }, + "use_stripe_sdk": { + "description": "Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/setup_intent" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/setup_intents/{intent}": { + "get": { + "description": "

Retrieves the details of a SetupIntent that has previously been created.

\n\n

Client-side retrieval using a publishable key is allowed when the client_secret is provided in the query string.

\n\n

When retrieved with a publishable key, only a subset of properties will be returned. Please refer to the SetupIntent object reference for more details.

", + "operationId": "GetSetupIntentsIntent", + "parameters": [ + { + "description": "The client secret of the SetupIntent. We require this string if you use a publishable key to retrieve the SetupIntent.", + "in": "query", + "name": "client_secret", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "intent", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/setup_intent" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates a SetupIntent object.

", + "operationId": "PostSetupIntentsIntent", + "parameters": [ + { + "in": "path", + "name": "intent", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "flow_directions": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "payment_method_data": { + "explode": true, + "style": "deepObject" + }, + "payment_method_options": { + "explode": true, + "style": "deepObject" + }, + "payment_method_types": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "attach_to_self": { + "description": "If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.\n\nIt can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.", + "type": "boolean" + }, + "customer": { + "description": "ID of the Customer this SetupIntent belongs to, if one exists.\n\nIf present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 1000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "flow_directions": { + "description": "Indicates the directions of money movement for which this payment method is intended to be used.\n\nInclude `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.", + "items": { + "enum": ["inbound", "outbound"], + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "payment_method": { + "description": "ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent. To unset this field to null, pass in an empty string.", + "maxLength": 5000, + "type": "string" + }, + "payment_method_configuration": { + "description": "The ID of the payment method configuration to use with this SetupIntent.", + "maxLength": 100, + "type": "string" + }, + "payment_method_data": { + "description": "When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)\nvalue in the SetupIntent.", + "properties": { + "acss_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "institution_number": { + "maxLength": 5000, + "type": "string" + }, + "transit_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "account_number", + "institution_number", + "transit_number" + ], + "title": "payment_method_param", + "type": "object" + }, + "affirm": { + "properties": {}, + "title": "param", + "type": "object" + }, + "afterpay_clearpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "alipay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "allow_redisplay": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "amazon_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "au_becs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "bsb_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "bsb_number"], + "title": "param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "sort_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "bancontact": { + "properties": {}, + "title": "param", + "type": "object" + }, + "billing_details": { + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "billing_details_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "name": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "billing_details_inner_params", + "type": "object" + }, + "blik": { + "properties": {}, + "title": "param", + "type": "object" + }, + "boleto": { + "properties": { + "tax_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "param", + "type": "object" + }, + "cashapp": { + "properties": {}, + "title": "param", + "type": "object" + }, + "customer_balance": { + "properties": {}, + "title": "param", + "type": "object" + }, + "eps": { + "properties": { + "bank": { + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "fpx": { + "properties": { + "bank": { + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["bank"], + "title": "param", + "type": "object" + }, + "giropay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "grabpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "ideal": { + "properties": { + "bank": { + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "interac_present": { + "properties": {}, + "title": "param", + "type": "object" + }, + "klarna": { + "properties": { + "dob": { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth", + "type": "object" + } + }, + "title": "param", + "type": "object" + }, + "konbini": { + "properties": {}, + "title": "param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "param", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "mobilepay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "multibanco": { + "properties": {}, + "title": "param", + "type": "object" + }, + "oxxo": { + "properties": {}, + "title": "param", + "type": "object" + }, + "p24": { + "properties": { + "bank": { + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "param", + "type": "object" + }, + "paynow": { + "properties": {}, + "title": "param", + "type": "object" + }, + "paypal": { + "properties": {}, + "title": "param", + "type": "object" + }, + "pix": { + "properties": {}, + "title": "param", + "type": "object" + }, + "promptpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "radar_options": { + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "revolut_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "iban": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["iban"], + "title": "param", + "type": "object" + }, + "sofort": { + "properties": { + "country": { + "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], + "type": "string" + } + }, + "required": ["country"], + "title": "param", + "type": "object" + }, + "swish": { + "properties": {}, + "title": "param", + "type": "object" + }, + "twint": { + "properties": {}, + "title": "param", + "type": "object" + }, + "type": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "properties": { + "account_holder_type": { + "enum": ["company", "individual"], + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "savings"], + "type": "string" + }, + "financial_connections_account": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "wechat_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "zip": { + "properties": {}, + "title": "param", + "type": "object" + } + }, + "required": ["type"], + "title": "payment_method_data_params", + "type": "object" + }, + "payment_method_options": { + "description": "Payment method-specific configuration for this SetupIntent.", + "properties": { + "acss_debit": { + "properties": { + "currency": { + "enum": ["cad", "usd"], + "type": "string" + }, + "mandate_options": { + "properties": { + "custom_mandate_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "default_for": { + "items": { + "enum": ["invoice", "subscription"], + "type": "string" + }, + "type": "array" + }, + "interval_description": { + "maxLength": 500, + "type": "string" + }, + "payment_schedule": { + "enum": ["combined", "interval", "sporadic"], + "type": "string" + }, + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "setup_intent_payment_method_options_mandate_options_param", + "type": "object" + }, + "verification_method": { + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "amazon_pay": { + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "card": { + "properties": { + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "currency": { + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + }, + "end_date": { + "format": "unix-time", + "type": "integer" + }, + "interval": { + "enum": [ + "day", + "month", + "sporadic", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "type": "integer" + }, + "reference": { + "maxLength": 80, + "type": "string" + }, + "start_date": { + "format": "unix-time", + "type": "integer" + }, + "supported_types": { + "items": { + "enum": ["india"], + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "amount", + "amount_type", + "currency", + "interval", + "reference", + "start_date" + ], + "title": "setup_intent_mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string", + "x-stripeBypassValidation": true + }, + "three_d_secure": { + "properties": { + "ares_trans_status": { + "enum": ["A", "C", "I", "N", "R", "U", "Y"], + "type": "string" + }, + "cryptogram": { + "maxLength": 5000, + "type": "string" + }, + "electronic_commerce_indicator": { + "enum": ["01", "02", "05", "06", "07"], + "type": "string", + "x-stripeBypassValidation": true + }, + "network_options": { + "properties": { + "cartes_bancaires": { + "properties": { + "cb_avalgo": { + "enum": ["0", "1", "2", "3", "4", "A"], + "type": "string" + }, + "cb_exemption": { + "maxLength": 4, + "type": "string" + }, + "cb_score": { + "type": "integer" + } + }, + "required": ["cb_avalgo"], + "title": "cartes_bancaires_network_options_param", + "type": "object" + } + }, + "title": "network_options_param", + "type": "object" + }, + "requestor_challenge_indicator": { + "maxLength": 2, + "type": "string" + }, + "transaction_id": { + "maxLength": 5000, + "type": "string" + }, + "version": { + "enum": ["1.0.2", "2.1.0", "2.2.0"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + } + }, + "title": "setup_intent_param", + "type": "object" + }, + "card_present": { + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "paypal": { + "properties": { + "billing_agreement_id": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "us_bank_account": { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "title": "linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "return_url": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "linked_account_options_param", + "type": "object" + }, + "mandate_options": { + "properties": { + "collection_method": { + "enum": ["", "paper"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "networks": { + "properties": { + "requested": { + "items": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "type": "array" + } + }, + "title": "networks_options_param", + "type": "object" + }, + "verification_method": { + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "payment_method_types": { + "description": "The list of payment method types (for example, card) that this SetupIntent can set up. If you don't provide this array, it defaults to [\"card\"].", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/setup_intent" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/setup_intents/{intent}/cancel": { + "post": { + "description": "

You can cancel a SetupIntent object when it’s in one of these statuses: requires_payment_method, requires_confirmation, or requires_action.

\n\n

After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. You can’t cancel the SetupIntent for a Checkout Session. Expire the Checkout Session instead.

", + "operationId": "PostSetupIntentsIntentCancel", + "parameters": [ + { + "in": "path", + "name": "intent", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "cancellation_reason": { + "description": "Reason for canceling this SetupIntent. Possible values are: `abandoned`, `requested_by_customer`, or `duplicate`", + "enum": ["abandoned", "duplicate", "requested_by_customer"], + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/setup_intent" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/setup_intents/{intent}/confirm": { + "post": { + "description": "

Confirm that your customer intends to set up the current or\nprovided payment method. For example, you would confirm a SetupIntent\nwhen a customer hits the “Save” button on a payment method management\npage on your website.

\n\n

If the selected payment method does not require any additional\nsteps from the customer, the SetupIntent will transition to the\nsucceeded status.

\n\n

Otherwise, it will transition to the requires_action status and\nsuggest additional actions via next_action. If setup fails,\nthe SetupIntent will transition to the\nrequires_payment_method status or the canceled status if the\nconfirmation limit is reached.

", + "operationId": "PostSetupIntentsIntentConfirm", + "parameters": [ + { + "in": "path", + "name": "intent", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "mandate_data": { + "explode": true, + "style": "deepObject" + }, + "payment_method_data": { + "explode": true, + "style": "deepObject" + }, + "payment_method_options": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "client_secret": { + "description": "The client secret of the SetupIntent.", + "maxLength": 5000, + "type": "string" + }, + "confirmation_token": { + "description": "ID of the ConfirmationToken used to confirm this SetupIntent.\n\nIf the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "mandate_data": { + "anyOf": [ + { + "properties": { + "customer_acceptance": { + "properties": { + "accepted_at": { + "format": "unix-time", + "type": "integer" + }, + "offline": { + "properties": {}, + "title": "offline_param", + "type": "object" + }, + "online": { + "properties": { + "ip_address": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["ip_address", "user_agent"], + "title": "online_param", + "type": "object" + }, + "type": { + "enum": ["offline", "online"], + "maxLength": 5000, + "type": "string" + } + }, + "required": ["type"], + "title": "customer_acceptance_param", + "type": "object" + } + }, + "required": ["customer_acceptance"], + "title": "secret_key_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + }, + { + "description": "This hash contains details about the Mandate to create", + "properties": { + "customer_acceptance": { + "properties": { + "online": { + "properties": { + "ip_address": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "online_param", + "type": "object" + }, + "type": { + "enum": ["online"], + "maxLength": 5000, + "type": "string" + } + }, + "required": ["online", "type"], + "title": "customer_acceptance_param", + "type": "object" + } + }, + "required": ["customer_acceptance"], + "title": "client_key_param", + "type": "object" + } + ] + }, + "payment_method": { + "description": "ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.", + "maxLength": 5000, + "type": "string" + }, + "payment_method_data": { + "description": "When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)\nvalue in the SetupIntent.", + "properties": { + "acss_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "institution_number": { + "maxLength": 5000, + "type": "string" + }, + "transit_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "account_number", + "institution_number", + "transit_number" + ], + "title": "payment_method_param", + "type": "object" + }, + "affirm": { + "properties": {}, + "title": "param", + "type": "object" + }, + "afterpay_clearpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "alipay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "allow_redisplay": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "amazon_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "au_becs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "bsb_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "bsb_number"], + "title": "param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "sort_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "bancontact": { + "properties": {}, + "title": "param", + "type": "object" + }, + "billing_details": { + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "billing_details_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "name": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "billing_details_inner_params", + "type": "object" + }, + "blik": { + "properties": {}, + "title": "param", + "type": "object" + }, + "boleto": { + "properties": { + "tax_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "param", + "type": "object" + }, + "cashapp": { + "properties": {}, + "title": "param", + "type": "object" + }, + "customer_balance": { + "properties": {}, + "title": "param", + "type": "object" + }, + "eps": { + "properties": { + "bank": { + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "fpx": { + "properties": { + "bank": { + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["bank"], + "title": "param", + "type": "object" + }, + "giropay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "grabpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "ideal": { + "properties": { + "bank": { + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "interac_present": { + "properties": {}, + "title": "param", + "type": "object" + }, + "klarna": { + "properties": { + "dob": { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth", + "type": "object" + } + }, + "title": "param", + "type": "object" + }, + "konbini": { + "properties": {}, + "title": "param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "param", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "mobilepay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "multibanco": { + "properties": {}, + "title": "param", + "type": "object" + }, + "oxxo": { + "properties": {}, + "title": "param", + "type": "object" + }, + "p24": { + "properties": { + "bank": { + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "param", + "type": "object" + }, + "paynow": { + "properties": {}, + "title": "param", + "type": "object" + }, + "paypal": { + "properties": {}, + "title": "param", + "type": "object" + }, + "pix": { + "properties": {}, + "title": "param", + "type": "object" + }, + "promptpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "radar_options": { + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "revolut_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "iban": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["iban"], + "title": "param", + "type": "object" + }, + "sofort": { + "properties": { + "country": { + "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], + "type": "string" + } + }, + "required": ["country"], + "title": "param", + "type": "object" + }, + "swish": { + "properties": {}, + "title": "param", + "type": "object" + }, + "twint": { + "properties": {}, + "title": "param", + "type": "object" + }, + "type": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "properties": { + "account_holder_type": { + "enum": ["company", "individual"], + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "savings"], + "type": "string" + }, + "financial_connections_account": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "wechat_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "zip": { + "properties": {}, + "title": "param", + "type": "object" + } + }, + "required": ["type"], + "title": "payment_method_data_params", + "type": "object" + }, + "payment_method_options": { + "description": "Payment method-specific configuration for this SetupIntent.", + "properties": { + "acss_debit": { + "properties": { + "currency": { + "enum": ["cad", "usd"], + "type": "string" + }, + "mandate_options": { + "properties": { + "custom_mandate_url": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "default_for": { + "items": { + "enum": ["invoice", "subscription"], + "type": "string" + }, + "type": "array" + }, + "interval_description": { + "maxLength": 500, + "type": "string" + }, + "payment_schedule": { + "enum": ["combined", "interval", "sporadic"], + "type": "string" + }, + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "setup_intent_payment_method_options_mandate_options_param", + "type": "object" + }, + "verification_method": { + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "amazon_pay": { + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "card": { + "properties": { + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "currency": { + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + }, + "end_date": { + "format": "unix-time", + "type": "integer" + }, + "interval": { + "enum": [ + "day", + "month", + "sporadic", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "type": "integer" + }, + "reference": { + "maxLength": 80, + "type": "string" + }, + "start_date": { + "format": "unix-time", + "type": "integer" + }, + "supported_types": { + "items": { + "enum": ["india"], + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "amount", + "amount_type", + "currency", + "interval", + "reference", + "start_date" + ], + "title": "setup_intent_mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string", + "x-stripeBypassValidation": true + }, + "three_d_secure": { + "properties": { + "ares_trans_status": { + "enum": ["A", "C", "I", "N", "R", "U", "Y"], + "type": "string" + }, + "cryptogram": { + "maxLength": 5000, + "type": "string" + }, + "electronic_commerce_indicator": { + "enum": ["01", "02", "05", "06", "07"], + "type": "string", + "x-stripeBypassValidation": true + }, + "network_options": { + "properties": { + "cartes_bancaires": { + "properties": { + "cb_avalgo": { + "enum": ["0", "1", "2", "3", "4", "A"], + "type": "string" + }, + "cb_exemption": { + "maxLength": 4, + "type": "string" + }, + "cb_score": { + "type": "integer" + } + }, + "required": ["cb_avalgo"], + "title": "cartes_bancaires_network_options_param", + "type": "object" + } + }, + "title": "network_options_param", + "type": "object" + }, + "requestor_challenge_indicator": { + "maxLength": 2, + "type": "string" + }, + "transaction_id": { + "maxLength": 5000, + "type": "string" + }, + "version": { + "enum": ["1.0.2", "2.1.0", "2.2.0"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + } + }, + "title": "setup_intent_param", + "type": "object" + }, + "card_present": { + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "paypal": { + "properties": { + "billing_agreement_id": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "mandate_options": { + "properties": {}, + "title": "payment_method_options_mandate_options_param", + "type": "object" + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, + "us_bank_account": { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "title": "linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "return_url": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "linked_account_options_param", + "type": "object" + }, + "mandate_options": { + "properties": { + "collection_method": { + "enum": ["", "paper"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "networks": { + "properties": { + "requested": { + "items": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "type": "array" + } + }, + "title": "networks_options_param", + "type": "object" + }, + "verification_method": { + "enum": ["automatic", "instant", "microdeposits"], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "setup_intent_payment_method_options_param", + "type": "object" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + "return_url": { + "description": "The URL to redirect your customer back to after they authenticate on the payment method's app or site.\nIf you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.\nThis parameter is only used for cards and other redirect-based payment methods.", + "type": "string" + }, + "use_stripe_sdk": { + "description": "Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/setup_intent" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/setup_intents/{intent}/verify_microdeposits": { + "post": { + "description": "

Verifies microdeposits on a SetupIntent object.

", + "operationId": "PostSetupIntentsIntentVerifyMicrodeposits", + "parameters": [ + { + "in": "path", + "name": "intent", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "amounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amounts": { + "description": "Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.", + "items": { + "type": "integer" + }, + "type": "array" + }, + "client_secret": { + "description": "The client secret of the SetupIntent.", + "maxLength": 5000, + "type": "string" + }, + "descriptor_code": { + "description": "A six-character code starting with SM present in the microdeposit sent to the bank account.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/setup_intent" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/shipping_rates": { + "get": { + "description": "

Returns a list of your shipping rates.

", + "operationId": "GetShippingRates", + "parameters": [ + { + "description": "Only return shipping rates that are active or inactive.", + "in": "query", + "name": "active", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return shipping rates for the given currency.", + "in": "query", + "name": "currency", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/shipping_rate" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/shipping_rates", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ShippingResourcesShippingRateList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new shipping rate object.

", + "operationId": "PostShippingRates", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "delivery_estimate": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "fixed_amount": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "delivery_estimate": { + "description": "The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.", + "properties": { + "maximum": { + "properties": { + "unit": { + "enum": [ + "business_day", + "day", + "hour", + "month", + "week" + ], + "type": "string" + }, + "value": { + "type": "integer" + } + }, + "required": ["unit", "value"], + "title": "delivery_estimate_bound", + "type": "object" + }, + "minimum": { + "properties": { + "unit": { + "enum": [ + "business_day", + "day", + "hour", + "month", + "week" + ], + "type": "string" + }, + "value": { + "type": "integer" + } + }, + "required": ["unit", "value"], + "title": "delivery_estimate_bound", + "type": "object" + } + }, + "title": "delivery_estimate", + "type": "object" + }, + "display_name": { + "description": "The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.", + "maxLength": 100, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "fixed_amount": { + "description": "Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.", + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + }, + "currency_options": { + "additionalProperties": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + } + }, + "required": ["amount"], + "title": "currency_option", + "type": "object" + }, + "type": "object" + } + }, + "required": ["amount", "currency"], + "title": "fixed_amount", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "tax_behavior": { + "description": "Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.", + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "tax_code": { + "description": "A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.", + "type": "string" + }, + "type": { + "description": "The type of calculation to use on the shipping rate.", + "enum": ["fixed_amount"], + "type": "string" + } + }, + "required": ["display_name"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/shipping_rate" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/shipping_rates/{shipping_rate_token}": { + "get": { + "description": "

Returns the shipping rate object with the given ID.

", + "operationId": "GetShippingRatesShippingRateToken", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "shipping_rate_token", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/shipping_rate" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates an existing shipping rate object.

", + "operationId": "PostShippingRatesShippingRateToken", + "parameters": [ + { + "in": "path", + "name": "shipping_rate_token", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "fixed_amount": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Whether the shipping rate can be used for new purchases. Defaults to `true`.", + "type": "boolean" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "fixed_amount": { + "description": "Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.", + "properties": { + "currency_options": { + "additionalProperties": { + "properties": { + "amount": { + "type": "integer" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + } + }, + "title": "currency_option_update", + "type": "object" + }, + "type": "object" + } + }, + "title": "fixed_amount_update", + "type": "object" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "tax_behavior": { + "description": "Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.", + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/shipping_rate" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/sigma/scheduled_query_runs": { + "get": { + "description": "

Returns a list of scheduled query runs.

", + "operationId": "GetSigmaScheduledQueryRuns", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/scheduled_query_run" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/sigma/scheduled_query_runs", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SigmaScheduledQueryRunList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/sigma/scheduled_query_runs/{scheduled_query_run}": { + "get": { + "description": "

Retrieves the details of an scheduled query run.

", + "operationId": "GetSigmaScheduledQueryRunsScheduledQueryRun", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "scheduled_query_run", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/scheduled_query_run" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/sources": { + "post": { + "description": "

Creates a new source object.

", + "operationId": "PostSources", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "mandate": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "owner": { + "explode": true, + "style": "deepObject" + }, + "receiver": { + "explode": true, + "style": "deepObject" + }, + "redirect": { + "explode": true, + "style": "deepObject" + }, + "source_order": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "Amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources. Not supported for `receiver` type sources, where charge amount may not be specified until funds land.", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready.", + "type": "string" + }, + "customer": { + "description": "The `Customer` to whom the original source is attached to. Must be set when the original source is not a `Source` (e.g., `Card`).", + "maxLength": 500, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "flow": { + "description": "The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows.", + "enum": [ + "code_verification", + "none", + "receiver", + "redirect" + ], + "maxLength": 5000, + "type": "string" + }, + "mandate": { + "description": "Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.", + "properties": { + "acceptance": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "offline": { + "properties": { + "contact_email": { + "type": "string" + } + }, + "required": ["contact_email"], + "title": "mandate_offline_acceptance_params", + "type": "object" + }, + "online": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "mandate_online_acceptance_params", + "type": "object" + }, + "status": { + "enum": [ + "accepted", + "pending", + "refused", + "revoked" + ], + "maxLength": 5000, + "type": "string" + }, + "type": { + "enum": ["offline", "online"], + "maxLength": 5000, + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["status"], + "title": "mandate_acceptance_params", + "type": "object" + }, + "amount": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "currency": { + "type": "string" + }, + "interval": { + "enum": ["one_time", "scheduled", "variable"], + "maxLength": 5000, + "type": "string" + }, + "notification_method": { + "enum": [ + "deprecated_none", + "email", + "manual", + "none", + "stripe_email" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "mandate_params", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "original_source": { + "description": "The source to share.", + "maxLength": 5000, + "type": "string" + }, + "owner": { + "description": "Information about the owner of the payment instrument that may be used or required by particular source types.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "source_address", + "type": "object" + }, + "email": { + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "owner", + "type": "object" + }, + "receiver": { + "description": "Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`).", + "properties": { + "refund_attributes_method": { + "enum": ["email", "manual", "none"], + "maxLength": 5000, + "type": "string" + } + }, + "title": "receiver_params", + "type": "object" + }, + "redirect": { + "description": "Parameters required for the redirect flow. Required if the source is authenticated by a redirect (`flow` is `redirect`).", + "properties": { + "return_url": { + "type": "string" + } + }, + "required": ["return_url"], + "title": "redirect_params", + "type": "object" + }, + "source_order": { + "description": "Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.", + "properties": { + "items": { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + }, + "description": { + "maxLength": 1000, + "type": "string" + }, + "parent": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + }, + "type": { + "enum": ["discount", "shipping", "sku", "tax"], + "maxLength": 5000, + "type": "string" + } + }, + "title": "order_item_specs", + "type": "object" + }, + "type": "array" + }, + "shipping": { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["line1"], + "title": "address", + "type": "object" + }, + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "tracking_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["address"], + "title": "order_shipping", + "type": "object" + } + }, + "title": "shallow_order_specs", + "type": "object" + }, + "statement_descriptor": { + "description": "An arbitrary string to be displayed on your customer's statement. As an example, if your website is `RunClub` and the item you're charging for is a race ticket, you may want to specify a `statement_descriptor` of `RunClub 5K race ticket.` While many payment types will display this information, some may not display it at all.", + "maxLength": 5000, + "type": "string" + }, + "token": { + "description": "An optional token used to create the source. When passed, token properties will override source parameters.", + "maxLength": 5000, + "type": "string" + }, + "type": { + "description": "The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide)", + "maxLength": 5000, + "type": "string" + }, + "usage": { + "enum": ["reusable", "single_use"], + "maxLength": 5000, + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/source" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/sources/{source}": { + "get": { + "description": "

Retrieves an existing source object. Supply the unique source ID from a source creation request and Stripe will return the corresponding up-to-date source object information.

", + "operationId": "GetSourcesSource", + "parameters": [ + { + "description": "The client secret of the source. Required if a publishable key is used to retrieve the source.", + "in": "query", + "name": "client_secret", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "source", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/source" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the specified source by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

This request accepts the metadata and owner as arguments. It is also possible to update type specific information for selected payment methods. Please refer to our payment method guides for more detail.

", + "operationId": "PostSourcesSource", + "parameters": [ + { + "in": "path", + "name": "source", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "mandate": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "owner": { + "explode": true, + "style": "deepObject" + }, + "source_order": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "Amount associated with the source.", + "type": "integer" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "mandate": { + "description": "Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.", + "properties": { + "acceptance": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "offline": { + "properties": { + "contact_email": { + "type": "string" + } + }, + "required": ["contact_email"], + "title": "mandate_offline_acceptance_params", + "type": "object" + }, + "online": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "mandate_online_acceptance_params", + "type": "object" + }, + "status": { + "enum": [ + "accepted", + "pending", + "refused", + "revoked" + ], + "maxLength": 5000, + "type": "string" + }, + "type": { + "enum": ["offline", "online"], + "maxLength": 5000, + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["status"], + "title": "mandate_acceptance_params", + "type": "object" + }, + "amount": { + "anyOf": [ + { + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "currency": { + "type": "string" + }, + "interval": { + "enum": ["one_time", "scheduled", "variable"], + "maxLength": 5000, + "type": "string" + }, + "notification_method": { + "enum": [ + "deprecated_none", + "email", + "manual", + "none", + "stripe_email" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "mandate_params", + "type": "object" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "owner": { + "description": "Information about the owner of the payment instrument that may be used or required by particular source types.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "source_address", + "type": "object" + }, + "email": { + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "owner", + "type": "object" + }, + "source_order": { + "description": "Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.", + "properties": { + "items": { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "currency": { + "type": "string" + }, + "description": { + "maxLength": 1000, + "type": "string" + }, + "parent": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + }, + "type": { + "enum": ["discount", "shipping", "sku", "tax"], + "maxLength": 5000, + "type": "string" + } + }, + "title": "order_item_specs", + "type": "object" + }, + "type": "array" + }, + "shipping": { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["line1"], + "title": "address", + "type": "object" + }, + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "tracking_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["address"], + "title": "order_shipping", + "type": "object" + } + }, + "title": "order_params", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/source" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/sources/{source}/mandate_notifications/{mandate_notification}": { + "get": { + "description": "

Retrieves a new Source MandateNotification.

", + "operationId": "GetSourcesSourceMandateNotificationsMandateNotification", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "mandate_notification", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "source", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/source_mandate_notification" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/sources/{source}/source_transactions": { + "get": { + "description": "

List source transactions for a given source.

", + "operationId": "GetSourcesSourceSourceTransactions", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "in": "path", + "name": "source", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/source_transaction" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "ApmsSourcesSourceTransactionList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/sources/{source}/source_transactions/{source_transaction}": { + "get": { + "description": "

Retrieve an existing source transaction object. Supply the unique source ID from a source creation request and the source transaction ID and Stripe will return the corresponding up-to-date source object information.

", + "operationId": "GetSourcesSourceSourceTransactionsSourceTransaction", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "source", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "source_transaction", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/source_transaction" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/sources/{source}/verify": { + "post": { + "description": "

Verify a given source.

", + "operationId": "PostSourcesSourceVerify", + "parameters": [ + { + "in": "path", + "name": "source", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "values": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "values": { + "description": "The values needed to verify the source.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "required": ["values"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/source" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscription_items": { + "get": { + "description": "

Returns a list of your subscription items for a given subscription.

", + "operationId": "GetSubscriptionItems", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "The ID of the subscription whose items will be retrieved.", + "in": "query", + "name": "subscription", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/subscription_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/subscription_items", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SubscriptionsItemsSubscriptionItemList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Adds a new item to an existing subscription. No existing items will be changed or replaced.

", + "operationId": "PostSubscriptionItems", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "billing_thresholds": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "price_data": { + "explode": true, + "style": "deepObject" + }, + "tax_rates": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription item." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "payment_behavior": { + "description": "Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.\n\nUse `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.", + "enum": [ + "allow_incomplete", + "default_incomplete", + "error_if_incomplete", + "pending_if_incomplete" + ], + "type": "string" + }, + "price": { + "description": "The ID of the price object.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "proration_date": { + "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.", + "format": "unix-time", + "type": "integer" + }, + "quantity": { + "description": "The quantity you'd like to apply to the subscription item you're creating.", + "type": "integer" + }, + "subscription": { + "description": "The identifier of the subscription to modify.", + "maxLength": 5000, + "type": "string" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." + } + }, + "required": ["subscription"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription_item" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscription_items/{item}": { + "delete": { + "description": "

Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.

", + "operationId": "DeleteSubscriptionItemsItem", + "parameters": [ + { + "in": "path", + "name": "item", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": { + "clear_usage": { + "description": "Delete all usage for the given subscription item. Allowed only when the current plan's `usage_type` is `metered`.", + "type": "boolean" + }, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "proration_date": { + "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.", + "format": "unix-time", + "type": "integer" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_subscription_item" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves the subscription item with the given ID.

", + "operationId": "GetSubscriptionItemsItem", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "item", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription_item" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates the plan or quantity of an item on a current subscription.

", + "operationId": "PostSubscriptionItemsItem", + "parameters": [ + { + "in": "path", + "name": "item", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "billing_thresholds": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "price_data": { + "explode": true, + "style": "deepObject" + }, + "tax_rates": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription item." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "off_session": { + "description": "Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).", + "type": "boolean" + }, + "payment_behavior": { + "description": "Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.\n\nUse `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.", + "enum": [ + "allow_incomplete", + "default_incomplete", + "error_if_incomplete", + "pending_if_incomplete" + ], + "type": "string" + }, + "price": { + "description": "The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.", + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "proration_date": { + "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.", + "format": "unix-time", + "type": "integer" + }, + "quantity": { + "description": "The quantity you'd like to apply to the subscription item you're creating.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription_item" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscription_items/{subscription_item}/usage_record_summaries": { + "get": { + "description": "

For the specified subscription item, returns a list of summary objects. Each object in the list provides usage information that’s been summarized from multiple usage records and over a subscription billing period (e.g., 15 usage records in the month of September).

\n\n

The list is sorted in reverse-chronological order (newest first). The first list item represents the most current usage period that hasn’t ended yet. Since new usage records can still be added, the returned summary information for the subscription item’s ID should be seen as unstable until the subscription billing period ends.

", + "operationId": "GetSubscriptionItemsSubscriptionItemUsageRecordSummaries", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "in": "path", + "name": "subscription_item", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/usage_record_summary" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "UsageEventsResourceUsageRecordSummaryList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscription_items/{subscription_item}/usage_records": { + "post": { + "description": "

Creates a usage record for a specified subscription item and date, and fills it with a quantity.

\n\n

Usage records provide quantity information that Stripe uses to track how much a customer is using your service. With usage information and the pricing model set up by the metered billing plan, Stripe helps you send accurate invoices to your customers.

\n\n

The default calculation for usage is to add up all the quantity values of the usage records within a billing period. You can change this default behavior with the billing plan’s aggregate_usage parameter. When there is more than one usage record with the same timestamp, Stripe adds the quantity values together. In most cases, this is the desired resolution, however, you can change this behavior with the action parameter.

\n\n

The default pricing model for metered billing is per-unit pricing. For finer granularity, you can configure metered billing to have a tiered pricing model.

", + "operationId": "PostSubscriptionItemsSubscriptionItemUsageRecords", + "parameters": [ + { + "in": "path", + "name": "subscription_item", + "required": true, + "schema": { + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "timestamp": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "action": { + "description": "Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value.", + "enum": ["increment", "set"], + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "quantity": { + "description": "The usage quantity for the specified timestamp.", + "type": "integer" + }, + "timestamp": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "The timestamp for the usage event. This timestamp must be within the current billing period of the subscription of the provided `subscription_item`, and must not be in the future. When passing `\"now\"`, Stripe records usage for the current time. Default is `\"now\"` if a value is not provided." + } + }, + "required": ["quantity"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/usage_record" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscription_schedules": { + "get": { + "description": "

Retrieves the list of your subscription schedules.

", + "operationId": "GetSubscriptionSchedules", + "parameters": [ + { + "description": "Only return subscription schedules that were created canceled the given date interval.", + "explode": true, + "in": "query", + "name": "canceled_at", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return subscription schedules that completed during the given date interval.", + "explode": true, + "in": "query", + "name": "completed_at", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return subscription schedules that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return subscription schedules for the given customer.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Only return subscription schedules that were released during the given date interval.", + "explode": true, + "in": "query", + "name": "released_at", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return subscription schedules that have not started yet.", + "in": "query", + "name": "scheduled", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/subscription_schedule" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/subscription_schedules", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SubscriptionSchedulesResourceScheduleList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new subscription schedule object. Each customer can have up to 500 active or scheduled subscriptions.

", + "operationId": "PostSubscriptionSchedules", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "default_settings": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "phases": { + "explode": true, + "style": "deepObject" + }, + "start_date": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "customer": { + "description": "The identifier of the customer to create the subscription schedule for.", + "maxLength": 5000, + "type": "string" + }, + "default_settings": { + "description": "Object representing the subscription schedule's default settings.", + "properties": { + "application_fee_percent": { + "type": "number" + }, + "automatic_tax": { + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "enum": ["automatic", "phase_start"], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "collection_method": { + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "default_payment_method": { + "maxLength": 5000, + "type": "string" + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "invoice_settings": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "days_until_due": { + "type": "integer" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "subscription_schedule_default_settings_param", + "type": "object" + }, + "on_behalf_of": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "transfer_data": { + "anyOf": [ + { + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "default_settings_params", + "type": "object" + }, + "end_behavior": { + "description": "Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.", + "enum": ["cancel", "none", "release", "renew"], + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "from_subscription": { + "description": "Migrate an existing subscription to be managed by a subscription schedule. If this parameter is set, a subscription schedule will be created using the subscription's item(s), set to auto-renew using the subscription's interval. When using this parameter, other parameters (such as phase values) cannot be set. To create a subscription schedule with other modifications, we recommend making two separate API calls.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "phases": { + "description": "List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.", + "items": { + "properties": { + "add_invoice_items": { + "items": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "add_invoice_item_entry", + "type": "object" + }, + "type": "array" + }, + "application_fee_percent": { + "type": "number" + }, + "automatic_tax": { + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "enum": ["automatic", "phase_start"], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "collection_method": { + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "currency": { + "type": "string" + }, + "default_payment_method": { + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "end_date": { + "format": "unix-time", + "type": "integer" + }, + "invoice_settings": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "days_until_due": { + "type": "integer" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings", + "type": "object" + }, + "items": { + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": [ + "day", + "month", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product", + "recurring" + ], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "configuration_item_params", + "type": "object" + }, + "type": "array" + }, + "iterations": { + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "on_behalf_of": { + "type": "string" + }, + "proration_behavior": { + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + }, + "transfer_data": { + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + "trial": { + "type": "boolean" + }, + "trial_end": { + "format": "unix-time", + "type": "integer" + } + }, + "required": ["items"], + "title": "phase_configuration_params", + "type": "object" + }, + "type": "array" + }, + "start_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ], + "description": "When the subscription schedule starts. We recommend using `now` so that it starts the subscription immediately. You can also use a Unix timestamp to backdate the subscription so that it starts on a past date, or set a future date for the subscription to start on." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription_schedule" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscription_schedules/{schedule}": { + "get": { + "description": "

Retrieves the details of an existing subscription schedule. You only need to supply the unique subscription schedule identifier that was returned upon subscription schedule creation.

", + "operationId": "GetSubscriptionSchedulesSchedule", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "schedule", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription_schedule" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates an existing subscription schedule.

", + "operationId": "PostSubscriptionSchedulesSchedule", + "parameters": [ + { + "in": "path", + "name": "schedule", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "default_settings": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "phases": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "default_settings": { + "description": "Object representing the subscription schedule's default settings.", + "properties": { + "application_fee_percent": { + "type": "number" + }, + "automatic_tax": { + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "enum": ["automatic", "phase_start"], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "collection_method": { + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "default_payment_method": { + "maxLength": 5000, + "type": "string" + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "invoice_settings": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "days_until_due": { + "type": "integer" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "subscription_schedule_default_settings_param", + "type": "object" + }, + "on_behalf_of": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "transfer_data": { + "anyOf": [ + { + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "default_settings_params", + "type": "object" + }, + "end_behavior": { + "description": "Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.", + "enum": ["cancel", "none", "release", "renew"], + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "phases": { + "description": "List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase. Note that past phases can be omitted.", + "items": { + "properties": { + "add_invoice_items": { + "items": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "add_invoice_item_entry", + "type": "object" + }, + "type": "array" + }, + "application_fee_percent": { + "type": "number" + }, + "automatic_tax": { + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "enum": ["automatic", "phase_start"], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "collection_method": { + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "default_payment_method": { + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "end_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + }, + "invoice_settings": { + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "days_until_due": { + "type": "integer" + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings", + "type": "object" + }, + "items": { + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": [ + "day", + "month", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product", + "recurring" + ], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "configuration_item_params", + "type": "object" + }, + "type": "array" + }, + "iterations": { + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "on_behalf_of": { + "type": "string" + }, + "proration_behavior": { + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + }, + "start_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + }, + "transfer_data": { + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + "trial": { + "type": "boolean" + }, + "trial_end": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + } + ] + } + }, + "required": ["items"], + "title": "phase_configuration_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "description": "If the update changes the current phase, indicates whether the changes should be prorated. The default value is `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription_schedule" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscription_schedules/{schedule}/cancel": { + "post": { + "description": "

Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active.

", + "operationId": "PostSubscriptionSchedulesScheduleCancel", + "parameters": [ + { + "in": "path", + "name": "schedule", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "invoice_now": { + "description": "If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Defaults to `true`.", + "type": "boolean" + }, + "prorate": { + "description": "If the subscription schedule is `active`, indicates if the cancellation should be prorated. Defaults to `true`.", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription_schedule" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscription_schedules/{schedule}/release": { + "post": { + "description": "

Releases the subscription schedule immediately, which will stop scheduling of its phases, but leave any existing subscription in place. A schedule can only be released if its status is not_started or active. If the subscription schedule is currently associated with a subscription, releasing it will remove its subscription property and set the subscription’s ID to the released_subscription property.

", + "operationId": "PostSubscriptionSchedulesScheduleRelease", + "parameters": [ + { + "in": "path", + "name": "schedule", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "preserve_cancel_date": { + "description": "Keep any cancellation on the subscription that the schedule has set", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription_schedule" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscriptions": { + "get": { + "description": "

By default, returns a list of subscriptions that have not been canceled. In order to list canceled subscriptions, specify status=canceled.

", + "operationId": "GetSubscriptions", + "parameters": [ + { + "description": "Filter subscriptions by their automatic tax settings.", + "explode": true, + "in": "query", + "name": "automatic_tax", + "required": false, + "schema": { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "automatic_tax_filter_params", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "The collection method of the subscriptions to retrieve. Either `charge_automatically` or `send_invoice`.", + "in": "query", + "name": "collection_method", + "required": false, + "schema": { + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return subscriptions that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "explode": true, + "in": "query", + "name": "current_period_end", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "explode": true, + "in": "query", + "name": "current_period_start", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "The ID of the customer whose subscriptions will be retrieved.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Filter for subscriptions that contain this recurring price ID.", + "in": "query", + "name": "price", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "The status of the subscriptions to retrieve. Passing in a value of `canceled` will return all canceled subscriptions, including those belonging to deleted customers. Pass `ended` to find subscriptions that are canceled and subscriptions that are expired due to [incomplete payment](https://stripe.com/docs/billing/subscriptions/overview#subscription-statuses). Passing in a value of `all` will return subscriptions of all statuses. If no value is supplied, all subscriptions that have not been canceled are returned.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": [ + "active", + "all", + "canceled", + "ended", + "incomplete", + "incomplete_expired", + "past_due", + "paused", + "trialing", + "unpaid" + ], + "type": "string" + }, + "style": "form" + }, + { + "description": "Filter for subscriptions that are associated with the specified test clock. The response will not include subscriptions with test clocks if this and the customer parameter is not set.", + "in": "query", + "name": "test_clock", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/subscription" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/subscriptions", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SubscriptionsSubscriptionList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new subscription on an existing customer. Each customer can have up to 500 active or scheduled subscriptions.

\n\n

When you create a subscription with collection_method=charge_automatically, the first invoice is finalized as part of the request.\nThe payment_behavior parameter determines the exact behavior of the initial payment.

\n\n

To start subscriptions where the first invoice always begins in a draft status, use subscription schedules instead.\nSchedules provide the flexibility to model more complex billing configurations that change over time.

", + "operationId": "PostSubscriptions", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "add_invoice_items": { + "explode": true, + "style": "deepObject" + }, + "application_fee_percent": { + "explode": true, + "style": "deepObject" + }, + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "billing_cycle_anchor_config": { + "explode": true, + "style": "deepObject" + }, + "billing_thresholds": { + "explode": true, + "style": "deepObject" + }, + "default_tax_rates": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "invoice_settings": { + "explode": true, + "style": "deepObject" + }, + "items": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "on_behalf_of": { + "explode": true, + "style": "deepObject" + }, + "payment_settings": { + "explode": true, + "style": "deepObject" + }, + "pending_invoice_item_interval": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { + "explode": true, + "style": "deepObject" + }, + "trial_end": { + "explode": true, + "style": "deepObject" + }, + "trial_settings": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "add_invoice_items": { + "description": "A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.", + "items": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "add_invoice_item_entry", + "type": "object" + }, + "type": "array" + }, + "application_fee_percent": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions)." + }, + "automatic_tax": { + "description": "Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_config", + "type": "object" + }, + "backdate_start_date": { + "description": "For new subscriptions, a past timestamp to backdate the subscription's start date to. If set, the first invoice will contain a proration for the timespan between the start date and the current time. Can be combined with trials and the billing cycle anchor.", + "format": "unix-time", + "type": "integer" + }, + "billing_cycle_anchor": { + "description": "A future timestamp in UTC format to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). The anchor is the reference point that aligns future billing cycle dates. It sets the day of week for `week` intervals, the day of month for `month` and `year` intervals, and the month of year for `year` intervals.", + "format": "unix-time", + "type": "integer", + "x-stripeBypassValidation": true + }, + "billing_cycle_anchor_config": { + "description": "Mutually exclusive with billing_cycle_anchor and only valid with monthly and yearly price intervals. When provided, the billing_cycle_anchor is set to the next occurence of the day_of_month at the hour, minute, and second UTC.", + "properties": { + "day_of_month": { + "type": "integer" + }, + "hour": { + "type": "integer" + }, + "minute": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "second": { + "type": "integer" + } + }, + "required": ["day_of_month"], + "title": "billing_cycle_anchor_config_param", + "type": "object" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." + }, + "cancel_at": { + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.", + "format": "unix-time", + "type": "integer" + }, + "cancel_at_period_end": { + "description": "Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.", + "type": "boolean" + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "coupon": { + "description": "The ID of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "The identifier of the customer to subscribe.", + "maxLength": 5000, + "type": "string" + }, + "days_until_due": { + "description": "Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.", + "type": "integer" + }, + "default_payment_method": { + "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "maxLength": 5000, + "type": "string" + }, + "default_source": { + "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription." + }, + "description": { + "description": "The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.", + "maxLength": 500, + "type": "string" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "invoice_settings": { + "description": "All invoices will be billed using the specified settings.", + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings_param", + "type": "object" + }, + "items": { + "description": "A list of up to 20 subscription items, each with an attached price.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "subscription_item_create_params", + "type": "object" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "off_session": { + "description": "Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).", + "type": "boolean" + }, + "on_behalf_of": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The account on behalf of which to charge, for each of the subscription's invoices." + }, + "payment_behavior": { + "description": "Only applies to subscriptions with `collection_method=charge_automatically`.\n\nUse `allow_incomplete` to create Subscriptions with `status=incomplete` if the first invoice can't be paid. Creating Subscriptions with this status allows you to manage scenarios where additional customer actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `default_incomplete` to create Subscriptions with `status=incomplete` when the first invoice requires payment, otherwise start as active. Subscriptions transition to `status=active` when successfully confirming the PaymentIntent on the first invoice. This allows simpler management of scenarios where additional customer actions are needed to pay a subscription’s invoice, such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method. If the PaymentIntent is not confirmed within 23 hours Subscriptions transition to `status=incomplete_expired`, which is a terminal state.\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice can't be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further customer action is needed, this parameter doesn't create a Subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.\n\n`pending_if_incomplete` is only used with updates and cannot be passed when creating a Subscription.\n\nSubscriptions with `collection_method=send_invoice` are automatically activated regardless of the first Invoice status.", + "enum": [ + "allow_incomplete", + "default_incomplete", + "error_if_incomplete", + "pending_if_incomplete" + ], + "type": "string" + }, + "payment_settings": { + "description": "Payment settings to pass to invoices created by the subscription.", + "properties": { + "payment_method_options": { + "properties": { + "acss_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bancontact": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": ["de", "en", "fr", "nl"], + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string" + } + }, + "title": "subscription_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "customer_balance": { + "anyOf": [ + { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_param", + "type": "object" + }, + "type": { + "type": "string" + } + }, + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "konbini": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "type": "string" + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_method_options", + "type": "object" + }, + "payment_method_types": { + "anyOf": [ + { + "items": { + "enum": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "konbini", + "link", + "multibanco", + "p24", + "paynow", + "paypal", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "us_bank_account", + "wechat_pay" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "save_default_payment_method": { + "enum": ["off", "on_subscription"], + "type": "string" + } + }, + "title": "payment_settings", + "type": "object" + }, + "pending_invoice_item_interval": { + "anyOf": [ + { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "pending_invoice_item_interval_params", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval." + }, + "promotion_code": { + "description": "The promotion code to apply to this subscription. A promotion code applied to a subscription will only affect invoices created for that particular subscription. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "transfer_data": { + "description": "If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.", + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + "trial_end": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more." + }, + "trial_from_plan": { + "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.", + "type": "boolean" + }, + "trial_period_days": { + "description": "Integer representing the number of trial period days before the customer is charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.", + "type": "integer" + }, + "trial_settings": { + "description": "Settings related to subscription trials.", + "properties": { + "end_behavior": { + "properties": { + "missing_payment_method": { + "enum": ["cancel", "create_invoice", "pause"], + "type": "string" + } + }, + "required": ["missing_payment_method"], + "title": "end_behavior", + "type": "object" + } + }, + "required": ["end_behavior"], + "title": "trial_settings_config", + "type": "object" + } + }, + "required": ["customer"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscriptions/search": { + "get": { + "description": "

Search for subscriptions you’ve previously created using Stripe’s Search Query Language.\nDon’t use search in read-after-write flows where strict consistency is necessary. Under normal operating\nconditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up\nto an hour behind during outages. Search functionality is not available to merchants in India.

", + "operationId": "GetSubscriptionsSearch", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.", + "in": "query", + "name": "page", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for subscriptions](https://stripe.com/docs/search#query-fields-for-subscriptions).", + "in": "query", + "name": "query", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/subscription" + }, + "type": "array" + }, + "has_more": { + "type": "boolean" + }, + "next_page": { + "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": ["search_result"], + "type": "string" + }, + "total_count": { + "description": "The total number of objects that match the query, only accurate up to 10,000.", + "type": "integer" + }, + "url": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "SearchResult", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscriptions/{subscription_exposed_id}": { + "delete": { + "description": "

Cancels a customer’s subscription immediately. The customer will not be charged again for the subscription.

\n\n

Note, however, that any pending invoice items that you’ve created will still be charged for at the end of the period, unless manually deleted. If you’ve set the subscription to cancel at the end of the period, any pending prorations will also be left in place and collected at the end of the period. But if the subscription is set to cancel immediately, pending prorations will be removed.

\n\n

By default, upon subscription cancellation, Stripe will stop automatic collection of all finalized invoices for the customer. This is intended to prevent unexpected payment attempts after the customer has canceled a subscription. However, you can resume automatic collection of the invoices manually after subscription cancellation to have us proceed. Or, you could check for unpaid invoices before allowing the customer to cancel the subscription at all.

", + "operationId": "DeleteSubscriptionsSubscriptionExposedId", + "parameters": [ + { + "in": "path", + "name": "subscription_exposed_id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "cancellation_details": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "cancellation_details": { + "description": "Details about why this subscription was cancelled", + "properties": { + "comment": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "feedback": { + "enum": [ + "", + "customer_service", + "low_quality", + "missing_features", + "other", + "switched_service", + "too_complex", + "too_expensive", + "unused" + ], + "type": "string" + } + }, + "title": "cancellation_details_param", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "invoice_now": { + "description": "Will generate a final invoice that invoices for any un-invoiced metered usage and new/pending proration invoice items. Defaults to `true`.", + "type": "boolean" + }, + "prorate": { + "description": "Will generate a proration invoice item that credits remaining unused time until the subscription period end. Defaults to `false`.", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves the subscription with the given ID.

", + "operationId": "GetSubscriptionsSubscriptionExposedId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "subscription_exposed_id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates an existing subscription to match the specified parameters.\nWhen changing prices or quantities, we optionally prorate the price we charge next month to make up for any price changes.\nTo preview how the proration is calculated, use the create preview endpoint.

\n\n

By default, we prorate subscription changes. For example, if a customer signs up on May 1 for a 100 price, they’ll be billed 100 immediately. If on May 15 they switch to a 200 price, then on June 1 they’ll be billed 250 (200 for a renewal of her subscription, plus a 50 prorating adjustment for half of the previous month’s 100 difference). Similarly, a downgrade generates a credit that is applied to the next invoice. We also prorate when you make quantity changes.

\n\n

Switching prices does not normally change the billing date or generate an immediate charge unless:

\n\n
    \n
  • The billing interval is changed (for example, from monthly to yearly).
  • \n
  • The subscription moves from free to paid.
  • \n
  • A trial starts or ends.
  • \n
\n\n

In these cases, we apply a credit for the unused time on the previous price, immediately charge the customer using the new price, and reset the billing date. Learn about how Stripe immediately attempts payment for subscription changes.

\n\n

If you want to charge for an upgrade immediately, pass proration_behavior as always_invoice to create prorations, automatically invoice the customer for those proration adjustments, and attempt to collect payment. If you pass create_prorations, the prorations are created but not automatically invoiced. If you want to bill the customer for the prorations before the subscription’s renewal date, you need to manually invoice the customer.

\n\n

If you don’t want to prorate, set the proration_behavior option to none. With this option, the customer is billed 100 on May 1 and 200 on June 1. Similarly, if you set proration_behavior to none when switching between different billing intervals (for example, from monthly to yearly), we don’t generate any credits for the old subscription’s unused time. We still reset the billing date and bill immediately for the new subscription.

\n\n

Updating the quantity on a subscription many times in an hour may result in rate limiting. If you need to bill for a frequently changing quantity, consider integrating usage-based billing instead.

", + "operationId": "PostSubscriptionsSubscriptionExposedId", + "parameters": [ + { + "in": "path", + "name": "subscription_exposed_id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "add_invoice_items": { + "explode": true, + "style": "deepObject" + }, + "application_fee_percent": { + "explode": true, + "style": "deepObject" + }, + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "billing_thresholds": { + "explode": true, + "style": "deepObject" + }, + "cancel_at": { + "explode": true, + "style": "deepObject" + }, + "cancellation_details": { + "explode": true, + "style": "deepObject" + }, + "default_source": { + "explode": true, + "style": "deepObject" + }, + "default_tax_rates": { + "explode": true, + "style": "deepObject" + }, + "description": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "invoice_settings": { + "explode": true, + "style": "deepObject" + }, + "items": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "on_behalf_of": { + "explode": true, + "style": "deepObject" + }, + "pause_collection": { + "explode": true, + "style": "deepObject" + }, + "payment_settings": { + "explode": true, + "style": "deepObject" + }, + "pending_invoice_item_interval": { + "explode": true, + "style": "deepObject" + }, + "transfer_data": { + "explode": true, + "style": "deepObject" + }, + "trial_end": { + "explode": true, + "style": "deepObject" + }, + "trial_settings": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "add_invoice_items": { + "description": "A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.", + "items": { + "properties": { + "discounts": { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product"], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "add_invoice_item_entry", + "type": "object" + }, + "type": "array" + }, + "application_fee_percent": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions)." + }, + "automatic_tax": { + "description": "Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.", + "properties": { + "enabled": { + "type": "boolean" + }, + "liability": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "required": ["enabled"], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "description": "Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time (in UTC). For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", + "enum": ["now", "unchanged"], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." + }, + "cancel_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period." + }, + "cancel_at_period_end": { + "description": "Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`.", + "type": "boolean" + }, + "cancellation_details": { + "description": "Details about why this subscription was cancelled", + "properties": { + "comment": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "feedback": { + "enum": [ + "", + "customer_service", + "low_quality", + "missing_features", + "other", + "switched_service", + "too_complex", + "too_expensive", + "unused" + ], + "type": "string" + } + }, + "title": "cancellation_details_param", + "type": "object" + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.", + "enum": ["charge_automatically", "send_invoice"], + "type": "string" + }, + "coupon": { + "description": "The ID of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "days_until_due": { + "description": "Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.", + "type": "integer" + }, + "default_payment_method": { + "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "maxLength": 5000, + "type": "string" + }, + "default_source": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source)." + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates." + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "invoice_settings": { + "description": "All invoices will be billed using the specified settings.", + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "issuer": { + "properties": { + "account": { + "type": "string" + }, + "type": { + "enum": ["account", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings_param", + "type": "object" + }, + "items": { + "description": "A list of up to 20 subscription items, each with an attached price.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "type": "integer" + } + }, + "required": ["usage_gte"], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "clear_usage": { + "type": "boolean" + }, + "deleted": { + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "maxLength": 5000, + "type": "string" + }, + "discount": { + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "id": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "price": { + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "properties": { + "currency": { + "type": "string" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive", "unspecified"], + "type": "string" + }, + "unit_amount": { + "type": "integer" + }, + "unit_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "required": ["currency", "product", "recurring"], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "subscription_item_update_params", + "type": "object" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "off_session": { + "description": "Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).", + "type": "boolean" + }, + "on_behalf_of": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The account on behalf of which to charge, for each of the subscription's invoices." + }, + "pause_collection": { + "anyOf": [ + { + "properties": { + "behavior": { + "enum": [ + "keep_as_draft", + "mark_uncollectible", + "void" + ], + "type": "string" + }, + "resumes_at": { + "format": "unix-time", + "type": "integer" + } + }, + "required": ["behavior"], + "title": "pause_collection_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](/billing/subscriptions/pause-payment)." + }, + "payment_behavior": { + "description": "Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.\n\nUse `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.", + "enum": [ + "allow_incomplete", + "default_incomplete", + "error_if_incomplete", + "pending_if_incomplete" + ], + "type": "string" + }, + "payment_settings": { + "description": "Payment settings to pass to invoices created by the subscription.", + "properties": { + "payment_method_options": { + "properties": { + "acss_debit": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "transaction_type": { + "enum": ["business", "personal"], + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "bancontact": { + "anyOf": [ + { + "properties": { + "preferred_language": { + "enum": ["de", "en", "fr", "nl"], + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "card": { + "anyOf": [ + { + "properties": { + "mandate_options": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_type": { + "enum": ["fixed", "maximum"], + "type": "string" + }, + "description": { + "maxLength": 200, + "type": "string" + } + }, + "title": "mandate_options_param", + "type": "object" + }, + "network": { + "enum": [ + "amex", + "cartes_bancaires", + "diners", + "discover", + "eftpos_au", + "girocard", + "interac", + "jcb", + "mastercard", + "unionpay", + "unknown", + "visa" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "request_three_d_secure": { + "enum": ["any", "automatic", "challenge"], + "type": "string" + } + }, + "title": "subscription_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "customer_balance": { + "anyOf": [ + { + "properties": { + "bank_transfer": { + "properties": { + "eu_bank_transfer": { + "properties": { + "country": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "eu_bank_transfer_param", + "type": "object" + }, + "type": { + "type": "string" + } + }, + "title": "bank_transfer_param", + "type": "object" + }, + "funding_type": { + "type": "string" + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "konbini": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "sepa_debit": { + "anyOf": [ + { + "properties": {}, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "us_bank_account": { + "anyOf": [ + { + "properties": { + "financial_connections": { + "properties": { + "filters": { + "properties": { + "account_subcategories": { + "items": { + "enum": ["checking", "savings"], + "type": "string" + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_filters_param", + "type": "object" + }, + "permissions": { + "items": { + "enum": [ + "balances", + "ownership", + "payment_method", + "transactions" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + "prefetch": { + "items": { + "enum": [ + "balances", + "ownership", + "transactions" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + } + }, + "title": "invoice_linked_account_options_param", + "type": "object" + }, + "verification_method": { + "enum": [ + "automatic", + "instant", + "microdeposits" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "invoice_payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_method_options", + "type": "object" + }, + "payment_method_types": { + "anyOf": [ + { + "items": { + "enum": [ + "ach_credit_transfer", + "ach_debit", + "acss_debit", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "boleto", + "card", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "konbini", + "link", + "multibanco", + "p24", + "paynow", + "paypal", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "us_bank_account", + "wechat_pay" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "save_default_payment_method": { + "enum": ["off", "on_subscription"], + "type": "string" + } + }, + "title": "payment_settings", + "type": "object" + }, + "pending_invoice_item_interval": { + "anyOf": [ + { + "properties": { + "interval": { + "enum": ["day", "month", "week", "year"], + "type": "string" + }, + "interval_count": { + "type": "integer" + } + }, + "required": ["interval"], + "title": "pending_invoice_item_interval_params", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval." + }, + "promotion_code": { + "description": "The promotion code to apply to this subscription. A promotion code applied to a subscription will only affect invoices created for that particular subscription. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "proration_date": { + "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same proration that was previewed with [upcoming invoice](https://stripe.com/docs/api#upcoming_invoice) endpoint. It can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.", + "format": "unix-time", + "type": "integer" + }, + "transfer_data": { + "anyOf": [ + { + "properties": { + "amount_percent": { + "type": "number" + }, + "destination": { + "type": "string" + } + }, + "required": ["destination"], + "title": "transfer_data_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value." + }, + "trial_end": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`." + }, + "trial_from_plan": { + "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.", + "type": "boolean" + }, + "trial_settings": { + "description": "Settings related to subscription trials.", + "properties": { + "end_behavior": { + "properties": { + "missing_payment_method": { + "enum": ["cancel", "create_invoice", "pause"], + "type": "string" + } + }, + "required": ["missing_payment_method"], + "title": "end_behavior", + "type": "object" + } + }, + "required": ["end_behavior"], + "title": "trial_settings_config", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscriptions/{subscription_exposed_id}/discount": { + "delete": { + "description": "

Removes the currently applied discount on a subscription.

", + "operationId": "DeleteSubscriptionsSubscriptionExposedIdDiscount", + "parameters": [ + { + "in": "path", + "name": "subscription_exposed_id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_discount" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/subscriptions/{subscription}/resume": { + "post": { + "description": "

Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.

", + "operationId": "PostSubscriptionsSubscriptionResume", + "parameters": [ + { + "in": "path", + "name": "subscription", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "billing_cycle_anchor": { + "description": "Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time (in UTC). Setting the value to `unchanged` advances the subscription's billing cycle anchor to the period that surrounds the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", + "enum": ["now", "unchanged"], + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "enum": ["always_invoice", "create_prorations", "none"], + "type": "string" + }, + "proration_date": { + "description": "If set, the proration will be calculated as though the subscription was resumed at the given time. This can be used to apply exactly the same proration that was previewed with [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.", + "format": "unix-time", + "type": "integer" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/subscription" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/calculations": { + "post": { + "description": "

Calculates tax based on the input and returns a Tax Calculation object.

", + "operationId": "PostTaxCalculations", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "customer_details": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "line_items": { + "explode": true, + "style": "deepObject" + }, + "ship_from_details": { + "explode": true, + "style": "deepObject" + }, + "shipping_cost": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "The ID of an existing customer to use for this calculation. If provided, the customer's address and tax IDs are copied to `customer_details`.", + "maxLength": 5000, + "type": "string" + }, + "customer_details": { + "description": "Details about the customer, including address and tax IDs.", + "properties": { + "address": { + "properties": { + "city": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "line2": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "postal_code": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "state": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "required": ["country"], + "title": "postal_address", + "type": "object" + }, + "address_source": { + "enum": ["billing", "shipping"], + "type": "string" + }, + "ip_address": { + "type": "string" + }, + "tax_ids": { + "items": { + "properties": { + "type": { + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "value": { + "type": "string" + } + }, + "required": ["type", "value"], + "title": "data_params", + "type": "object" + }, + "type": "array" + }, + "taxability_override": { + "enum": ["customer_exempt", "none", "reverse_charge"], + "type": "string" + } + }, + "title": "customer_details", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "line_items": { + "description": "A list of items the customer is purchasing.", + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "product": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + }, + "reference": { + "maxLength": 500, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive"], + "type": "string" + }, + "tax_code": { + "type": "string" + } + }, + "required": ["amount"], + "title": "calculation_line_item", + "type": "object" + }, + "type": "array" + }, + "ship_from_details": { + "description": "Details about the address from which the goods are being shipped.", + "properties": { + "address": { + "properties": { + "city": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "line2": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "postal_code": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "state": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "required": ["country"], + "title": "merchant_postal_address", + "type": "object" + } + }, + "required": ["address"], + "title": "ship_from_details", + "type": "object" + }, + "shipping_cost": { + "description": "Shipping cost details to be used for the calculation.", + "properties": { + "amount": { + "type": "integer" + }, + "shipping_rate": { + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "enum": ["exclusive", "inclusive"], + "type": "string" + }, + "tax_code": { + "type": "string" + } + }, + "title": "shipping_cost", + "type": "object" + }, + "tax_date": { + "description": "Timestamp of date at which the tax rules and rates in effect applies for the calculation. Measured in seconds since the Unix epoch. Can be up to 48 hours in the past, and up to 48 hours in the future.", + "type": "integer" + } + }, + "required": ["currency", "line_items"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.calculation" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/calculations/{calculation}": { + "get": { + "description": "

Retrieves a Tax Calculation object, if the calculation hasn’t expired.

", + "operationId": "GetTaxCalculationsCalculation", + "parameters": [ + { + "in": "path", + "name": "calculation", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.calculation" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/calculations/{calculation}/line_items": { + "get": { + "description": "

Retrieves the line items of a tax calculation as a collection, if the calculation hasn’t expired.

", + "operationId": "GetTaxCalculationsCalculationLineItems", + "parameters": [ + { + "in": "path", + "name": "calculation", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 500, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 500, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/tax.calculation_line_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/tax/calculations/[^/]+/line_items", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TaxProductResourceTaxCalculationLineItemList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/registrations": { + "get": { + "description": "

Returns a list of Tax Registration objects.

", + "operationId": "GetTaxRegistrations", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "The status of the Tax Registration.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["active", "all", "expired", "scheduled"], + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/tax.registration" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/tax/registrations", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TaxProductRegistrationsResourceTaxRegistrationList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new Tax Registration object.

", + "operationId": "PostTaxRegistrations", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "active_from": { + "explode": true, + "style": "deepObject" + }, + "country_options": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "active_from": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "Time at which the Tax Registration becomes active. It can be either `now` to indicate the current time, or a future timestamp measured in seconds since the Unix epoch." + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "country_options": { + "description": "Specific options for a registration in the specified `country`.", + "properties": { + "ae": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "at": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "au": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "be": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "bg": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "bh": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "ca": { + "properties": { + "province_standard": { + "properties": { + "province": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["province"], + "title": "province_standard", + "type": "object" + }, + "type": { + "enum": [ + "province_standard", + "simplified", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "canada", + "type": "object" + }, + "ch": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "cl": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "co": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "cy": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "cz": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "de": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "dk": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "ee": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "eg": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "es": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "fi": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "fr": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "gb": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "ge": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "gr": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "hr": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "hu": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "id": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "ie": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "is": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "it": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "jp": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "ke": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "kr": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "kz": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "lt": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "lu": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "lv": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "mt": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "mx": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "my": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "ng": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "nl": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "no": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "nz": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "om": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "pl": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "pt": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "ro": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "sa": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "se": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "sg": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + }, + "si": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "sk": { + "properties": { + "standard": { + "properties": { + "place_of_supply_scheme": { + "enum": ["small_seller", "standard"], + "type": "string" + } + }, + "required": ["place_of_supply_scheme"], + "title": "standard", + "type": "object" + }, + "type": { + "enum": [ + "ioss", + "oss_non_union", + "oss_union", + "standard" + ], + "type": "string" + } + }, + "required": ["type"], + "title": "europe", + "type": "object" + }, + "th": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "tr": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "us": { + "properties": { + "local_amusement_tax": { + "properties": { + "jurisdiction": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["jurisdiction"], + "title": "local_amusement_tax", + "type": "object" + }, + "local_lease_tax": { + "properties": { + "jurisdiction": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["jurisdiction"], + "title": "local_lease_tax", + "type": "object" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "type": { + "enum": [ + "local_amusement_tax", + "local_lease_tax", + "state_communications_tax", + "state_sales_tax" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["state", "type"], + "title": "united_states", + "type": "object" + }, + "vn": { + "properties": { + "type": { + "enum": ["simplified"], + "type": "string" + } + }, + "required": ["type"], + "title": "simplified", + "type": "object" + }, + "za": { + "properties": { + "type": { + "enum": ["standard"], + "type": "string" + } + }, + "required": ["type"], + "title": "default", + "type": "object" + } + }, + "title": "country_options", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "expires_at": { + "description": "If set, the Tax Registration stops being active at this time. If not set, the Tax Registration will be active indefinitely. Timestamp measured in seconds since the Unix epoch.", + "format": "unix-time", + "type": "integer" + } + }, + "required": ["active_from", "country", "country_options"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.registration" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/registrations/{id}": { + "get": { + "description": "

Returns a Tax Registration object.

", + "operationId": "GetTaxRegistrationsId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.registration" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates an existing Tax Registration object.

\n\n

A registration cannot be deleted after it has been created. If you wish to end a registration you may do so by setting expires_at.

", + "operationId": "PostTaxRegistrationsId", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "active_from": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "expires_at": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "active_from": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "Time at which the registration becomes active. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "expires_at": { + "anyOf": [ + { + "enum": ["now"], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "If set, the registration stops being active at this time. If not set, the registration will be active indefinitely. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.registration" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/settings": { + "get": { + "description": "

Retrieves Tax Settings for a merchant.

", + "operationId": "GetTaxSettings", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.settings" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates Tax Settings parameters used in tax calculations. All parameters are editable but none can be removed once set.

", + "operationId": "PostTaxSettings", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "defaults": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "head_office": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "defaults": { + "description": "Default configuration to be used on Stripe Tax calculations.", + "properties": { + "tax_behavior": { + "enum": [ + "exclusive", + "inclusive", + "inferred_by_currency" + ], + "type": "string" + }, + "tax_code": { + "type": "string" + } + }, + "title": "defaults_param", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "head_office": { + "description": "The place where your business is located.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "validated_country_address", + "type": "object" + } + }, + "required": ["address"], + "title": "head_office_param", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.settings" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/transactions/create_from_calculation": { + "post": { + "description": "

Creates a Tax Transaction from a calculation, if that calculation hasn’t expired. Calculations expire after 90 days.

", + "operationId": "PostTaxTransactionsCreateFromCalculation", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "calculation": { + "description": "Tax Calculation ID to be used as input when creating the transaction.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "posted_at": { + "description": "The Unix timestamp representing when the tax liability is assumed or reduced, which determines the liability posting period and handling in tax liability reports. The timestamp must fall within the `tax_date` and the current time, unless the `tax_date` is scheduled in advance. Defaults to the current time.", + "format": "unix-time", + "type": "integer" + }, + "reference": { + "description": "A custom order or sale identifier, such as 'myOrder_123'. Must be unique across all transactions, including reversals.", + "maxLength": 500, + "type": "string" + } + }, + "required": ["calculation", "reference"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.transaction" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/transactions/create_reversal": { + "post": { + "description": "

Partially or fully reverses a previously created Transaction.

", + "operationId": "PostTaxTransactionsCreateReversal", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "line_items": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "shipping_cost": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "flat_amount": { + "description": "A flat amount to reverse across the entire transaction, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative. This value represents the total amount to refund from the transaction, including taxes.", + "type": "integer" + }, + "line_items": { + "description": "The line item amounts to reverse.", + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "amount_tax": { + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "original_line_item": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + }, + "reference": { + "maxLength": 500, + "type": "string" + } + }, + "required": [ + "amount", + "amount_tax", + "original_line_item", + "reference" + ], + "title": "transaction_line_item_reversal", + "type": "object" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "mode": { + "description": "If `partial`, the provided line item or shipping cost amounts are reversed. If `full`, the original transaction is fully reversed.", + "enum": ["full", "partial"], + "type": "string" + }, + "original_transaction": { + "description": "The ID of the Transaction to partially or fully reverse.", + "maxLength": 5000, + "type": "string" + }, + "reference": { + "description": "A custom identifier for this reversal, such as `myOrder_123-refund_1`, which must be unique across all transactions. The reference helps identify this reversal transaction in exported [tax reports](https://stripe.com/docs/tax/reports).", + "maxLength": 500, + "type": "string" + }, + "shipping_cost": { + "description": "The shipping cost to reverse.", + "properties": { + "amount": { + "type": "integer" + }, + "amount_tax": { + "type": "integer" + } + }, + "required": ["amount", "amount_tax"], + "title": "transaction_shipping_cost_reversal", + "type": "object" + } + }, + "required": ["mode", "original_transaction", "reference"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.transaction" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/transactions/{transaction}": { + "get": { + "description": "

Retrieves a Tax Transaction object.

", + "operationId": "GetTaxTransactionsTransaction", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "transaction", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax.transaction" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax/transactions/{transaction}/line_items": { + "get": { + "description": "

Retrieves the line items of a committed standalone transaction as a collection.

", + "operationId": "GetTaxTransactionsTransactionLineItems", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 500, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 500, + "type": "string" + }, + "style": "form" + }, + { + "in": "path", + "name": "transaction", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/tax.transaction_line_item" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/tax/transactions/[^/]+/line_items", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TaxProductResourceTaxTransactionLineItemList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax_codes": { + "get": { + "description": "

A list of all tax codes available to add to Products in order to allow specific tax calculations.

", + "operationId": "GetTaxCodes", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/tax_code" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TaxProductResourceTaxCodeList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax_codes/{id}": { + "get": { + "description": "

Retrieves the details of an existing tax code. Supply the unique tax code ID and Stripe will return the corresponding tax code information.

", + "operationId": "GetTaxCodesId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax_code" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax_ids": { + "get": { + "description": "

Returns a list of tax IDs.

", + "operationId": "GetTaxIds", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.", + "explode": true, + "in": "query", + "name": "owner", + "required": false, + "schema": { + "properties": { + "account": { + "type": "string" + }, + "customer": { + "maxLength": 5000, + "type": "string" + }, + "type": { + "enum": ["account", "application", "customer", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "owner_params", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/tax_id" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TaxIDsList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new account or customer tax_id object.

", + "operationId": "PostTaxIds", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "owner": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "owner": { + "description": "The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.", + "properties": { + "account": { + "type": "string" + }, + "customer": { + "maxLength": 5000, + "type": "string" + }, + "type": { + "enum": ["account", "application", "customer", "self"], + "type": "string" + } + }, + "required": ["type"], + "title": "owner_params", + "type": "object" + }, + "type": { + "description": "Type of the tax ID, one of `ad_nrt`, `ae_trn`, `ar_cuit`, `au_abn`, `au_arn`, `bg_uic`, `bh_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `ch_uid`, `ch_vat`, `cl_tin`, `cn_tin`, `co_nit`, `cr_tin`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kr_brn`, `kz_bin`, `li_uid`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sv_nit`, `th_vat`, `tr_tin`, `tw_vat`, `ua_vat`, `us_ein`, `uy_ruc`, `ve_rif`, `vn_tin`, or `za_vat`", + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_uid", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "de_stn", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hr_oib", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "value": { + "description": "Value of the tax ID.", + "type": "string" + } + }, + "required": ["type", "value"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax_id" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax_ids/{id}": { + "delete": { + "description": "

Deletes an existing account or customer tax_id object.

", + "operationId": "DeleteTaxIdsId", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_tax_id" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves an account or customer tax_id object.

", + "operationId": "GetTaxIdsId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax_id" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax_rates": { + "get": { + "description": "

Returns a list of your tax rates. Tax rates are returned sorted by creation date, with the most recently created tax rates appearing first.

", + "operationId": "GetTaxRates", + "parameters": [ + { + "description": "Optional flag to filter by tax rates that are either active or inactive (archived).", + "in": "query", + "name": "active", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "Optional range for filtering created date.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "Optional flag to filter by tax rates that are inclusive (or those that are not inclusive).", + "in": "query", + "name": "inclusive", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/tax_rate" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/tax_rates", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TaxRatesList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new tax rate.

", + "operationId": "PostTaxRates", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.", + "type": "boolean" + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.", + "maxLength": 5000, + "type": "string" + }, + "display_name": { + "description": "The display name of the tax rate, which will be shown to users.", + "maxLength": 50, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "inclusive": { + "description": "This specifies if the tax rate is inclusive or exclusive.", + "type": "boolean" + }, + "jurisdiction": { + "description": "The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.", + "maxLength": 50, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "percentage": { + "description": "This represents the tax rate percent out of 100.", + "type": "number" + }, + "state": { + "description": "[ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, \"NY\" for New York, United States.", + "maxLength": 2, + "type": "string" + }, + "tax_type": { + "description": "The high-level tax type, such as `vat` or `sales_tax`.", + "enum": [ + "amusement_tax", + "communications_tax", + "gst", + "hst", + "igst", + "jct", + "lease_tax", + "pst", + "qst", + "rst", + "sales_tax", + "vat" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["display_name", "inclusive", "percentage"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax_rate" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tax_rates/{tax_rate}": { + "get": { + "description": "

Retrieves a tax rate with the given ID

", + "operationId": "GetTaxRatesTaxRate", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "tax_rate", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax_rate" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates an existing tax rate.

", + "operationId": "PostTaxRatesTaxRate", + "parameters": [ + { + "in": "path", + "name": "tax_rate", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.", + "type": "boolean" + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.", + "maxLength": 5000, + "type": "string" + }, + "display_name": { + "description": "The display name of the tax rate, which will be shown to users.", + "maxLength": 50, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "jurisdiction": { + "description": "The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.", + "maxLength": 50, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "state": { + "description": "[ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, \"NY\" for New York, United States.", + "maxLength": 2, + "type": "string" + }, + "tax_type": { + "description": "The high-level tax type, such as `vat` or `sales_tax`.", + "enum": [ + "amusement_tax", + "communications_tax", + "gst", + "hst", + "igst", + "jct", + "lease_tax", + "pst", + "qst", + "rst", + "sales_tax", + "vat" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/tax_rate" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/configurations": { + "get": { + "description": "

Returns a list of Configuration objects.

", + "operationId": "GetTerminalConfigurations", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "if present, only return the account default or non-default configurations.", + "in": "query", + "name": "is_account_default", + "required": false, + "schema": { + "type": "boolean" + }, + "style": "form" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/terminal.configuration" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/terminal/configurations", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TerminalConfigurationConfigurationList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new Configuration object.

", + "operationId": "PostTerminalConfigurations", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "bbpos_wisepos_e": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "offline": { + "explode": true, + "style": "deepObject" + }, + "reboot_window": { + "explode": true, + "style": "deepObject" + }, + "stripe_s700": { + "explode": true, + "style": "deepObject" + }, + "tipping": { + "explode": true, + "style": "deepObject" + }, + "verifone_p400": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "bbpos_wisepos_e": { + "description": "An object containing device type specific settings for BBPOS WisePOS E readers", + "properties": { + "splashscreen": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "bbpos_wise_pose", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "name": { + "description": "Name of the configuration", + "maxLength": 100, + "type": "string" + }, + "offline": { + "anyOf": [ + { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "offline", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Configurations for collecting transactions offline." + }, + "reboot_window": { + "description": "Reboot time settings for readers that support customized reboot time configuration.", + "properties": { + "end_hour": { + "type": "integer" + }, + "start_hour": { + "type": "integer" + } + }, + "required": ["end_hour", "start_hour"], + "title": "reboot_window", + "type": "object" + }, + "stripe_s700": { + "description": "An object containing device type specific settings for Stripe S700 readers", + "properties": { + "splashscreen": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "stripe_s700", + "type": "object" + }, + "tipping": { + "anyOf": [ + { + "properties": { + "aud": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "cad": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "chf": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "czk": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "dkk": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "eur": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "gbp": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "hkd": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "myr": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "nok": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "nzd": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "sek": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "sgd": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "usd": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + } + }, + "title": "tipping", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Tipping configurations for readers supporting on-reader tips" + }, + "verifone_p400": { + "description": "An object containing device type specific settings for Verifone P400 readers", + "properties": { + "splashscreen": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "verifone_p400", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/terminal.configuration" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/configurations/{configuration}": { + "delete": { + "description": "

Deletes a Configuration object.

", + "operationId": "DeleteTerminalConfigurationsConfiguration", + "parameters": [ + { + "in": "path", + "name": "configuration", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_terminal.configuration" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves a Configuration object.

", + "operationId": "GetTerminalConfigurationsConfiguration", + "parameters": [ + { + "in": "path", + "name": "configuration", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "$ref": "#/components/schemas/terminal.configuration" + }, + { + "$ref": "#/components/schemas/deleted_terminal.configuration" + } + ] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates a new Configuration object.

", + "operationId": "PostTerminalConfigurationsConfiguration", + "parameters": [ + { + "in": "path", + "name": "configuration", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "bbpos_wisepos_e": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "offline": { + "explode": true, + "style": "deepObject" + }, + "reboot_window": { + "explode": true, + "style": "deepObject" + }, + "stripe_s700": { + "explode": true, + "style": "deepObject" + }, + "tipping": { + "explode": true, + "style": "deepObject" + }, + "verifone_p400": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "bbpos_wisepos_e": { + "anyOf": [ + { + "properties": { + "splashscreen": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "bbpos_wise_pose", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "An object containing device type specific settings for BBPOS WisePOS E readers" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "name": { + "description": "Name of the configuration", + "maxLength": 100, + "type": "string" + }, + "offline": { + "anyOf": [ + { + "properties": { + "enabled": { + "type": "boolean" + } + }, + "required": ["enabled"], + "title": "offline", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Configurations for collecting transactions offline." + }, + "reboot_window": { + "anyOf": [ + { + "properties": { + "end_hour": { + "type": "integer" + }, + "start_hour": { + "type": "integer" + } + }, + "required": ["end_hour", "start_hour"], + "title": "reboot_window", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Reboot time settings for readers that support customized reboot time configuration." + }, + "stripe_s700": { + "anyOf": [ + { + "properties": { + "splashscreen": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "stripe_s700", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "An object containing device type specific settings for Stripe S700 readers" + }, + "tipping": { + "anyOf": [ + { + "properties": { + "aud": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "cad": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "chf": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "czk": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "dkk": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "eur": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "gbp": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "hkd": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "myr": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "nok": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "nzd": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "sek": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "sgd": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + }, + "usd": { + "properties": { + "fixed_amounts": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "percentages": { + "items": { + "type": "integer" + }, + "type": "array" + }, + "smart_tip_threshold": { + "type": "integer" + } + }, + "title": "currency_specific_config", + "type": "object" + } + }, + "title": "tipping", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Tipping configurations for readers supporting on-reader tips" + }, + "verifone_p400": { + "anyOf": [ + { + "properties": { + "splashscreen": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "verifone_p400", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "An object containing device type specific settings for Verifone P400 readers" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "$ref": "#/components/schemas/terminal.configuration" + }, + { + "$ref": "#/components/schemas/deleted_terminal.configuration" + } + ] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/connection_tokens": { + "post": { + "description": "

To connect to a reader the Stripe Terminal SDK needs to retrieve a short-lived connection token from Stripe, proxied through your server. On your backend, add an endpoint that creates and returns a connection token.

", + "operationId": "PostTerminalConnectionTokens", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "location": { + "description": "The id of the location that this connection token is scoped to. If specified the connection token will only be usable with readers assigned to that location, otherwise the connection token will be usable with all readers. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).", + "maxLength": 5000, + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/terminal.connection_token" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/locations": { + "get": { + "description": "

Returns a list of Location objects.

", + "operationId": "GetTerminalLocations", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/terminal.location" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/terminal/locations", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TerminalLocationLocationList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new Location object.\nFor further details, including which address fields are required in each country, see the Manage locations guide.

", + "operationId": "PostTerminalLocations", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "address": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "address": { + "description": "The full address of the location.", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["country"], + "title": "create_location_address_param", + "type": "object" + }, + "configuration_overrides": { + "description": "The ID of a configuration that will be used to customize all readers in this location.", + "maxLength": 1000, + "type": "string" + }, + "display_name": { + "description": "A name for the location.", + "maxLength": 1000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, + "required": ["address", "display_name"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/terminal.location" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/locations/{location}": { + "delete": { + "description": "

Deletes a Location object.

", + "operationId": "DeleteTerminalLocationsLocation", + "parameters": [ + { + "in": "path", + "name": "location", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_terminal.location" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "get": { + "description": "

Retrieves a Location object.

", + "operationId": "GetTerminalLocationsLocation", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "location", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "$ref": "#/components/schemas/terminal.location" + }, + { + "$ref": "#/components/schemas/deleted_terminal.location" + } + ] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates a Location object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", + "operationId": "PostTerminalLocationsLocation", + "parameters": [ + { + "in": "path", + "name": "location", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "address": { + "explode": true, + "style": "deepObject" + }, + "configuration_overrides": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "address": { + "description": "The full address of the location. If you're updating the `address` field, avoid changing the `country`. If you need to modify the `country` field, create a new `Location` object and re-register any existing readers to that location.", + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "configuration_overrides": { + "anyOf": [ + { + "maxLength": 1000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The ID of a configuration that will be used to customize all readers in this location." + }, + "display_name": { + "description": "A name for the location.", + "maxLength": 1000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "$ref": "#/components/schemas/terminal.location" + }, + { + "$ref": "#/components/schemas/deleted_terminal.location" + } + ] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/readers": { + "get": { + "description": "

Returns a list of Reader objects.

", + "operationId": "GetTerminalReaders", + "parameters": [ + { + "description": "Filters readers by device type", + "in": "query", + "name": "device_type", + "required": false, + "schema": { + "enum": [ + "bbpos_chipper2x", + "bbpos_wisepad3", + "bbpos_wisepos_e", + "mobile_phone_reader", + "simulated_wisepos_e", + "stripe_m2", + "stripe_s700", + "verifone_P400" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A location ID to filter the response list to only readers at the specific location", + "in": "query", + "name": "location", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Filters readers by serial number", + "in": "query", + "name": "serial_number", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A status filter to filter readers to only offline or online readers", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["offline", "online"], + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "A list of readers", + "items": { + "$ref": "#/components/schemas/terminal.reader" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TerminalReaderRetrieveReader", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates a new Reader object.

", + "operationId": "PostTerminalReaders", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "label": { + "description": "Custom label given to the reader for easier identification. If no label is specified, the registration code will be used.", + "maxLength": 5000, + "type": "string" + }, + "location": { + "description": "The location to assign the reader to.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "report_type": { - "description": "The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `\"balance.summary.1\"`.", + "registration_code": { + "description": "A code generated by the reader used for registering to an account.", + "maxLength": 5000, "type": "string" } }, - "required": ["report_type"], + "required": ["registration_code"], "type": "object" } } @@ -70895,7 +138927,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/reporting.report_run" + "$ref": "#/components/schemas/terminal.reader" } } }, @@ -70914,10 +138946,61 @@ } } }, - "/v1/reporting/report_runs/{report_run}": { + "/v1/terminal/readers/{reader}": { + "delete": { + "description": "

Deletes a Reader object.

", + "operationId": "DeleteTerminalReadersReader", + "parameters": [ + { + "in": "path", + "name": "reader", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_terminal.reader" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, "get": { - "description": "

Retrieves the details of an existing Report Run. (Requires a live-mode API key.)

", - "operationId": "GetReportingReportRunsReportRun", + "description": "

Retrieves a Reader object.

", + "operationId": "GetTerminalReadersReader", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -70936,7 +139019,7 @@ }, { "in": "path", - "name": "report_run", + "name": "reader", "required": true, "schema": { "maxLength": 5000, @@ -70950,6 +139033,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -70962,7 +139046,14 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/reporting.report_run" + "anyOf": [ + { + "$ref": "#/components/schemas/terminal.reader" + }, + { + "$ref": "#/components/schemas/deleted_terminal.reader" + } + ] } } }, @@ -70979,35 +139070,79 @@ "description": "Error response." } } - } - }, - "/v1/reporting/report_types": { - "get": { - "description": "

Returns a full list of Report Types. (Requires a live-mode API key.)

", - "operationId": "GetReportingReportTypes", + }, + "post": { + "description": "

Updates a Reader object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", + "operationId": "PostTerminalReadersReader", "parameters": [ { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, + "in": "path", + "name": "reader", + "required": true, "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "maxLength": 5000, + "type": "string" }, - "style": "deepObject" + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "label": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "label": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "The new label of the reader." + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, "type": "object" } } @@ -71019,33 +139154,271 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/reporting.report_type" - }, - "type": "array" + "anyOf": [ + { + "$ref": "#/components/schemas/terminal.reader" }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" + { + "$ref": "#/components/schemas/deleted_terminal.reader" + } + ] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/readers/{reader}/cancel_action": { + "post": { + "description": "

Cancels the current reader action.

", + "operationId": "PostTerminalReadersReaderCancelAction", + "parameters": [ + { + "in": "path", + "name": "reader", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/terminal.reader" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/readers/{reader}/process_payment_intent": { + "post": { + "description": "

Initiates a payment flow on a Reader.

", + "operationId": "PostTerminalReadersReaderProcessPaymentIntent", + "parameters": [ + { + "in": "path", + "name": "reader", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "process_config": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, "type": "string" }, - "url": { - "description": "The URL where this list can be accessed.", + "type": "array" + }, + "payment_intent": { + "description": "PaymentIntent ID", + "maxLength": 5000, + "type": "string" + }, + "process_config": { + "description": "Configuration overrides", + "properties": { + "enable_customer_cancellation": { + "type": "boolean" + }, + "skip_tipping": { + "type": "boolean" + }, + "tipping": { + "properties": { + "amount_eligible": { + "type": "integer" + } + }, + "title": "tipping_config", + "type": "object" + } + }, + "title": "process_config", + "type": "object" + } + }, + "required": ["payment_intent"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/terminal.reader" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/readers/{reader}/process_setup_intent": { + "post": { + "description": "

Initiates a setup intent flow on a Reader.

", + "operationId": "PostTerminalReadersReaderProcessSetupIntent", + "parameters": [ + { + "in": "path", + "name": "reader", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "process_config": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "customer_consent_collected": { + "description": "Customer Consent Collected", + "type": "boolean" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { "maxLength": 5000, "type": "string" - } + }, + "type": "array" }, - "required": ["data", "has_more", "object", "url"], - "title": "FinancialReportingFinanceReportTypeList", - "type": "object", - "x-expandableFields": ["data"] + "process_config": { + "description": "Configuration overrides", + "properties": { + "enable_customer_cancellation": { + "type": "boolean" + } + }, + "title": "process_setup_config", + "type": "object" + }, + "setup_intent": { + "description": "SetupIntent ID", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["customer_consent_collected", "setup_intent"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/terminal.reader" } } }, @@ -71064,31 +139437,131 @@ } } }, - "/v1/reporting/report_types/{report_type}": { - "get": { - "description": "

Retrieves the details of a Report Type. (Requires a live-mode API key.)

", - "operationId": "GetReportingReportTypesReportType", + "/v1/terminal/readers/{reader}/refund_payment": { + "post": { + "description": "

Initiates a refund on a Reader

", + "operationId": "PostTerminalReadersReaderRefundPayment", "parameters": [ { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, + "in": "path", + "name": "reader", + "required": true, "schema": { - "items": { - "maxLength": 5000, - "type": "string" + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "refund_payment_config": { + "explode": true, + "style": "deepObject" + } }, - "type": "array" + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "A positive integer in __cents__ representing how much of this charge to refund.", + "type": "integer" + }, + "charge": { + "description": "ID of the Charge to refund.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "payment_intent": { + "description": "ID of the PaymentIntent to refund.", + "maxLength": 5000, + "type": "string" + }, + "refund_application_fee": { + "description": "Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.", + "type": "boolean" + }, + "refund_payment_config": { + "description": "Configuration overrides", + "properties": { + "enable_customer_cancellation": { + "type": "boolean" + } + }, + "title": "refund_payment_config", + "type": "object" + }, + "reverse_transfer": { + "description": "Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount). A transfer can be reversed only by the application that created the charge.", + "type": "boolean" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/terminal.reader" + } + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/terminal/readers/{reader}/set_reader_display": { + "post": { + "description": "

Sets reader display to show cart details.

", + "operationId": "PostTerminalReadersReaderSetReaderDisplay", + "parameters": [ { "in": "path", - "name": "report_type", + "name": "reader", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" @@ -71097,21 +139570,83 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "cart": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "cart": { + "description": "Cart", + "properties": { + "currency": { + "type": "string" + }, + "line_items": { + "items": { + "properties": { + "amount": { + "type": "integer" + }, + "description": { + "maxLength": 5000, + "type": "string" + }, + "quantity": { + "type": "integer" + } + }, + "required": ["amount", "description", "quantity"], + "title": "line_item", + "type": "object" + }, + "type": "array" + }, + "tax": { + "type": "integer" + }, + "total": { + "type": "integer" + } + }, + "required": ["currency", "line_items", "total"], + "title": "cart", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "type": { + "description": "Type", + "enum": ["cart"], + "type": "string" + } + }, + "required": ["type"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/reporting.report_type" + "$ref": "#/components/schemas/terminal.reader" } } }, @@ -71130,428 +139665,668 @@ } } }, - "/v1/reviews": { - "get": { - "description": "

Returns a list of Review objects that have open set to true. The objects are sorted in descending order by creation date, with the most recently created object appearing first.

", - "operationId": "GetReviews", - "parameters": [ - { - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], + "/v1/test_helpers/confirmation_tokens": { + "post": { + "description": "

Creates a test mode Confirmation Token server side for your integration tests.

", + "operationId": "PostTestHelpersConfirmationTokens", "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "payment_method_data": { + "explode": true, + "style": "deepObject" + }, + "shipping": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/review" + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "payment_method": { + "description": "ID of an existing PaymentMethod.", + "maxLength": 5000, + "type": "string" + }, + "payment_method_data": { + "description": "If provided, this hash will be used to create a PaymentMethod.", + "properties": { + "acss_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "institution_number": { + "maxLength": 5000, + "type": "string" + }, + "transit_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "account_number", + "institution_number", + "transit_number" + ], + "title": "payment_method_param", + "type": "object" + }, + "affirm": { + "properties": {}, + "title": "param", + "type": "object" + }, + "afterpay_clearpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "alipay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "allow_redisplay": { + "enum": ["always", "limited", "unspecified"], + "type": "string" + }, + "amazon_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "au_becs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "bsb_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "bsb_number"], + "title": "param", + "type": "object" + }, + "bacs_debit": { + "properties": { + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "sort_code": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "bancontact": { + "properties": {}, + "title": "param", + "type": "object" + }, + "billing_details": { + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "billing_details_address", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "name": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "billing_details_inner_params", + "type": "object" + }, + "blik": { + "properties": {}, + "title": "param", + "type": "object" + }, + "boleto": { + "properties": { + "tax_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["tax_id"], + "title": "param", + "type": "object" + }, + "cashapp": { + "properties": {}, + "title": "param", + "type": "object" + }, + "customer_balance": { + "properties": {}, + "title": "param", + "type": "object" + }, + "eps": { + "properties": { + "bank": { + "enum": [ + "arzte_und_apotheker_bank", + "austrian_anadi_bank_ag", + "bank_austria", + "bankhaus_carl_spangler", + "bankhaus_schelhammer_und_schattera_ag", + "bawag_psk_ag", + "bks_bank_ag", + "brull_kallmus_bank_ag", + "btv_vier_lander_bank", + "capital_bank_grawe_gruppe_ag", + "deutsche_bank_ag", + "dolomitenbank", + "easybank_ag", + "erste_bank_und_sparkassen", + "hypo_alpeadriabank_international_ag", + "hypo_bank_burgenland_aktiengesellschaft", + "hypo_noe_lb_fur_niederosterreich_u_wien", + "hypo_oberosterreich_salzburg_steiermark", + "hypo_tirol_bank_ag", + "hypo_vorarlberg_bank_ag", + "marchfelder_bank", + "oberbank_ag", + "raiffeisen_bankengruppe_osterreich", + "schoellerbank_ag", + "sparda_bank_wien", + "volksbank_gruppe", + "volkskreditbank_ag", + "vr_bank_braunau" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "fpx": { + "properties": { + "bank": { + "enum": [ + "affin_bank", + "agrobank", + "alliance_bank", + "ambank", + "bank_islam", + "bank_muamalat", + "bank_of_china", + "bank_rakyat", + "bsn", + "cimb", + "deutsche_bank", + "hong_leong_bank", + "hsbc", + "kfh", + "maybank2e", + "maybank2u", + "ocbc", + "pb_enterprise", + "public_bank", + "rhb", + "standard_chartered", + "uob" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["bank"], + "title": "param", + "type": "object" + }, + "giropay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "grabpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "ideal": { + "properties": { + "bank": { + "enum": [ + "abn_amro", + "asn_bank", + "bunq", + "handelsbanken", + "ing", + "knab", + "moneyou", + "n26", + "nn", + "rabobank", + "regiobank", + "revolut", + "sns_bank", + "triodos_bank", + "van_lanschot", + "yoursafe" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "param", + "type": "object" + }, + "interac_present": { + "properties": {}, + "title": "param", + "type": "object" + }, + "klarna": { + "properties": { + "dob": { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth", + "type": "object" + } + }, + "title": "param", + "type": "object" + }, + "konbini": { + "properties": {}, + "title": "param", + "type": "object" + }, + "link": { + "properties": {}, + "title": "param", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "mobilepay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "multibanco": { + "properties": {}, + "title": "param", + "type": "object" }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" + "oxxo": { + "properties": {}, + "title": "param", + "type": "object" + }, + "p24": { + "properties": { + "bank": { + "enum": [ + "alior_bank", + "bank_millennium", + "bank_nowy_bfg_sa", + "bank_pekao_sa", + "banki_spbdzielcze", + "blik", + "bnp_paribas", + "boz", + "citi_handlowy", + "credit_agricole", + "envelobank", + "etransfer_pocztowy24", + "getin_bank", + "ideabank", + "ing", + "inteligo", + "mbank_mtransfer", + "nest_przelew", + "noble_pay", + "pbac_z_ipko", + "plus_bank", + "santander_przelew24", + "tmobile_usbugi_bankowe", + "toyota_bank", + "velobank", + "volkswagen_bank" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "title": "param", + "type": "object" + }, + "paynow": { + "properties": {}, + "title": "param", + "type": "object" + }, + "paypal": { + "properties": {}, + "title": "param", + "type": "object" + }, + "pix": { + "properties": {}, + "title": "param", + "type": "object" + }, + "promptpay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "radar_options": { + "properties": { + "session": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "radar_options_with_hidden_options", + "type": "object" + }, + "revolut_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "sepa_debit": { + "properties": { + "iban": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["iban"], + "title": "param", + "type": "object" + }, + "sofort": { + "properties": { + "country": { + "enum": ["AT", "BE", "DE", "ES", "IT", "NL"], + "type": "string" + } + }, + "required": ["country"], + "title": "param", + "type": "object" + }, + "swish": { + "properties": {}, + "title": "param", + "type": "object" + }, + "twint": { + "properties": {}, + "title": "param", + "type": "object" + }, + "type": { + "enum": [ + "acss_debit", + "affirm", + "afterpay_clearpay", + "alipay", + "amazon_pay", + "au_becs_debit", + "bacs_debit", + "bancontact", + "blik", + "boleto", + "cashapp", + "customer_balance", + "eps", + "fpx", + "giropay", + "grabpay", + "ideal", + "klarna", + "konbini", + "link", + "mobilepay", + "multibanco", + "oxxo", + "p24", + "paynow", + "paypal", + "pix", + "promptpay", + "revolut_pay", + "sepa_debit", + "sofort", + "swish", + "twint", + "us_bank_account", + "wechat_pay", + "zip" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "us_bank_account": { + "properties": { + "account_holder_type": { + "enum": ["company", "individual"], + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "account_type": { + "enum": ["checking", "savings"], + "type": "string" + }, + "financial_connections_account": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "payment_method_param", + "type": "object" + }, + "wechat_pay": { + "properties": {}, + "title": "param", + "type": "object" + }, + "zip": { + "properties": {}, + "title": "param", + "type": "object" + } }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/reviews", - "type": "string" - } + "required": ["type"], + "title": "payment_method_data_params", + "type": "object" }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/reviews/{review}": { - "get": { - "description": "

Retrieves a Review object.

", - "operationId": "GetReviewsReview", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "review", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/review" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/reviews/{review}/approve": { - "post": { - "description": "

Approves a Review object, closing it and removing it from the list of reviews.

", - "operationId": "PostReviewsReviewApprove", - "parameters": [ - { - "in": "path", - "name": "review", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/review" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/setup_attempts": { - "get": { - "description": "

Returns a list of SetupAttempts associated with a provided SetupIntent.

", - "operationId": "GetSetupAttempts", - "parameters": [ - { - "description": "A filter on the list, based on the object `created` field. The value\ncan be a string with an integer Unix timestamp, or it can be a\ndictionary with a number of different query options.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } + "return_url": { + "description": "Return URL used to confirm the Intent.", + "type": "string" }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "Only return SetupAttempts created by the SetupIntent specified by\nthis ID.", - "in": "query", - "name": "setup_intent", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/setup_attempt" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/setup_attempts", - "type": "string" - } + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this ConfirmationToken's payment method.\n\nThe presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.", + "enum": ["off_session", "on_session"], + "type": "string" }, - "required": ["data", "has_more", "object", "url"], - "title": "PaymentFlowsSetupIntentSetupAttemptList", - "type": "object", - "x-expandableFields": ["data"] + "shipping": { + "description": "Shipping information for this ConfirmationToken.", + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "required": ["address", "name"], + "title": "recipient_shipping_with_optional_fields_address", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/confirmation_token" } } }, @@ -71570,159 +140345,69 @@ } } }, - "/v1/setup_intents": { - "get": { - "description": "

Returns a list of SetupIntents.

", - "operationId": "GetSetupIntents", + "/v1/test_helpers/customers/{customer}/fund_cash_balance": { + "post": { + "description": "

Create an incoming testmode bank transfer

", + "operationId": "PostTestHelpersCustomersCustomerFundCashBalance", "parameters": [ { - "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return SetupIntents for the customer specified by this customer ID.", - "in": "query", + "in": "path", "name": "customer", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "Only return SetupIntents associated with the specified payment method.", - "in": "query", - "name": "payment_method", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "amount": { + "description": "Amount to be used for this test cash balance transaction. A positive integer representing how much to fund in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to fund $1.00 or 100 to fund ¥100, a zero-decimal currency).", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "reference": { + "description": "A description of the test funding. This simulates free-text references supplied by customers when making bank transfers to their cash balance. You can use this to test how Stripe's [reconciliation algorithm](https://stripe.com/docs/payments/customer-balance/reconciliation) applies to different user inputs.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["amount", "currency"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/setup_intent" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/setup_intents", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "title": "PaymentFlowsSetupIntentList", - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/customer_cash_balance_transaction" } } }, @@ -71739,53 +140424,83 @@ "description": "Error response." } } - }, + } + }, + "/v1/test_helpers/issuing/authorizations": { "post": { - "description": "

Creates a SetupIntent object.

\n\n

After the SetupIntent is created, attach a payment method and confirm\nto collect any required permissions to charge the payment method later.

", - "operationId": "PostSetupIntents", + "description": "

Create a test-mode authorization.

", + "operationId": "PostTestHelpersIssuingAuthorizations", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { + "amount_details": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" }, - "mandate_data": { + "fleet": { "explode": true, "style": "deepObject" }, - "metadata": { + "fuel": { "explode": true, "style": "deepObject" }, - "payment_method_options": { + "merchant_data": { "explode": true, "style": "deepObject" }, - "payment_method_types": { + "network_data": { "explode": true, "style": "deepObject" }, - "single_use": { + "verification_data": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "confirm": { - "description": "Set to `true` to attempt to confirm this SetupIntent immediately. This parameter defaults to `false`. If the payment method attached is a card, a return_url may be provided in case additional authentication is required.", - "type": "boolean" + "amount": { + "description": "The total amount to attempt to authorize. This amount is in the provided currency, or defaults to the card's currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" }, - "customer": { - "description": "ID of the Customer this SetupIntent belongs to, if one exists.\n\nIf present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.", + "amount_details": { + "description": "Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "properties": { + "atm_fee": { + "type": "integer" + }, + "cashback_amount": { + "type": "integer" + } + }, + "title": "amount_details_specs", + "type": "object" + }, + "authorization_method": { + "description": "How the card details were provided. Defaults to online.", + "enum": [ + "chip", + "contactless", + "keyed_in", + "online", + "swipe" + ], + "type": "string" + }, + "card": { + "description": "Card associated with this authorization.", "maxLength": 5000, "type": "string" }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 1000, + "currency": { + "description": "The currency of the authorization. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, "expand": { @@ -71796,125 +140511,870 @@ }, "type": "array" }, - "mandate_data": { - "description": "This hash contains details about the Mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).", + "fleet": { + "description": "Fleet-specific information for authorizations using Fleet cards.", + "properties": { + "cardholder_prompt_data": { + "properties": { + "driver_id": { + "maxLength": 5000, + "type": "string" + }, + "odometer": { + "type": "integer" + }, + "unspecified_id": { + "maxLength": 5000, + "type": "string" + }, + "user_id": { + "maxLength": 5000, + "type": "string" + }, + "vehicle_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "fleet_cardholder_prompt_data_specs", + "type": "object" + }, + "purchase_type": { + "enum": [ + "fuel_and_non_fuel_purchase", + "fuel_purchase", + "non_fuel_purchase" + ], + "maxLength": 5000, + "type": "string" + }, + "reported_breakdown": { + "properties": { + "fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_fuel_specs", + "type": "object" + }, + "non_fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_non_fuel_specs", + "type": "object" + }, + "tax": { + "properties": { + "local_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "national_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_tax_specs", + "type": "object" + } + }, + "title": "fleet_reported_breakdown_specs", + "type": "object" + }, + "service_type": { + "enum": [ + "full_service", + "non_fuel_transaction", + "self_service" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "fleet_testmode_authorization_specs", + "type": "object" + }, + "fuel": { + "description": "Information about fuel that was purchased with this transaction.", + "properties": { + "industry_product_code": { + "maxLength": 5000, + "type": "string" + }, + "quantity_decimal": { + "format": "decimal", + "type": "string" + }, + "type": { + "enum": [ + "diesel", + "other", + "unleaded_plus", + "unleaded_regular", + "unleaded_super" + ], + "maxLength": 5000, + "type": "string" + }, + "unit": { + "enum": [ + "charging_minute", + "imperial_gallon", + "kilogram", + "kilowatt_hour", + "liter", + "other", + "pound", + "us_gallon" + ], + "maxLength": 5000, + "type": "string" + }, + "unit_cost_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fuel_specs", + "type": "object" + }, + "is_amount_controllable": { + "description": "If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.", + "type": "boolean" + }, + "merchant_data": { + "description": "Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.", + "properties": { + "category": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "network_id": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "terminal_id": { + "maxLength": 5000, + "type": "string" + }, + "url": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "merchant_data_specs", + "type": "object" + }, + "network_data": { + "description": "Details about the authorization, such as identifiers, set by the card network.", + "properties": { + "acquiring_institution_id": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "network_data_specs", + "type": "object" + }, + "verification_data": { + "description": "Verifications that Stripe performed on information that the cardholder provided to the merchant.", + "properties": { + "address_line1_check": { + "enum": ["match", "mismatch", "not_provided"], + "type": "string" + }, + "address_postal_code_check": { + "enum": ["match", "mismatch", "not_provided"], + "type": "string" + }, + "authentication_exemption": { + "properties": { + "claimed_by": { + "enum": ["acquirer", "issuer"], + "type": "string" + }, + "type": { + "enum": [ + "low_value_transaction", + "transaction_risk_analysis", + "unknown" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["claimed_by", "type"], + "title": "authentication_exemption_specs", + "type": "object" + }, + "cvc_check": { + "enum": ["match", "mismatch", "not_provided"], + "type": "string" + }, + "expiry_check": { + "enum": ["match", "mismatch", "not_provided"], + "type": "string" + }, + "three_d_secure": { + "properties": { + "result": { + "enum": [ + "attempt_acknowledged", + "authenticated", + "failed", + "required" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["result"], + "title": "three_d_secure_specs", + "type": "object" + } + }, + "title": "verification_data_specs", + "type": "object" + }, + "wallet": { + "description": "The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`. Will populate as `null` when no digital wallet was utilized.", + "enum": ["apple_pay", "google_pay", "samsung_pay"], + "type": "string" + } + }, + "required": ["amount", "card"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.authorization" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/test_helpers/issuing/authorizations/{authorization}/capture": { + "post": { + "description": "

Capture a test-mode authorization.

", + "operationId": "PostTestHelpersIssuingAuthorizationsAuthorizationCapture", + "parameters": [ + { + "in": "path", + "name": "authorization", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "purchase_details": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "capture_amount": { + "description": "The amount to capture from the authorization. If not provided, the full amount of the authorization will be captured. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "close_authorization": { + "description": "Whether to close the authorization after capture. Defaults to true. Set to false to enable multi-capture flows.", + "type": "boolean" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "purchase_details": { + "description": "Additional purchase information that is optionally provided by the merchant.", "properties": { - "customer_acceptance": { + "fleet": { + "properties": { + "cardholder_prompt_data": { + "properties": { + "driver_id": { + "maxLength": 5000, + "type": "string" + }, + "odometer": { + "type": "integer" + }, + "unspecified_id": { + "maxLength": 5000, + "type": "string" + }, + "user_id": { + "maxLength": 5000, + "type": "string" + }, + "vehicle_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "fleet_cardholder_prompt_data_specs", + "type": "object" + }, + "purchase_type": { + "enum": [ + "fuel_and_non_fuel_purchase", + "fuel_purchase", + "non_fuel_purchase" + ], + "maxLength": 5000, + "type": "string" + }, + "reported_breakdown": { + "properties": { + "fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_fuel_specs", + "type": "object" + }, + "non_fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_non_fuel_specs", + "type": "object" + }, + "tax": { + "properties": { + "local_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "national_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_tax_specs", + "type": "object" + } + }, + "title": "fleet_reported_breakdown_specs", + "type": "object" + }, + "service_type": { + "enum": [ + "full_service", + "non_fuel_transaction", + "self_service" + ], + "maxLength": 5000, + "type": "string" + } + }, + "title": "fleet_specs", + "type": "object" + }, + "flight": { "properties": { - "accepted_at": { + "departure_at": { "format": "unix-time", "type": "integer" }, - "offline": { - "properties": {}, - "title": "offline_param", - "type": "object" + "passenger_name": { + "maxLength": 5000, + "type": "string" + }, + "refundable": { + "type": "boolean" }, - "online": { - "properties": { - "ip_address": { - "type": "string" + "segments": { + "items": { + "properties": { + "arrival_airport_code": { + "maxLength": 3, + "type": "string" + }, + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "departure_airport_code": { + "maxLength": 3, + "type": "string" + }, + "flight_number": { + "maxLength": 5000, + "type": "string" + }, + "service_class": { + "maxLength": 5000, + "type": "string" + }, + "stopover_allowed": { + "type": "boolean" + } }, - "user_agent": { - "maxLength": 5000, - "type": "string" - } + "title": "flight_segment_specs", + "type": "object" }, - "required": ["ip_address", "user_agent"], - "title": "online_param", - "type": "object" + "type": "array" }, - "type": { - "enum": ["offline", "online"], + "travel_agency": { "maxLength": 5000, "type": "string" } }, - "required": ["type"], - "title": "customer_acceptance_param", + "title": "flight_specs", "type": "object" - } - }, - "required": ["customer_acceptance"], - "title": "secret_key_param", - "type": "object" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "on_behalf_of": { - "description": "The Stripe account ID for which this SetupIntent is created.", - "type": "string" - }, - "payment_method": { - "description": "ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.", - "maxLength": 5000, - "type": "string" - }, - "payment_method_options": { - "description": "Payment-method-specific configuration for this SetupIntent.", - "properties": { - "card": { + }, + "fuel": { "properties": { - "request_three_d_secure": { - "enum": ["any", "automatic"], + "industry_product_code": { "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" + }, + "quantity_decimal": { + "format": "decimal", + "type": "string" + }, + "type": { + "enum": [ + "diesel", + "other", + "unleaded_plus", + "unleaded_regular", + "unleaded_super" + ], + "maxLength": 5000, + "type": "string" + }, + "unit": { + "enum": [ + "charging_minute", + "imperial_gallon", + "kilogram", + "kilowatt_hour", + "liter", + "other", + "pound", + "us_gallon" + ], + "maxLength": 5000, + "type": "string" + }, + "unit_cost_decimal": { + "format": "decimal", + "type": "string" } }, - "title": "setup_intent_param", + "title": "fuel_specs", "type": "object" }, - "sepa_debit": { + "lodging": { "properties": { - "mandate_options": { - "properties": {}, - "title": "payment_method_options_mandate_options_param", - "type": "object" + "check_in_at": { + "format": "unix-time", + "type": "integer" + }, + "nights": { + "type": "integer" } }, - "title": "setup_intent_payment_method_options_param", + "title": "lodging_specs", "type": "object" - } - }, - "title": "payment_method_options_param", - "type": "object" - }, - "payment_method_types": { - "description": "The list of payment method types (e.g. card) that this SetupIntent is allowed to use. If this is not provided, defaults to [\"card\"].", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "return_url": { - "description": "The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).", - "type": "string" - }, - "single_use": { - "description": "If this hash is populated, this SetupIntent will generate a single_use Mandate on success.", - "properties": { - "amount": { - "type": "integer" }, - "currency": { + "receipt": { + "items": { + "properties": { + "description": { + "maxLength": 26, + "type": "string" + }, + "quantity": { + "format": "decimal", + "type": "string" + }, + "total": { + "type": "integer" + }, + "unit_cost": { + "type": "integer" + } + }, + "title": "receipt_specs", + "type": "object" + }, + "type": "array" + }, + "reference": { + "maxLength": 5000, "type": "string" } }, - "required": ["amount", "currency"], - "title": "setup_intent_single_use_params", + "title": "purchase_details_specs", "type": "object" - }, - "usage": { - "description": "Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`.", - "enum": ["off_session", "on_session"], - "type": "string" } }, "type": "object" @@ -71928,7 +141388,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/setup_intent" + "$ref": "#/components/schemas/issuing.authorization" } } }, @@ -71947,40 +141407,14 @@ } } }, - "/v1/setup_intents/{intent}": { - "get": { - "description": "

Retrieves the details of a SetupIntent that has previously been created.

\n\n

Client-side retrieval using a publishable key is allowed when the client_secret is provided in the query string.

\n\n

When retrieved with a publishable key, only a subset of properties will be returned. Please refer to the SetupIntent object reference for more details.

", - "operationId": "GetSetupIntentsIntent", + "/v1/test_helpers/issuing/authorizations/{authorization}/expire": { + "post": { + "description": "

Expire a test-mode Authorization.

", + "operationId": "PostTestHelpersIssuingAuthorizationsAuthorizationExpire", "parameters": [ - { - "description": "The client secret of the SetupIntent. Required if a publishable key is used to retrieve the SetupIntent.", - "in": "query", - "name": "client_secret", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, { "in": "path", - "name": "intent", + "name": "authorization", "required": true, "schema": { "maxLength": 5000, @@ -71992,9 +141426,24 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -72006,7 +141455,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/setup_intent" + "$ref": "#/components/schemas/issuing.authorization" } } }, @@ -72023,14 +141472,16 @@ "description": "Error response." } } - }, + } + }, + "/v1/test_helpers/issuing/authorizations/{authorization}/finalize_amount": { "post": { - "description": "

Updates a SetupIntent object.

", - "operationId": "PostSetupIntentsIntent", + "description": "

Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.

", + "operationId": "PostTestHelpersIssuingAuthorizationsAuthorizationFinalizeAmount", "parameters": [ { "in": "path", - "name": "intent", + "name": "authorization", "required": true, "schema": { "maxLength": 5000, @@ -72047,31 +141498,18 @@ "explode": true, "style": "deepObject" }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "payment_method_options": { + "fleet": { "explode": true, "style": "deepObject" }, - "payment_method_types": { + "fuel": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "customer": { - "description": "ID of the Customer this SetupIntent belongs to, if one exists.\n\nIf present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.", - "maxLength": 5000, - "type": "string" - }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 1000, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -72080,77 +141518,158 @@ }, "type": "array" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "payment_method": { - "description": "ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.", - "maxLength": 5000, - "type": "string" + "final_amount": { + "description": "The final authorization amount that will be captured by the merchant. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" }, - "payment_method_options": { - "description": "Payment-method-specific configuration for this SetupIntent.", + "fleet": { + "description": "Fleet-specific information for authorizations using Fleet cards.", "properties": { - "card": { + "cardholder_prompt_data": { "properties": { - "request_three_d_secure": { - "enum": ["any", "automatic"], + "driver_id": { "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true + "type": "string" + }, + "odometer": { + "type": "integer" + }, + "unspecified_id": { + "maxLength": 5000, + "type": "string" + }, + "user_id": { + "maxLength": 5000, + "type": "string" + }, + "vehicle_number": { + "maxLength": 5000, + "type": "string" } }, - "title": "setup_intent_param", + "title": "fleet_cardholder_prompt_data_specs", "type": "object" }, - "sepa_debit": { + "purchase_type": { + "enum": [ + "fuel_and_non_fuel_purchase", + "fuel_purchase", + "non_fuel_purchase" + ], + "maxLength": 5000, + "type": "string" + }, + "reported_breakdown": { "properties": { - "mandate_options": { - "properties": {}, - "title": "payment_method_options_mandate_options_param", + "fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_fuel_specs", + "type": "object" + }, + "non_fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_non_fuel_specs", + "type": "object" + }, + "tax": { + "properties": { + "local_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "national_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_tax_specs", "type": "object" } }, - "title": "setup_intent_payment_method_options_param", + "title": "fleet_reported_breakdown_specs", "type": "object" + }, + "service_type": { + "enum": [ + "full_service", + "non_fuel_transaction", + "self_service" + ], + "maxLength": 5000, + "type": "string" } }, - "title": "payment_method_options_param", + "title": "fleet_specs", "type": "object" }, - "payment_method_types": { - "description": "The list of payment method types (e.g. card) that this SetupIntent is allowed to set up. If this is not provided, defaults to [\"card\"].", - "items": { - "maxLength": 5000, - "type": "string" + "fuel": { + "description": "Information about fuel that was purchased with this transaction.", + "properties": { + "industry_product_code": { + "maxLength": 5000, + "type": "string" + }, + "quantity_decimal": { + "format": "decimal", + "type": "string" + }, + "type": { + "enum": [ + "diesel", + "other", + "unleaded_plus", + "unleaded_regular", + "unleaded_super" + ], + "maxLength": 5000, + "type": "string" + }, + "unit": { + "enum": [ + "charging_minute", + "imperial_gallon", + "kilogram", + "kilowatt_hour", + "liter", + "other", + "pound", + "us_gallon" + ], + "maxLength": 5000, + "type": "string" + }, + "unit_cost_decimal": { + "format": "decimal", + "type": "string" + } }, - "type": "array" + "title": "fuel_specs", + "type": "object" } }, + "required": ["final_amount"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/setup_intent" + "$ref": "#/components/schemas/issuing.authorization" } } }, @@ -72169,14 +141688,14 @@ } } }, - "/v1/setup_intents/{intent}/cancel": { + "/v1/test_helpers/issuing/authorizations/{authorization}/increment": { "post": { - "description": "

A SetupIntent object can be canceled when it is in one of these statuses: requires_payment_method, requires_confirmation, or requires_action.

\n\n

Once canceled, setup is abandoned and any operations on the SetupIntent will fail with an error.

", - "operationId": "PostSetupIntentsIntentCancel", + "description": "

Increment a test-mode Authorization.

", + "operationId": "PostTestHelpersIssuingAuthorizationsAuthorizationIncrement", "parameters": [ { "in": "path", - "name": "intent", + "name": "authorization", "required": true, "schema": { "maxLength": 5000, @@ -72195,13 +141714,8 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "cancellation_reason": { - "description": "Reason for canceling this SetupIntent. Possible values are `abandoned`, `requested_by_customer`, or `duplicate`", - "enum": ["abandoned", "duplicate", "requested_by_customer"], - "maxLength": 5000, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -72209,20 +141723,29 @@ "type": "string" }, "type": "array" + }, + "increment_amount": { + "description": "The amount to increment the authorization by. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + }, + "is_amount_controllable": { + "description": "If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.", + "type": "boolean" } }, + "required": ["increment_amount"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/setup_intent" + "$ref": "#/components/schemas/issuing.authorization" } } }, @@ -72241,14 +141764,14 @@ } } }, - "/v1/setup_intents/{intent}/confirm": { + "/v1/test_helpers/issuing/authorizations/{authorization}/reverse": { "post": { - "description": "

Confirm that your customer intends to set up the current or\nprovided payment method. For example, you would confirm a SetupIntent\nwhen a customer hits the “Save” button on a payment method management\npage on your website.

\n\n

If the selected payment method does not require any additional\nsteps from the customer, the SetupIntent will transition to the\nsucceeded status.

\n\n

Otherwise, it will transition to the requires_action status and\nsuggest additional actions via next_action. If setup fails,\nthe SetupIntent will transition to the\nrequires_payment_method status.

", - "operationId": "PostSetupIntentsIntentConfirm", + "description": "

Reverse a test-mode Authorization.

", + "operationId": "PostTestHelpersIssuingAuthorizationsAuthorizationReverse", "parameters": [ { "in": "path", - "name": "intent", + "name": "authorization", "required": true, "schema": { "maxLength": 5000, @@ -72264,23 +141787,11 @@ "expand": { "explode": true, "style": "deepObject" - }, - "mandate_data": { - "explode": true, - "style": "deepObject" - }, - "payment_method_options": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "client_secret": { - "description": "The client secret of the SetupIntent.", - "maxLength": 5000, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -72289,123 +141800,9 @@ }, "type": "array" }, - "mandate_data": { - "anyOf": [ - { - "properties": { - "customer_acceptance": { - "properties": { - "accepted_at": { - "format": "unix-time", - "type": "integer" - }, - "offline": { - "properties": {}, - "title": "offline_param", - "type": "object" - }, - "online": { - "properties": { - "ip_address": { - "type": "string" - }, - "user_agent": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["ip_address", "user_agent"], - "title": "online_param", - "type": "object" - }, - "type": { - "enum": ["offline", "online"], - "maxLength": 5000, - "type": "string" - } - }, - "required": ["type"], - "title": "customer_acceptance_param", - "type": "object" - } - }, - "required": ["customer_acceptance"], - "title": "secret_key_param", - "type": "object" - }, - { - "properties": { - "customer_acceptance": { - "properties": { - "online": { - "properties": { - "ip_address": { - "type": "string" - }, - "user_agent": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "online_param", - "type": "object" - }, - "type": { - "enum": ["online"], - "maxLength": 5000, - "type": "string" - } - }, - "required": ["online", "type"], - "title": "customer_acceptance_param", - "type": "object" - } - }, - "required": ["customer_acceptance"], - "title": "client_key_param", - "type": "object" - } - ], - "description": "This hash contains details about the Mandate to create" - }, - "payment_method": { - "description": "ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.", - "maxLength": 5000, - "type": "string" - }, - "payment_method_options": { - "description": "Payment-method-specific configuration for this SetupIntent.", - "properties": { - "card": { - "properties": { - "request_three_d_secure": { - "enum": ["any", "automatic"], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - } - }, - "title": "setup_intent_param", - "type": "object" - }, - "sepa_debit": { - "properties": { - "mandate_options": { - "properties": {}, - "title": "payment_method_options_mandate_options_param", - "type": "object" - } - }, - "title": "setup_intent_payment_method_options_param", - "type": "object" - } - }, - "title": "payment_method_options_param", - "type": "object" - }, - "return_url": { - "description": "The URL to redirect your customer back to after they authenticate on the payment method's app or site.\nIf you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.\nThis parameter is only used for cards and other redirect-based payment methods.", - "type": "string" + "reverse_amount": { + "description": "The amount to reverse from the authorization. If not provided, the full amount of the authorization will be reversed. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" } }, "type": "object" @@ -72419,7 +141816,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/setup_intent" + "$ref": "#/components/schemas/issuing.authorization" } } }, @@ -72438,65 +141835,43 @@ } } }, - "/v1/sigma/scheduled_query_runs": { - "get": { - "description": "

Returns a list of scheduled query runs.

", - "operationId": "GetSigmaScheduledQueryRuns", + "/v1/test_helpers/issuing/cards/{card}/shipping/deliver": { + "post": { + "description": "

Updates the shipping status of the specified Issuing Card object to delivered.

", + "operationId": "PostTestHelpersIssuingCardsCardShippingDeliver", "parameters": [ { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, + "in": "path", + "name": "card", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -72508,33 +141883,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/scheduled_query_run" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/sigma/scheduled_query_runs", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/issuing.card" } } }, @@ -72553,29 +141902,14 @@ } } }, - "/v1/sigma/scheduled_query_runs/{scheduled_query_run}": { - "get": { - "description": "

Retrieves the details of an scheduled query run.

", - "operationId": "GetSigmaScheduledQueryRunsScheduledQueryRun", + "/v1/test_helpers/issuing/cards/{card}/shipping/fail": { + "post": { + "description": "

Updates the shipping status of the specified Issuing Card object to failure.

", + "operationId": "PostTestHelpersIssuingCardsCardShippingFail", "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, { "in": "path", - "name": "scheduled_query_run", + "name": "card", "required": true, "schema": { "maxLength": 5000, @@ -72587,9 +141921,24 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -72601,7 +141950,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/scheduled_query_run" + "$ref": "#/components/schemas/issuing.card" } } }, @@ -72620,126 +141969,43 @@ } } }, - "/v1/skus": { - "get": { - "description": "

Returns a list of your SKUs. The SKUs are returned sorted by creation date, with the most recently created SKUs appearing first.

", - "operationId": "GetSkus", + "/v1/test_helpers/issuing/cards/{card}/shipping/return": { + "post": { + "description": "

Updates the shipping status of the specified Issuing Card object to returned.

", + "operationId": "PostTestHelpersIssuingCardsCardShippingReturn", "parameters": [ { - "description": "Only return SKUs that are active or inactive (e.g., pass `false` to list all inactive products).", - "in": "query", - "name": "active", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, - { - "description": "Only return SKUs that have the specified key-value pairs in this partially constructed dictionary. Can be specified only if `product` is also supplied. For instance, if the associated product has attributes `[\"color\", \"size\"]`, passing in `attributes[color]=red` returns all the SKUs for this product that have `color` set to `red`.", - "explode": true, - "in": "query", - "name": "attributes", - "required": false, - "schema": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "type": "object" - }, - "style": "deepObject" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "Only return SKUs with the given IDs.", - "explode": true, - "in": "query", - "name": "ids", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "Only return SKUs that are either in stock or out of stock (e.g., pass `false` to list all SKUs that are out of stock). If no value is provided, all SKUs are returned.", - "in": "query", - "name": "in_stock", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "The ID of the product whose SKUs will be retrieved. Must be a product with type `good`.", - "in": "query", - "name": "product", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, + "in": "path", + "name": "card", + "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -72751,33 +142017,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/sku" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/skus", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/issuing.card" } } }, @@ -72794,53 +142034,36 @@ "description": "Error response." } } - }, + } + }, + "/v1/test_helpers/issuing/cards/{card}/shipping/ship": { "post": { - "description": "

Creates a new SKU associated with a product.

", - "operationId": "PostSkus", + "description": "

Updates the shipping status of the specified Issuing Card object to shipped.

", + "operationId": "PostTestHelpersIssuingCardsCardShippingShip", + "parameters": [ + { + "in": "path", + "name": "card", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "attributes": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" - }, - "inventory": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "package_dimensions": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Whether the SKU is available for purchase. Default to `true`.", - "type": "boolean" - }, - "attributes": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "A dictionary of attributes and values for the attributes defined by the product. If, for example, a product's attributes are `[\"size\", \"gender\"]`, a valid SKU has the following dictionary of attributes: `{\"size\": \"Medium\", \"gender\": \"Unisex\"}`.", - "type": "object" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -72848,85 +142071,20 @@ "type": "string" }, "type": "array" - }, - "id": { - "description": "The identifier for the SKU. Must be unique. If not provided, an identifier will be randomly generated.", - "type": "string" - }, - "image": { - "description": "The URL of an image for this SKU, meant to be displayable to the customer.", - "maxLength": 5000, - "type": "string" - }, - "inventory": { - "description": "Description of the SKU's inventory.", - "properties": { - "quantity": { - "type": "integer" - }, - "type": { - "enum": ["bucket", "finite", "infinite"], - "type": "string" - }, - "value": { - "enum": ["", "in_stock", "limited", "out_of_stock"], - "type": "string" - } - }, - "required": ["type"], - "title": "inventory_create_specs", - "type": "object" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "package_dimensions": { - "description": "The dimensions of this SKU for shipping purposes.", - "properties": { - "height": { - "type": "number" - }, - "length": { - "type": "number" - }, - "weight": { - "type": "number" - }, - "width": { - "type": "number" - } - }, - "required": ["height", "length", "weight", "width"], - "title": "package_dimensions_specs", - "type": "object" - }, - "price": { - "description": "The cost of the item as a nonnegative integer in the smallest currency unit (that is, 100 cents to charge $1.00, or 100 to charge ¥100, Japanese Yen being a zero-decimal currency).", - "type": "integer" - }, - "product": { - "description": "The ID of the product this SKU is associated with. Must be a product with type `good`.", - "maxLength": 5000, - "type": "string" } }, - "required": ["currency", "inventory", "price", "product"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/sku" + "$ref": "#/components/schemas/issuing.card" } } }, @@ -72945,14 +142103,14 @@ } } }, - "/v1/skus/{id}": { - "delete": { - "description": "

Delete a SKU. Deleting a SKU is only possible until it has been used in an order.

", - "operationId": "DeleteSkusId", + "/v1/test_helpers/issuing/personalization_designs/{personalization_design}/activate": { + "post": { + "description": "

Updates the status of the specified testmode personalization design object to active.

", + "operationId": "PostTestHelpersIssuingPersonalizationDesignsPersonalizationDesignActivate", "parameters": [ { "in": "path", - "name": "id", + "name": "personalization_design", "required": true, "schema": { "maxLength": 5000, @@ -72964,9 +142122,24 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -72978,7 +142151,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_sku" + "$ref": "#/components/schemas/issuing.personalization_design" } } }, @@ -72995,29 +142168,16 @@ "description": "Error response." } } - }, - "get": { - "description": "

Retrieves the details of an existing SKU. Supply the unique SKU identifier from either a SKU creation request or from the product, and Stripe will return the corresponding SKU information.

", - "operationId": "GetSkusId", + } + }, + "/v1/test_helpers/issuing/personalization_designs/{personalization_design}/deactivate": { + "post": { + "description": "

Updates the status of the specified testmode personalization design object to inactive.

", + "operationId": "PostTestHelpersIssuingPersonalizationDesignsPersonalizationDesignDeactivate", "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, { "in": "path", - "name": "id", + "name": "personalization_design", "required": true, "schema": { "maxLength": 5000, @@ -73029,9 +142189,24 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -73043,14 +142218,7 @@ "content": { "application/json": { "schema": { - "anyOf": [ - { - "$ref": "#/components/schemas/sku" - }, - { - "$ref": "#/components/schemas/deleted_sku" - } - ] + "$ref": "#/components/schemas/issuing.personalization_design" } } }, @@ -73067,14 +142235,16 @@ "description": "Error response." } } - }, + } + }, + "/v1/test_helpers/issuing/personalization_designs/{personalization_design}/reject": { "post": { - "description": "

Updates the specific SKU by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

Note that a SKU’s attributes are not editable. Instead, you would need to deactivate the existing SKU and create a new one with the new attribute values.

", - "operationId": "PostSkusId", + "description": "

Updates the status of the specified testmode personalization design object to rejected.

", + "operationId": "PostTestHelpersIssuingPersonalizationDesignsPersonalizationDesignReject", "parameters": [ { "in": "path", - "name": "id", + "name": "personalization_design", "required": true, "schema": { "maxLength": 5000, @@ -73087,45 +142257,18 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "attributes": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" }, - "inventory": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "package_dimensions": { + "rejection_reasons": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Whether this SKU is available for purchase.", - "type": "boolean" - }, - "attributes": { - "additionalProperties": { - "maxLength": 500, - "type": "string" - }, - "description": "A dictionary of attributes and values for the attributes defined by the product. When specified, `attributes` will partially update the existing attributes dictionary on the product, with the postcondition that a value must be present for each attribute key on the product.", - "type": "object" - }, - "currency": { - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -73134,94 +142277,148 @@ }, "type": "array" }, - "image": { - "description": "The URL of an image for this SKU, meant to be displayable to the customer.", - "maxLength": 5000, - "type": "string" - }, - "inventory": { - "description": "Description of the SKU's inventory.", + "rejection_reasons": { + "description": "The reason(s) the personalization design was rejected.", "properties": { - "quantity": { - "type": "integer" - }, - "type": { - "enum": ["bucket", "finite", "infinite"], - "type": "string" + "card_logo": { + "items": { + "enum": [ + "geographic_location", + "inappropriate", + "network_name", + "non_binary_image", + "non_fiat_currency", + "other", + "other_entity", + "promotional_material" + ], + "type": "string" + }, + "type": "array" }, - "value": { - "enum": ["", "in_stock", "limited", "out_of_stock"], - "type": "string" + "carrier_text": { + "items": { + "enum": [ + "geographic_location", + "inappropriate", + "network_name", + "non_fiat_currency", + "other", + "other_entity", + "promotional_material" + ], + "type": "string" + }, + "type": "array" } }, - "title": "inventory_update_specs", + "title": "rejection_reasons_param", "type": "object" + } + }, + "required": ["rejection_reasons"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.personalization_design" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/test_helpers/issuing/settlements": { + "post": { + "description": "

Allows the user to create an Issuing settlement.

", + "operationId": "PostTestHelpersIssuingSettlements", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "bin": { + "description": "The Bank Identification Number reflecting this settlement record.", + "maxLength": 5000, + "type": "string" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "clearing_date": { + "description": "The date that the transactions are cleared and posted to user's accounts.", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" }, - "package_dimensions": { - "anyOf": [ - { - "properties": { - "height": { - "type": "number" - }, - "length": { - "type": "number" - }, - "weight": { - "type": "number" - }, - "width": { - "type": "number" - } - }, - "required": ["height", "length", "weight", "width"], - "title": "package_dimensions_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The dimensions of this SKU for shipping purposes." + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "price": { - "description": "The cost of the item as a positive integer in the smallest currency unit (that is, 100 cents to charge $1.00, or 100 to charge ¥100, Japanese Yen being a zero-decimal currency).", + "interchange_fees": { + "description": "The total interchange received as reimbursement for the transactions.", "type": "integer" }, - "product": { - "description": "The ID of the product that this SKU should belong to. The product must exist, have the same set of attribute names as the SKU's current product, and be of type `good`.", + "net_total": { + "description": "The total net amount required to settle with the network.", + "type": "integer" + }, + "network_settlement_identifier": { + "description": "The Settlement Identification Number assigned by the network.", "maxLength": 5000, "type": "string" + }, + "transaction_count": { + "description": "The total number of transactions reflected in this settlement.", + "type": "integer" + }, + "transaction_volume": { + "description": "The total transaction amount reflected in this settlement.", + "type": "integer" } }, + "required": ["bin", "clearing_date", "currency", "net_total"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/sku" + "$ref": "#/components/schemas/issuing.settlement" } } }, @@ -73240,10 +142437,10 @@ } } }, - "/v1/sources": { + "/v1/test_helpers/issuing/transactions/create_force_capture": { "post": { - "description": "

Creates a new source object.

", - "operationId": "PostSources", + "description": "

Allows the user to capture an arbitrary amount, also known as a forced capture.

", + "operationId": "PostTestHelpersIssuingTransactionsCreateForceCapture", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -73252,44 +142449,29 @@ "explode": true, "style": "deepObject" }, - "mandate": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "owner": { - "explode": true, - "style": "deepObject" - }, - "receiver": { - "explode": true, - "style": "deepObject" - }, - "redirect": { + "merchant_data": { "explode": true, "style": "deepObject" }, - "source_order": { + "purchase_details": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "amount": { - "description": "Amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources. Not supported for `receiver` type sources, where charge amount may not be specified until funds land.", + "description": "The total amount to attempt to capture. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", "type": "integer" }, - "currency": { - "description": "Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready.", + "card": { + "description": "Card associated with this transaction.", + "maxLength": 5000, "type": "string" }, - "customer": { - "description": "The `Customer` to whom the original source is attached to. Must be set when the original source is not a `Source` (e.g., `Card`).", - "maxLength": 500, + "currency": { + "description": "The currency of the capture. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", "type": "string" }, "expand": { @@ -73300,399 +142482,591 @@ }, "type": "array" }, - "flow": { - "description": "The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows.", - "enum": [ - "code_verification", - "none", - "receiver", - "redirect" - ], - "maxLength": 5000, - "type": "string" + "merchant_data": { + "description": "Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.", + "properties": { + "category": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "network_id": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "terminal_id": { + "maxLength": 5000, + "type": "string" + }, + "url": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "merchant_data_specs", + "type": "object" }, - "mandate": { - "description": "Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.", + "purchase_details": { + "description": "Additional purchase information that is optionally provided by the merchant.", "properties": { - "acceptance": { + "fleet": { "properties": { - "date": { - "format": "unix-time", - "type": "integer" - }, - "ip": { - "type": "string" - }, - "offline": { + "cardholder_prompt_data": { "properties": { - "contact_email": { + "driver_id": { + "maxLength": 5000, "type": "string" - } - }, - "required": ["contact_email"], - "title": "mandate_offline_acceptance_params", - "type": "object" - }, - "online": { - "properties": { - "date": { - "format": "unix-time", + }, + "odometer": { "type": "integer" }, - "ip": { + "unspecified_id": { + "maxLength": 5000, "type": "string" }, - "user_agent": { + "user_id": { + "maxLength": 5000, + "type": "string" + }, + "vehicle_number": { "maxLength": 5000, "type": "string" } }, - "title": "mandate_online_acceptance_params", + "title": "fleet_cardholder_prompt_data_specs", "type": "object" }, - "status": { + "purchase_type": { "enum": [ - "accepted", - "pending", - "refused", - "revoked" + "fuel_and_non_fuel_purchase", + "fuel_purchase", + "non_fuel_purchase" ], "maxLength": 5000, "type": "string" }, - "type": { - "enum": ["offline", "online"], - "maxLength": 5000, - "type": "string" + "reported_breakdown": { + "properties": { + "fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_fuel_specs", + "type": "object" + }, + "non_fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_non_fuel_specs", + "type": "object" + }, + "tax": { + "properties": { + "local_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "national_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_tax_specs", + "type": "object" + } + }, + "title": "fleet_reported_breakdown_specs", + "type": "object" }, - "user_agent": { + "service_type": { + "enum": [ + "full_service", + "non_fuel_transaction", + "self_service" + ], "maxLength": 5000, "type": "string" } }, - "required": ["status"], - "title": "mandate_acceptance_params", + "title": "fleet_specs", "type": "object" }, - "amount": { - "anyOf": [ - { + "flight": { + "properties": { + "departure_at": { + "format": "unix-time", "type": "integer" }, - { - "enum": [""], + "passenger_name": { + "maxLength": 5000, + "type": "string" + }, + "refundable": { + "type": "boolean" + }, + "segments": { + "items": { + "properties": { + "arrival_airport_code": { + "maxLength": 3, + "type": "string" + }, + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "departure_airport_code": { + "maxLength": 3, + "type": "string" + }, + "flight_number": { + "maxLength": 5000, + "type": "string" + }, + "service_class": { + "maxLength": 5000, + "type": "string" + }, + "stopover_allowed": { + "type": "boolean" + } + }, + "title": "flight_segment_specs", + "type": "object" + }, + "type": "array" + }, + "travel_agency": { + "maxLength": 5000, "type": "string" } - ] - }, - "currency": { - "type": "string" - }, - "interval": { - "enum": ["one_time", "scheduled", "variable"], - "maxLength": 5000, - "type": "string" + }, + "title": "flight_specs", + "type": "object" }, - "notification_method": { - "enum": [ - "deprecated_none", - "email", - "manual", - "none", - "stripe_email" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "mandate_params", - "type": "object" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "original_source": { - "description": "The source to share.", - "maxLength": 5000, - "type": "string" - }, - "owner": { - "description": "Information about the owner of the payment instrument that may be used or required by particular source types.", - "properties": { - "address": { + "fuel": { "properties": { - "city": { + "industry_product_code": { "maxLength": 5000, "type": "string" }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, + "quantity_decimal": { + "format": "decimal", "type": "string" }, - "line2": { + "type": { + "enum": [ + "diesel", + "other", + "unleaded_plus", + "unleaded_regular", + "unleaded_super" + ], "maxLength": 5000, "type": "string" }, - "postal_code": { + "unit": { + "enum": [ + "charging_minute", + "imperial_gallon", + "kilogram", + "kilowatt_hour", + "liter", + "other", + "pound", + "us_gallon" + ], "maxLength": 5000, "type": "string" }, - "state": { - "maxLength": 5000, + "unit_cost_decimal": { + "format": "decimal", "type": "string" } }, - "title": "source_address", + "title": "fuel_specs", "type": "object" }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" + "lodging": { + "properties": { + "check_in_at": { + "format": "unix-time", + "type": "integer" + }, + "nights": { + "type": "integer" + } + }, + "title": "lodging_specs", + "type": "object" }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "owner", - "type": "object" - }, - "receiver": { - "description": "Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`).", - "properties": { - "refund_attributes_method": { - "enum": ["email", "manual", "none"], - "maxLength": 5000, - "type": "string" - } - }, - "title": "receiver_params", - "type": "object" - }, - "redirect": { - "description": "Parameters required for the redirect flow. Required if the source is authenticated by a redirect (`flow` is `redirect`).", - "properties": { - "return_url": { - "type": "string" - } - }, - "required": ["return_url"], - "title": "redirect_params", - "type": "object" - }, - "source_order": { - "description": "Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.", - "properties": { - "items": { + "receipt": { "items": { "properties": { - "amount": { - "type": "integer" - }, - "currency": { - "type": "string" - }, "description": { - "maxLength": 1000, + "maxLength": 26, "type": "string" }, - "parent": { - "maxLength": 5000, + "quantity": { + "format": "decimal", "type": "string" }, - "quantity": { + "total": { "type": "integer" }, - "type": { - "enum": ["discount", "shipping", "sku", "tax"], - "maxLength": 5000, - "type": "string" + "unit_cost": { + "type": "integer" } }, - "title": "order_item_specs", + "title": "receipt_specs", "type": "object" }, "type": "array" }, - "shipping": { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["line1"], - "title": "address", - "type": "object" - }, - "carrier": { - "maxLength": 5000, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - }, - "tracking_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["address"], - "title": "order_shipping", - "type": "object" + "reference": { + "maxLength": 5000, + "type": "string" } }, - "title": "shallow_order_specs", + "title": "purchase_details_specs", "type": "object" - }, - "statement_descriptor": { - "description": "An arbitrary string to be displayed on your customer's statement. As an example, if your website is `RunClub` and the item you're charging for is a race ticket, you may want to specify a `statement_descriptor` of `RunClub 5K race ticket.` While many payment types will display this information, some may not display it at all.", - "maxLength": 5000, - "type": "string" - }, - "token": { - "description": "An optional token used to create the source. When passed, token properties will override source parameters.", - "maxLength": 5000, - "type": "string" - }, - "type": { - "description": "The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide)", - "maxLength": 5000, - "type": "string" - }, - "usage": { - "enum": ["reusable", "single_use"], - "maxLength": 5000, - "type": "string" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/source" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/sources/{source}": { - "get": { - "description": "

Retrieves an existing source object. Supply the unique source ID from a source creation request and Stripe will return the corresponding up-to-date source object information.

", - "operationId": "GetSourcesSource", - "parameters": [ - { - "description": "The client secret of the source. Required if a publishable key is used to retrieve the source.", - "in": "query", - "name": "client_secret", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "source", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, + } + }, + "required": ["amount", "card"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/source" + "$ref": "#/components/schemas/issuing.transaction" } } }, @@ -73709,22 +143083,12 @@ "description": "Error response." } } - }, + } + }, + "/v1/test_helpers/issuing/transactions/create_unlinked_refund": { "post": { - "description": "

Updates the specified source by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

This request accepts the metadata and owner as arguments. It is also possible to update type specific information for selected payment methods. Please refer to our payment method guides for more detail.

", - "operationId": "PostSourcesSource", - "parameters": [ - { - "in": "path", - "name": "source", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], + "description": "

Allows the user to refund an arbitrary amount, also known as a unlinked refund.

", + "operationId": "PostTestHelpersIssuingTransactionsCreateUnlinkedRefund", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -73733,29 +143097,31 @@ "explode": true, "style": "deepObject" }, - "mandate": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "owner": { + "merchant_data": { "explode": true, "style": "deepObject" }, - "source_order": { + "purchase_details": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "amount": { - "description": "Amount associated with the source.", + "description": "The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", "type": "integer" }, + "card": { + "description": "Card associated with this unlinked refund transaction.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "The currency of the unlinked refund. If not provided, defaults to the currency of the card. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -73764,271 +143130,591 @@ }, "type": "array" }, - "mandate": { - "description": "Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.", + "merchant_data": { + "description": "Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.", "properties": { - "acceptance": { + "category": { + "enum": [ + "ac_refrigeration_repair", + "accounting_bookkeeping_services", + "advertising_services", + "agricultural_cooperative", + "airlines_air_carriers", + "airports_flying_fields", + "ambulance_services", + "amusement_parks_carnivals", + "antique_reproductions", + "antique_shops", + "aquariums", + "architectural_surveying_services", + "art_dealers_and_galleries", + "artists_supply_and_craft_shops", + "auto_and_home_supply_stores", + "auto_body_repair_shops", + "auto_paint_shops", + "auto_service_shops", + "automated_cash_disburse", + "automated_fuel_dispensers", + "automobile_associations", + "automotive_parts_and_accessories_stores", + "automotive_tire_stores", + "bail_and_bond_payments", + "bakeries", + "bands_orchestras", + "barber_and_beauty_shops", + "betting_casino_gambling", + "bicycle_shops", + "billiard_pool_establishments", + "boat_dealers", + "boat_rentals_and_leases", + "book_stores", + "books_periodicals_and_newspapers", + "bowling_alleys", + "bus_lines", + "business_secretarial_schools", + "buying_shopping_services", + "cable_satellite_and_other_pay_television_and_radio", + "camera_and_photographic_supply_stores", + "candy_nut_and_confectionery_stores", + "car_and_truck_dealers_new_used", + "car_and_truck_dealers_used_only", + "car_rental_agencies", + "car_washes", + "carpentry_services", + "carpet_upholstery_cleaning", + "caterers", + "charitable_and_social_service_organizations_fundraising", + "chemicals_and_allied_products", + "child_care_services", + "childrens_and_infants_wear_stores", + "chiropodists_podiatrists", + "chiropractors", + "cigar_stores_and_stands", + "civic_social_fraternal_associations", + "cleaning_and_maintenance", + "clothing_rental", + "colleges_universities", + "commercial_equipment", + "commercial_footwear", + "commercial_photography_art_and_graphics", + "commuter_transport_and_ferries", + "computer_network_services", + "computer_programming", + "computer_repair", + "computer_software_stores", + "computers_peripherals_and_software", + "concrete_work_services", + "construction_materials", + "consulting_public_relations", + "correspondence_schools", + "cosmetic_stores", + "counseling_services", + "country_clubs", + "courier_services", + "court_costs", + "credit_reporting_agencies", + "cruise_lines", + "dairy_products_stores", + "dance_hall_studios_schools", + "dating_escort_services", + "dentists_orthodontists", + "department_stores", + "detective_agencies", + "digital_goods_applications", + "digital_goods_games", + "digital_goods_large_volume", + "digital_goods_media", + "direct_marketing_catalog_merchant", + "direct_marketing_combination_catalog_and_retail_merchant", + "direct_marketing_inbound_telemarketing", + "direct_marketing_insurance_services", + "direct_marketing_other", + "direct_marketing_outbound_telemarketing", + "direct_marketing_subscription", + "direct_marketing_travel", + "discount_stores", + "doctors", + "door_to_door_sales", + "drapery_window_covering_and_upholstery_stores", + "drinking_places", + "drug_stores_and_pharmacies", + "drugs_drug_proprietaries_and_druggist_sundries", + "dry_cleaners", + "durable_goods", + "duty_free_stores", + "eating_places_restaurants", + "educational_services", + "electric_razor_stores", + "electric_vehicle_charging", + "electrical_parts_and_equipment", + "electrical_services", + "electronics_repair_shops", + "electronics_stores", + "elementary_secondary_schools", + "emergency_services_gcas_visa_use_only", + "employment_temp_agencies", + "equipment_rental", + "exterminating_services", + "family_clothing_stores", + "fast_food_restaurants", + "financial_institutions", + "fines_government_administrative_entities", + "fireplace_fireplace_screens_and_accessories_stores", + "floor_covering_stores", + "florists", + "florists_supplies_nursery_stock_and_flowers", + "freezer_and_locker_meat_provisioners", + "fuel_dealers_non_automotive", + "funeral_services_crematories", + "furniture_home_furnishings_and_equipment_stores_except_appliances", + "furniture_repair_refinishing", + "furriers_and_fur_shops", + "general_services", + "gift_card_novelty_and_souvenir_shops", + "glass_paint_and_wallpaper_stores", + "glassware_crystal_stores", + "golf_courses_public", + "government_licensed_horse_dog_racing_us_region_only", + "government_licensed_online_casions_online_gambling_us_region_only", + "government_owned_lotteries_non_us_region", + "government_owned_lotteries_us_region_only", + "government_services", + "grocery_stores_supermarkets", + "hardware_equipment_and_supplies", + "hardware_stores", + "health_and_beauty_spas", + "hearing_aids_sales_and_supplies", + "heating_plumbing_a_c", + "hobby_toy_and_game_shops", + "home_supply_warehouse_stores", + "hospitals", + "hotels_motels_and_resorts", + "household_appliance_stores", + "industrial_supplies", + "information_retrieval_services", + "insurance_default", + "insurance_underwriting_premiums", + "intra_company_purchases", + "jewelry_stores_watches_clocks_and_silverware_stores", + "landscaping_services", + "laundries", + "laundry_cleaning_services", + "legal_services_attorneys", + "luggage_and_leather_goods_stores", + "lumber_building_materials_stores", + "manual_cash_disburse", + "marinas_service_and_supplies", + "marketplaces", + "masonry_stonework_and_plaster", + "massage_parlors", + "medical_and_dental_labs", + "medical_dental_ophthalmic_and_hospital_equipment_and_supplies", + "medical_services", + "membership_organizations", + "mens_and_boys_clothing_and_accessories_stores", + "mens_womens_clothing_stores", + "metal_service_centers", + "miscellaneous_apparel_and_accessory_shops", + "miscellaneous_auto_dealers", + "miscellaneous_business_services", + "miscellaneous_food_stores", + "miscellaneous_general_merchandise", + "miscellaneous_general_services", + "miscellaneous_home_furnishing_specialty_stores", + "miscellaneous_publishing_and_printing", + "miscellaneous_recreation_services", + "miscellaneous_repair_shops", + "miscellaneous_specialty_retail", + "mobile_home_dealers", + "motion_picture_theaters", + "motor_freight_carriers_and_trucking", + "motor_homes_dealers", + "motor_vehicle_supplies_and_new_parts", + "motorcycle_shops_and_dealers", + "motorcycle_shops_dealers", + "music_stores_musical_instruments_pianos_and_sheet_music", + "news_dealers_and_newsstands", + "non_fi_money_orders", + "non_fi_stored_value_card_purchase_load", + "nondurable_goods", + "nurseries_lawn_and_garden_supply_stores", + "nursing_personal_care", + "office_and_commercial_furniture", + "opticians_eyeglasses", + "optometrists_ophthalmologist", + "orthopedic_goods_prosthetic_devices", + "osteopaths", + "package_stores_beer_wine_and_liquor", + "paints_varnishes_and_supplies", + "parking_lots_garages", + "passenger_railways", + "pawn_shops", + "pet_shops_pet_food_and_supplies", + "petroleum_and_petroleum_products", + "photo_developing", + "photographic_photocopy_microfilm_equipment_and_supplies", + "photographic_studios", + "picture_video_production", + "piece_goods_notions_and_other_dry_goods", + "plumbing_heating_equipment_and_supplies", + "political_organizations", + "postal_services_government_only", + "precious_stones_and_metals_watches_and_jewelry", + "professional_services", + "public_warehousing_and_storage", + "quick_copy_repro_and_blueprint", + "railroads", + "real_estate_agents_and_managers_rentals", + "record_stores", + "recreational_vehicle_rentals", + "religious_goods_stores", + "religious_organizations", + "roofing_siding_sheet_metal", + "secretarial_support_services", + "security_brokers_dealers", + "service_stations", + "sewing_needlework_fabric_and_piece_goods_stores", + "shoe_repair_hat_cleaning", + "shoe_stores", + "small_appliance_repair", + "snowmobile_dealers", + "special_trade_services", + "specialty_cleaning", + "sporting_goods_stores", + "sporting_recreation_camps", + "sports_and_riding_apparel_stores", + "sports_clubs_fields", + "stamp_and_coin_stores", + "stationary_office_supplies_printing_and_writing_paper", + "stationery_stores_office_and_school_supply_stores", + "swimming_pools_sales", + "t_ui_travel_germany", + "tailors_alterations", + "tax_payments_government_agencies", + "tax_preparation_services", + "taxicabs_limousines", + "telecommunication_equipment_and_telephone_sales", + "telecommunication_services", + "telegraph_services", + "tent_and_awning_shops", + "testing_laboratories", + "theatrical_ticket_agencies", + "timeshares", + "tire_retreading_and_repair", + "tolls_bridge_fees", + "tourist_attractions_and_exhibits", + "towing_services", + "trailer_parks_campgrounds", + "transportation_services", + "travel_agencies_tour_operators", + "truck_stop_iteration", + "truck_utility_trailer_rentals", + "typesetting_plate_making_and_related_services", + "typewriter_stores", + "u_s_federal_government_agencies_or_departments", + "uniforms_commercial_clothing", + "used_merchandise_and_secondhand_stores", + "utilities", + "variety_stores", + "veterinary_services", + "video_amusement_game_supplies", + "video_game_arcades", + "video_tape_rental_stores", + "vocational_trade_schools", + "watch_jewelry_repair", + "welding_repair", + "wholesale_clubs", + "wig_and_toupee_stores", + "wires_money_orders", + "womens_accessory_and_specialty_shops", + "womens_ready_to_wear_stores", + "wrecking_and_salvage_yards" + ], + "maxLength": 5000, + "type": "string" + }, + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "network_id": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "terminal_id": { + "maxLength": 5000, + "type": "string" + }, + "url": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "merchant_data_specs", + "type": "object" + }, + "purchase_details": { + "description": "Additional purchase information that is optionally provided by the merchant.", + "properties": { + "fleet": { "properties": { - "date": { - "format": "unix-time", - "type": "integer" - }, - "ip": { - "type": "string" - }, - "offline": { + "cardholder_prompt_data": { "properties": { - "contact_email": { + "driver_id": { + "maxLength": 5000, "type": "string" - } - }, - "required": ["contact_email"], - "title": "mandate_offline_acceptance_params", - "type": "object" - }, - "online": { - "properties": { - "date": { - "format": "unix-time", + }, + "odometer": { "type": "integer" }, - "ip": { + "unspecified_id": { + "maxLength": 5000, "type": "string" }, - "user_agent": { + "user_id": { + "maxLength": 5000, + "type": "string" + }, + "vehicle_number": { "maxLength": 5000, "type": "string" } }, - "title": "mandate_online_acceptance_params", + "title": "fleet_cardholder_prompt_data_specs", "type": "object" }, - "status": { + "purchase_type": { "enum": [ - "accepted", - "pending", - "refused", - "revoked" + "fuel_and_non_fuel_purchase", + "fuel_purchase", + "non_fuel_purchase" ], "maxLength": 5000, "type": "string" }, - "type": { - "enum": ["offline", "online"], - "maxLength": 5000, - "type": "string" + "reported_breakdown": { + "properties": { + "fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_fuel_specs", + "type": "object" + }, + "non_fuel": { + "properties": { + "gross_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_non_fuel_specs", + "type": "object" + }, + "tax": { + "properties": { + "local_amount_decimal": { + "format": "decimal", + "type": "string" + }, + "national_amount_decimal": { + "format": "decimal", + "type": "string" + } + }, + "title": "fleet_reported_breakdown_tax_specs", + "type": "object" + } + }, + "title": "fleet_reported_breakdown_specs", + "type": "object" }, - "user_agent": { + "service_type": { + "enum": [ + "full_service", + "non_fuel_transaction", + "self_service" + ], "maxLength": 5000, "type": "string" } }, - "required": ["status"], - "title": "mandate_acceptance_params", + "title": "fleet_specs", "type": "object" }, - "amount": { - "anyOf": [ - { + "flight": { + "properties": { + "departure_at": { + "format": "unix-time", "type": "integer" }, - { - "enum": [""], + "passenger_name": { + "maxLength": 5000, + "type": "string" + }, + "refundable": { + "type": "boolean" + }, + "segments": { + "items": { + "properties": { + "arrival_airport_code": { + "maxLength": 3, + "type": "string" + }, + "carrier": { + "maxLength": 5000, + "type": "string" + }, + "departure_airport_code": { + "maxLength": 3, + "type": "string" + }, + "flight_number": { + "maxLength": 5000, + "type": "string" + }, + "service_class": { + "maxLength": 5000, + "type": "string" + }, + "stopover_allowed": { + "type": "boolean" + } + }, + "title": "flight_segment_specs", + "type": "object" + }, + "type": "array" + }, + "travel_agency": { + "maxLength": 5000, "type": "string" } - ] - }, - "currency": { - "type": "string" - }, - "interval": { - "enum": ["one_time", "scheduled", "variable"], - "maxLength": 5000, - "type": "string" - }, - "notification_method": { - "enum": [ - "deprecated_none", - "email", - "manual", - "none", - "stripe_email" - ], - "maxLength": 5000, - "type": "string" - } - }, - "title": "mandate_params", - "type": "object" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" }, + "title": "flight_specs", "type": "object" }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "owner": { - "description": "Information about the owner of the payment instrument that may be used or required by particular source types.", - "properties": { - "address": { + "fuel": { "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { + "industry_product_code": { "maxLength": 5000, "type": "string" }, - "line1": { - "maxLength": 5000, + "quantity_decimal": { + "format": "decimal", "type": "string" }, - "line2": { + "type": { + "enum": [ + "diesel", + "other", + "unleaded_plus", + "unleaded_regular", + "unleaded_super" + ], "maxLength": 5000, "type": "string" }, - "postal_code": { + "unit": { + "enum": [ + "charging_minute", + "imperial_gallon", + "kilogram", + "kilowatt_hour", + "liter", + "other", + "pound", + "us_gallon" + ], "maxLength": 5000, "type": "string" }, - "state": { - "maxLength": 5000, + "unit_cost_decimal": { + "format": "decimal", "type": "string" } }, - "title": "source_address", + "title": "fuel_specs", "type": "object" }, - "email": { - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" + "lodging": { + "properties": { + "check_in_at": { + "format": "unix-time", + "type": "integer" + }, + "nights": { + "type": "integer" + } + }, + "title": "lodging_specs", + "type": "object" }, - "phone": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "owner", - "type": "object" - }, - "source_order": { - "description": "Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.", - "properties": { - "items": { + "receipt": { "items": { "properties": { - "amount": { - "type": "integer" - }, - "currency": { - "type": "string" - }, "description": { - "maxLength": 1000, + "maxLength": 26, "type": "string" }, - "parent": { - "maxLength": 5000, + "quantity": { + "format": "decimal", "type": "string" }, - "quantity": { + "total": { "type": "integer" }, - "type": { - "enum": ["discount", "shipping", "sku", "tax"], - "maxLength": 5000, - "type": "string" + "unit_cost": { + "type": "integer" } }, - "title": "order_item_specs", + "title": "receipt_specs", "type": "object" }, "type": "array" }, - "shipping": { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["line1"], - "title": "address", - "type": "object" - }, - "carrier": { - "maxLength": 5000, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "maxLength": 5000, - "type": "string" - }, - "tracking_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["address"], - "title": "order_shipping", - "type": "object" + "reference": { + "maxLength": 5000, + "type": "string" } }, - "title": "order_params", + "title": "purchase_details_specs", "type": "object" } }, + "required": ["amount", "card"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/source" + "$ref": "#/components/schemas/issuing.transaction" } } }, @@ -74047,39 +143733,151 @@ } } }, - "/v1/sources/{source}/mandate_notifications/{mandate_notification}": { - "get": { - "description": "

Retrieves a new Source MandateNotification.

", - "operationId": "GetSourcesSourceMandateNotificationsMandateNotification", + "/v1/test_helpers/issuing/transactions/{transaction}/refund": { + "post": { + "description": "

Refund a test-mode Transaction.

", + "operationId": "PostTestHelpersIssuingTransactionsTransactionRefund", "parameters": [ { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, + "in": "path", + "name": "transaction", + "required": true, "schema": { - "items": { - "maxLength": 5000, - "type": "string" + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } }, - "type": "array" + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "refund_amount": { + "description": "The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).", + "type": "integer" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/issuing.transaction" + } + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/test_helpers/refunds/{refund}/expire": { + "post": { + "description": "

Expire a refund with a status of requires_action.

", + "operationId": "PostTestHelpersRefundsRefundExpire", + "parameters": [ { "in": "path", - "name": "mandate_notification", + "name": "refund", "required": true, "schema": { - "maxLength": 5000, "type": "string" }, "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/refund" + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/test_helpers/terminal/readers/{reader}/present_payment_method": { + "post": { + "description": "

Presents a payment method on a simulated reader. Can be used to simulate accepting a payment, saving a card or refunding a transaction.

", + "operationId": "PostTestHelpersTerminalReadersReaderPresentPaymentMethod", + "parameters": [ { "in": "path", - "name": "source", + "name": "reader", "required": true, "schema": { "maxLength": 5000, @@ -74091,9 +143889,64 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "card_present": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "interac_present": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "amount_tip": { + "description": "Simulated on-reader tip amount.", + "type": "integer" + }, + "card_present": { + "description": "Simulated data for the card_present payment method.", + "properties": { + "number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "card_present", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "interac_present": { + "description": "Simulated data for the interac_present payment method.", + "properties": { + "number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "interac_present", + "type": "object" + }, + "type": { + "description": "Simulated payment type.", + "enum": ["card_present", "interac_present"], + "type": "string", + "x-stripeBypassValidation": true + } + }, "type": "object" } } @@ -74105,7 +143958,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/source_mandate_notification" + "$ref": "#/components/schemas/terminal.reader" } } }, @@ -74124,10 +143977,10 @@ } } }, - "/v1/sources/{source}/source_transactions": { + "/v1/test_helpers/test_clocks": { "get": { - "description": "

List source transactions for a given source.

", - "operationId": "GetSourcesSourceSourceTransactions", + "description": "

Returns a list of your test clocks.

", + "operationId": "GetTestHelpersTestClocks", "parameters": [ { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", @@ -74165,16 +144018,6 @@ }, "style": "form" }, - { - "in": "path", - "name": "source", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -74192,6 +144035,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -74208,7 +144052,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/source_transaction" + "$ref": "#/components/schemas/test_helpers.test_clock" }, "type": "array" }, @@ -74224,11 +144068,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, + "pattern": "^/v1/test_helpers/test_clocks", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "ApmsSourcesSourceTransactionList", + "title": "BillingClocksResourceBillingClockList", "type": "object", "x-expandableFields": ["data"] } @@ -74247,12 +144092,127 @@ "description": "Error response." } } + }, + "post": { + "description": "

Creates a new test clock that can be attached to new customers and quotes.

", + "operationId": "PostTestHelpersTestClocks", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "frozen_time": { + "description": "The initial frozen time for this test clock.", + "format": "unix-time", + "type": "integer" + }, + "name": { + "description": "The name for this test clock.", + "maxLength": 300, + "type": "string" + } + }, + "required": ["frozen_time"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } } }, - "/v1/sources/{source}/source_transactions/{source_transaction}": { + "/v1/test_helpers/test_clocks/{test_clock}": { + "delete": { + "description": "

Deletes a test clock.

", + "operationId": "DeleteTestHelpersTestClocksTestClock", + "parameters": [ + { + "in": "path", + "name": "test_clock", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/deleted_test_helpers.test_clock" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, "get": { - "description": "

Retrieve an existing source transaction object. Supply the unique source ID from a source creation request and the source transaction ID and Stripe will return the corresponding up-to-date source object information.

", - "operationId": "GetSourcesSourceSourceTransactionsSourceTransaction", + "description": "

Retrieves a test clock.

", + "operationId": "GetTestHelpersTestClocksTestClock", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -74271,17 +144231,60 @@ }, { "in": "path", - "name": "source", + "name": "test_clock", "required": true, "schema": { "maxLength": 5000, "type": "string" }, "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/test_helpers.test_clock" + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/test_helpers/test_clocks/{test_clock}/advance": { + "post": { + "description": "

Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready.

", + "operationId": "PostTestHelpersTestClocksTestClockAdvance", + "parameters": [ { "in": "path", - "name": "source_transaction", + "name": "test_clock", "required": true, "schema": { "maxLength": 5000, @@ -74293,21 +144296,42 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "frozen_time": { + "description": "The time to advance the test clock. Must be after the test clock's current frozen time. Cannot be more than two intervals in the future from the shortest subscription in this test clock. If there are no subscriptions in this test clock, it cannot be more than two years in the future.", + "format": "unix-time", + "type": "integer" + } + }, + "required": ["frozen_time"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/source_transaction" + "$ref": "#/components/schemas/test_helpers.test_clock" } } }, @@ -74326,14 +144350,14 @@ } } }, - "/v1/sources/{source}/verify": { + "/v1/test_helpers/treasury/inbound_transfers/{id}/fail": { "post": { - "description": "

Verify a given source.

", - "operationId": "PostSourcesSourceVerify", + "description": "

Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state.

", + "operationId": "PostTestHelpersTreasuryInboundTransfersIdFail", "parameters": [ { "in": "path", - "name": "source", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -74350,12 +144374,13 @@ "explode": true, "style": "deepObject" }, - "values": { + "failure_details": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -74365,8 +144390,92 @@ }, "type": "array" }, - "values": { - "description": "The values needed to verify the source.", + "failure_details": { + "description": "Details about a failed InboundTransfer.", + "properties": { + "code": { + "enum": [ + "account_closed", + "account_frozen", + "bank_account_restricted", + "bank_ownership_changed", + "debit_not_authorized", + "incorrect_account_holder_address", + "incorrect_account_holder_name", + "incorrect_account_holder_tax_id", + "insufficient_funds", + "invalid_account_number", + "invalid_currency", + "no_account", + "other" + ], + "type": "string" + } + }, + "title": "failure_details_params", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/treasury.inbound_transfer" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/test_helpers/treasury/inbound_transfers/{id}/return": { + "post": { + "description": "

Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.

", + "operationId": "PostTestHelpersTreasuryInboundTransfersIdReturn", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", "items": { "maxLength": 5000, "type": "string" @@ -74374,19 +144483,18 @@ "type": "array" } }, - "required": ["values"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/source" + "$ref": "#/components/schemas/treasury.inbound_transfer" } } }, @@ -74405,74 +144513,290 @@ } } }, - "/v1/subscription_items": { - "get": { - "description": "

Returns a list of your subscription items for a given subscription.

", - "operationId": "GetSubscriptionItems", + "/v1/test_helpers/treasury/inbound_transfers/{id}/succeed": { + "post": { + "description": "

Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state.

", + "operationId": "PostTestHelpersTreasuryInboundTransfersIdSucceed", "parameters": [ { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, + "in": "path", + "name": "id", + "required": true, "schema": { + "maxLength": 5000, "type": "string" }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } }, - "type": "array" + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/treasury.inbound_transfer" + } + } }, - "style": "deepObject" + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/test_helpers/treasury/outbound_payments/{id}": { + "post": { + "description": "

Updates a test mode created OutboundPayment with tracking details. The OutboundPayment must not be cancelable, and cannot be in the canceled or failed states.

", + "operationId": "PostTestHelpersTreasuryOutboundPaymentsId", + "parameters": [ { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, + "in": "path", + "name": "id", + "required": true, "schema": { - "type": "integer" + "maxLength": 5000, + "type": "string" }, - "style": "form" + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "tracking_details": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "tracking_details": { + "description": "Details about network-specific tracking information.", + "properties": { + "ach": { + "properties": { + "trace_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["trace_id"], + "title": "ach_tracking_details_params", + "type": "object" + }, + "type": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "us_domestic_wire": { + "properties": { + "chips": { + "maxLength": 5000, + "type": "string" + }, + "imad": { + "maxLength": 5000, + "type": "string" + }, + "omad": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "us_domestic_wire_tracking_details_params", + "type": "object" + } + }, + "required": ["type"], + "title": "tracking_details_params", + "type": "object" + } + }, + "required": ["tracking_details"], + "type": "object" + } + } + }, + "required": true + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/treasury.outbound_payment" + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/test_helpers/treasury/outbound_payments/{id}/fail": { + "post": { + "description": "

Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state.

", + "operationId": "PostTestHelpersTreasuryOutboundPaymentsIdFail", + "parameters": [ { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, + "in": "path", + "name": "id", + "required": true, "schema": { + "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/treasury.outbound_payment" + } + } + }, + "description": "Successful response." }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/test_helpers/treasury/outbound_payments/{id}/post": { + "post": { + "description": "

Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state.

", + "operationId": "PostTestHelpersTreasuryOutboundPaymentsIdPost", + "parameters": [ { - "description": "The ID of the subscription whose items will be retrieved.", - "in": "query", - "name": "subscription", + "in": "path", + "name": "id", "required": true, "schema": { "maxLength": 5000, "type": "string" }, - "style": "form" + "style": "simple" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -74484,33 +144808,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/subscription_item" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/subscription_items", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/treasury.outbound_payment" } } }, @@ -74527,56 +144825,40 @@ "description": "Error response." } } - }, + } + }, + "/v1/test_helpers/treasury/outbound_payments/{id}/return": { "post": { - "description": "

Adds a new item to an existing subscription. No existing items will be changed or replaced.

", - "operationId": "PostSubscriptionItems", + "description": "

Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.

", + "operationId": "PostTestHelpersTreasuryOutboundPaymentsIdReturn", + "parameters": [ + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "billing_thresholds": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "price_data": { - "explode": true, - "style": "deepObject" - }, - "tax_rates": { + "returned_details": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -74585,113 +144867,41 @@ }, "type": "array" }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "payment_behavior": { - "description": "Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.", - "enum": [ - "allow_incomplete", - "error_if_incomplete", - "pending_if_incomplete" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "price": { - "description": "The ID of the price object.", - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "returned_details": { + "description": "Optional hash to set the return code.", "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", + "code": { + "enum": [ + "account_closed", + "account_frozen", + "bank_account_restricted", + "bank_ownership_changed", + "declined", + "incorrect_account_holder_name", + "invalid_account_number", + "invalid_currency", + "no_account", + "other" + ], "type": "string" } }, - "required": ["currency", "product", "recurring"], - "title": "recurring_price_data", + "title": "returned_details_params", "type": "object" - }, - "proration_behavior": { - "description": "Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. Valid values are `create_prorations`, `none`, or `always_invoice`.\n\nPassing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.\n\nProrations can be disabled by passing `none`.", - "enum": ["always_invoice", "create_prorations", "none"], - "type": "string" - }, - "proration_date": { - "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.", - "format": "unix-time", - "type": "integer" - }, - "quantity": { - "description": "The quantity you'd like to apply to the subscription item you're creating.", - "type": "integer" - }, - "subscription": { - "description": "The identifier of the subscription to modify.", - "maxLength": 5000, - "type": "string" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." } }, - "required": ["subscription"], "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription_item" + "$ref": "#/components/schemas/treasury.outbound_payment" } } }, @@ -74710,14 +144920,14 @@ } } }, - "/v1/subscription_items/{item}": { - "delete": { - "description": "

Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.

", - "operationId": "DeleteSubscriptionItemsItem", + "/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}": { + "post": { + "description": "

Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.

", + "operationId": "PostTestHelpersTreasuryOutboundTransfersOutboundTransfer", "parameters": [ { "in": "path", - "name": "item", + "name": "outbound_transfer", "required": true, "schema": { "maxLength": 5000, @@ -74729,36 +144939,82 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "tracking_details": { + "explode": true, + "style": "deepObject" + } + }, "schema": { + "additionalProperties": false, "properties": { - "clear_usage": { - "description": "Delete all usage for the given subscription item. Allowed only when the current plan's `usage_type` is `metered`.", - "type": "boolean" - }, - "proration_behavior": { - "description": "Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. Valid values are `create_prorations`, `none`, or `always_invoice`.\n\nPassing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.\n\nProrations can be disabled by passing `none`.", - "enum": ["always_invoice", "create_prorations", "none"], - "type": "string" + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" }, - "proration_date": { - "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.", - "format": "unix-time", - "type": "integer" + "tracking_details": { + "description": "Details about network-specific tracking information.", + "properties": { + "ach": { + "properties": { + "trace_id": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["trace_id"], + "title": "ach_tracking_details_params", + "type": "object" + }, + "type": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + }, + "us_domestic_wire": { + "properties": { + "chips": { + "maxLength": 5000, + "type": "string" + }, + "imad": { + "maxLength": 5000, + "type": "string" + }, + "omad": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "us_domestic_wire_tracking_details_params", + "type": "object" + } + }, + "required": ["type"], + "title": "tracking_details_params", + "type": "object" } }, + "required": ["tracking_details"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_subscription_item" + "$ref": "#/components/schemas/treasury.outbound_transfer" } } }, @@ -74775,29 +145031,16 @@ "description": "Error response." } } - }, - "get": { - "description": "

Retrieves the subscription item with the given ID.

", - "operationId": "GetSubscriptionItemsItem", + } + }, + "/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/fail": { + "post": { + "description": "

Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.

", + "operationId": "PostTestHelpersTreasuryOutboundTransfersOutboundTransferFail", "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, { "in": "path", - "name": "item", + "name": "outbound_transfer", "required": true, "schema": { "maxLength": 5000, @@ -74809,9 +145052,24 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + } + }, "type": "object" } } @@ -74823,7 +145081,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription_item" + "$ref": "#/components/schemas/treasury.outbound_transfer" } } }, @@ -74840,14 +145098,16 @@ "description": "Error response." } } - }, + } + }, + "/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/post": { "post": { - "description": "

Updates the plan or quantity of an item on a current subscription.

", - "operationId": "PostSubscriptionItemsItem", + "description": "

Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.

", + "operationId": "PostTestHelpersTreasuryOutboundTransfersOutboundTransferPost", "parameters": [ { "in": "path", - "name": "item", + "name": "outbound_transfer", "required": true, "schema": { "maxLength": 5000, @@ -74860,48 +145120,14 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "billing_thresholds": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "price_data": { - "explode": true, - "style": "deepObject" - }, - "tax_rates": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -74909,106 +145135,6 @@ "type": "string" }, "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "off_session": { - "description": "Indicates if a customer is on or off-session while an invoice payment is attempted.", - "type": "boolean" - }, - "payment_behavior": { - "description": "Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.", - "enum": [ - "allow_incomplete", - "error_if_incomplete", - "pending_if_incomplete" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "price": { - "description": "The ID of the price object.", - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product", "recurring"], - "title": "recurring_price_data", - "type": "object" - }, - "proration_behavior": { - "description": "Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. Valid values are `create_prorations`, `none`, or `always_invoice`.\n\nPassing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.\n\nProrations can be disabled by passing `none`.", - "enum": ["always_invoice", "create_prorations", "none"], - "type": "string" - }, - "proration_date": { - "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.", - "format": "unix-time", - "type": "integer" - }, - "quantity": { - "description": "The quantity you'd like to apply to the subscription item you're creating.", - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." } }, "type": "object" @@ -75022,7 +145148,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription_item" + "$ref": "#/components/schemas/treasury.outbound_transfer" } } }, @@ -75041,63 +145167,17 @@ } } }, - "/v1/subscription_items/{subscription_item}/usage_record_summaries": { - "get": { - "description": "

For the specified subscription item, returns a list of summary objects. Each object in the list provides usage information that’s been summarized from multiple usage records and over a subscription billing period (e.g., 15 usage records in the month of September).

\n\n

The list is sorted in reverse-chronological order (newest first). The first list item represents the most current usage period that hasn’t ended yet. Since new usage records can still be added, the returned summary information for the subscription item’s ID should be seen as unstable until the subscription billing period ends.

", - "operationId": "GetSubscriptionItemsSubscriptionItemUsageRecordSummaries", + "/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/return": { + "post": { + "description": "

Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.

", + "operationId": "PostTestHelpersTreasuryOutboundTransfersOutboundTransferReturn", "parameters": [ - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, { "in": "path", - "name": "subscription_item", + "name": "outbound_transfer", "required": true, "schema": { + "maxLength": 5000, "type": "string" }, "style": "simple" @@ -75106,9 +145186,50 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "returned_details": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "returned_details": { + "description": "Details about a returned OutboundTransfer.", + "properties": { + "code": { + "enum": [ + "account_closed", + "account_frozen", + "bank_account_restricted", + "bank_ownership_changed", + "declined", + "incorrect_account_holder_name", + "invalid_account_number", + "invalid_currency", + "no_account", + "other" + ], + "type": "string" + } + }, + "title": "returned_details_params", + "type": "object" + } + }, "type": "object" } } @@ -75120,32 +145241,7 @@ "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/usage_record_summary" - }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" - }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] + "$ref": "#/components/schemas/treasury.outbound_transfer" } } }, @@ -75164,21 +145260,10 @@ } } }, - "/v1/subscription_items/{subscription_item}/usage_records": { + "/v1/test_helpers/treasury/received_credits": { "post": { - "description": "

Creates a usage record for a specified subscription item and date, and fills it with a quantity.

\n\n

Usage records provide quantity information that Stripe uses to track how much a customer is using your service. With usage information and the pricing model set up by the metered billing plan, Stripe helps you send accurate invoices to your customers.

\n\n

The default calculation for usage is to add up all the quantity values of the usage records within a billing period. You can change this default behavior with the billing plan’s aggregate_usage parameter. When there is more than one usage record with the same timestamp, Stripe adds the quantity values together. In most cases, this is the desired resolution, however, you can change this behavior with the action parameter.

\n\n

The default pricing model for metered billing is per-unit pricing. For finer granularity, you can configure metered billing to have a tiered pricing model.

", - "operationId": "PostSubscriptionItemsSubscriptionItemUsageRecords", - "parameters": [ - { - "in": "path", - "name": "subscription_item", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - ], + "description": "

Use this endpoint to simulate a test mode ReceivedCredit initiated by a third party. In live mode, you can’t directly create ReceivedCredits initiated by third parties.

", + "operationId": "PostTestHelpersTreasuryReceivedCredits", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -75186,13 +145271,26 @@ "expand": { "explode": true, "style": "deepObject" + }, + "initiating_payment_method_details": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "action": { - "description": "Valid values are `increment` (default) or `set`. When using `increment` the specified `quantity` will be added to the usage at the specified timestamp. The `set` action will overwrite the usage quantity at that timestamp. If the subscription has [billing thresholds](https://stripe.com/docs/api/subscriptions/object#subscription_object-billing_thresholds), `increment` is the only allowed value.", - "enum": ["increment", "set"], + "amount": { + "description": "Amount (in cents) to be transferred.", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, "type": "string" }, "expand": { @@ -75203,16 +145301,52 @@ }, "type": "array" }, - "quantity": { - "description": "The usage quantity for the specified timestamp.", - "type": "integer" + "financial_account": { + "description": "The FinancialAccount to send funds to.", + "type": "string" }, - "timestamp": { - "description": "The timestamp for the usage event. This timestamp must be within the current billing period of the subscription of the provided `subscription_item`.", - "type": "integer" + "initiating_payment_method_details": { + "description": "Initiating payment method details for the object.", + "properties": { + "type": { + "enum": ["us_bank_account"], + "type": "string" + }, + "us_bank_account": { + "properties": { + "account_holder_name": { + "maxLength": 5000, + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "us_bank_account_source_params", + "type": "object" + } + }, + "required": ["type"], + "title": "source_params", + "type": "object" + }, + "network": { + "description": "Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.", + "enum": ["ach", "us_domestic_wire"], + "type": "string" } }, - "required": ["quantity", "timestamp"], + "required": [ + "amount", + "currency", + "financial_account", + "network" + ], "type": "object" } } @@ -75224,7 +145358,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/usage_record" + "$ref": "#/components/schemas/treasury.received_credit" } } }, @@ -75243,385 +145377,848 @@ } } }, - "/v1/subscription_schedules": { - "get": { - "description": "

Retrieves the list of your subscription schedules.

", - "operationId": "GetSubscriptionSchedules", - "parameters": [ - { - "description": "Only return subscription schedules that were created canceled the given date interval.", - "explode": true, - "in": "query", - "name": "canceled_at", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" + "/v1/test_helpers/treasury/received_debits": { + "post": { + "description": "

Use this endpoint to simulate a test mode ReceivedDebit initiated by a third party. In live mode, you can’t directly create ReceivedDebits initiated by third parties.

", + "operationId": "PostTestHelpersTreasuryReceivedDebits", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" }, - { - "type": "integer" + "initiating_payment_method_details": { + "explode": true, + "style": "deepObject" } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return subscription schedules that completed during the given date interval.", - "explode": true, - "in": "query", - "name": "completed_at", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "Amount (in cents) to be transferred.", + "type": "integer" }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return subscription schedules that were created during the given date interval.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return subscription schedules for the given customer.", - "in": "query", - "name": "customer", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", - "in": "query", - "name": "ending_before", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", - "in": "query", - "name": "limit", - "required": false, - "schema": { - "type": "integer" - }, - "style": "form" - }, - { - "description": "Only return subscription schedules that were released during the given date interval.", - "explode": true, - "in": "query", - "name": "released_at", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "type": "string" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "lt": { - "type": "integer" + "type": "array" + }, + "financial_account": { + "description": "The FinancialAccount to pull funds from.", + "type": "string" + }, + "initiating_payment_method_details": { + "description": "Initiating payment method details for the object.", + "properties": { + "type": { + "enum": ["us_bank_account"], + "type": "string" + }, + "us_bank_account": { + "properties": { + "account_holder_name": { + "maxLength": 5000, + "type": "string" + }, + "account_number": { + "maxLength": 5000, + "type": "string" + }, + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "us_bank_account_source_params", + "type": "object" + } }, - "lte": { - "type": "integer" - } + "required": ["type"], + "title": "source_params", + "type": "object" }, - "title": "range_query_specs", - "type": "object" + "network": { + "description": "Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.", + "enum": ["ach"], + "type": "string" + } }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return subscription schedules that have not started yet.", - "in": "query", - "name": "scheduled", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, - { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", - "in": "query", - "name": "starting_after", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, + "required": [ + "amount", + "currency", + "financial_account", + "network" + ], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "description": "", - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/subscription_schedule" + "$ref": "#/components/schemas/treasury.received_debit" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/tokens": { + "post": { + "description": "

Creates a single-use token that represents a bank account’s details.\nYou can use this token with any API method in place of a bank account dictionary. You can only use this token once. To do so, attach it to a connected account where controller.requirement_collection is application, which includes Custom accounts.

", + "operationId": "PostTokens", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "account": { + "explode": true, + "style": "deepObject" + }, + "bank_account": { + "explode": true, + "style": "deepObject" + }, + "card": { + "explode": true, + "style": "deepObject" + }, + "cvc_update": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "person": { + "explode": true, + "style": "deepObject" + }, + "pii": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "account": { + "description": "Information for the account this token represents.", + "properties": { + "business_type": { + "enum": [ + "company", + "government_entity", + "individual", + "non_profit" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "company": { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "legal_entity_and_kyc_address_specs", + "type": "object" + }, + "address_kana": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "directors_provided": { + "type": "boolean" + }, + "executives_provided": { + "type": "boolean" + }, + "export_license_id": { + "maxLength": 5000, + "type": "string" + }, + "export_purpose_code": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 100, + "type": "string" + }, + "name_kana": { + "maxLength": 100, + "type": "string" + }, + "name_kanji": { + "maxLength": 100, + "type": "string" + }, + "owners_provided": { + "type": "boolean" + }, + "ownership_declaration": { + "properties": { + "date": { + "format": "unix-time", + "type": "integer" + }, + "ip": { + "type": "string" + }, + "user_agent": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "company_ownership_declaration", + "type": "object" + }, + "ownership_declaration_shown_and_signed": { + "type": "boolean" + }, + "phone": { + "maxLength": 5000, + "type": "string" + }, + "registration_number": { + "maxLength": 5000, + "type": "string" + }, + "structure": { + "enum": [ + "", + "free_zone_establishment", + "free_zone_llc", + "government_instrumentality", + "governmental_unit", + "incorporated_non_profit", + "incorporated_partnership", + "limited_liability_partnership", + "llc", + "multi_member_llc", + "private_company", + "private_corporation", + "private_partnership", + "public_company", + "public_corporation", + "public_partnership", + "registered_charity", + "single_member_llc", + "sole_establishment", + "sole_proprietorship", + "tax_exempt_government_instrumentality", + "unincorporated_association", + "unincorporated_non_profit", + "unincorporated_partnership" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "tax_id": { + "maxLength": 5000, + "type": "string" + }, + "tax_id_registrar": { + "maxLength": 5000, + "type": "string" + }, + "vat_id": { + "maxLength": 5000, + "type": "string" + }, + "verification": { + "properties": { + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "verification_document_specs", + "type": "object" + } + }, + "title": "verification_specs", + "type": "object" + } + }, + "title": "connect_js_account_token_company_specs", + "type": "object" }, - "type": "array" - }, - "has_more": { - "description": "True if this list has another page of items after this one that can be fetched.", - "type": "boolean" - }, - "object": { - "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", - "enum": ["list"], - "type": "string" + "individual": { + "properties": { + "address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "address_kana": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "japan_address_kanji_specs", + "type": "object" + }, + "dob": { + "anyOf": [ + { + "properties": { + "day": { + "type": "integer" + }, + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } + }, + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "email": { + "type": "string" + }, + "first_name": { + "maxLength": 100, + "type": "string" + }, + "first_name_kana": { + "maxLength": 5000, + "type": "string" + }, + "first_name_kanji": { + "maxLength": 5000, + "type": "string" + }, + "full_name_aliases": { + "anyOf": [ + { + "items": { + "maxLength": 300, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "gender": { + "type": "string" + }, + "id_number": { + "maxLength": 5000, + "type": "string" + }, + "id_number_secondary": { + "maxLength": 5000, + "type": "string" + }, + "last_name": { + "maxLength": 100, + "type": "string" + }, + "last_name_kana": { + "maxLength": 5000, + "type": "string" + }, + "last_name_kanji": { + "maxLength": 5000, + "type": "string" + }, + "maiden_name": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "phone": { + "type": "string" + }, + "political_exposure": { + "enum": ["existing", "none"], + "type": "string" + }, + "registered_address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "address_specs", + "type": "object" + }, + "relationship": { + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "percent_ownership": { + "anyOf": [ + { + "type": "number" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "title": { + "maxLength": 5000, + "type": "string" + } + }, + "title": "individual_relationship_specs", + "type": "object" + }, + "ssn_last_4": { + "maxLength": 5000, + "type": "string" + }, + "verification": { + "properties": { + "additional_document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + }, + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } + }, + "title": "person_verification_document_specs", + "type": "object" + } + }, + "title": "person_verification_specs", + "type": "object" + } + }, + "title": "individual_specs", + "type": "object" + }, + "tos_shown_and_accepted": { + "type": "boolean" + } }, - "url": { - "description": "The URL where this list can be accessed.", - "maxLength": 5000, - "pattern": "^/v1/subscription_schedules", - "type": "string" - } - }, - "required": ["data", "has_more", "object", "url"], - "type": "object", - "x-expandableFields": ["data"] - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Creates a new subscription schedule object. Each customer can have up to 500 active or scheduled subscriptions.

", - "operationId": "PostSubscriptionSchedules", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "default_settings": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "phases": { - "explode": true, - "style": "deepObject" - }, - "start_date": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "customer": { - "description": "The identifier of the customer to create the subscription schedule for.", - "maxLength": 5000, - "type": "string" + "title": "connect_js_account_token_specs", + "type": "object" }, - "default_settings": { - "description": "Object representing the subscription schedule's default settings.", + "bank_account": { + "description": "The bank account this token will represent.", "properties": { - "application_fee_percent": { - "type": "number" + "account_holder_name": { + "maxLength": 5000, + "type": "string" + }, + "account_holder_type": { + "enum": ["company", "individual"], + "maxLength": 5000, + "type": "string" }, - "billing_cycle_anchor": { - "enum": ["automatic", "phase_start"], + "account_number": { + "maxLength": 5000, "type": "string" }, - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "amount_gte": { - "type": "integer" - }, - "reset_billing_cycle_anchor": { - "type": "boolean" - } - }, - "title": "billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] + "account_type": { + "enum": ["checking", "futsu", "savings", "toza"], + "maxLength": 5000, + "type": "string" }, - "collection_method": { - "enum": ["charge_automatically", "send_invoice"], + "country": { + "maxLength": 5000, "type": "string" }, - "default_payment_method": { + "currency": { + "type": "string" + }, + "payment_method": { "maxLength": 5000, "type": "string" }, - "invoice_settings": { + "routing_number": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["account_number", "country"], + "title": "token_create_bank_account", + "type": "object", + "x-stripeBypassValidation": true + }, + "card": { + "anyOf": [ + { "properties": { - "days_until_due": { - "type": "integer" - } - }, - "title": "subscription_schedules_param", - "type": "object" - }, - "transfer_data": { - "anyOf": [ - { + "address_city": { + "maxLength": 5000, + "type": "string" + }, + "address_country": { + "maxLength": 5000, + "type": "string" + }, + "address_line1": { + "maxLength": 5000, + "type": "string" + }, + "address_line2": { + "maxLength": 5000, + "type": "string" + }, + "address_state": { + "maxLength": 5000, + "type": "string" + }, + "address_zip": { + "maxLength": 5000, + "type": "string" + }, + "currency": { + "maxLength": 5000, + "type": "string" + }, + "cvc": { + "maxLength": 5000, + "type": "string" + }, + "exp_month": { + "maxLength": 5000, + "type": "string" + }, + "exp_year": { + "maxLength": 5000, + "type": "string" + }, + "name": { + "maxLength": 5000, + "type": "string" + }, + "networks": { "properties": { - "amount_percent": { - "type": "number" - }, - "destination": { + "preferred": { + "enum": [ + "cartes_bancaires", + "mastercard", + "visa" + ], "type": "string" } }, - "required": ["destination"], - "title": "transfer_data_specs", + "title": "networks_param_specs", "type": "object" }, - { - "enum": [""], + "number": { + "maxLength": 5000, "type": "string" } - ] + }, + "required": ["exp_month", "exp_year", "number"], + "title": "credit_card_specs", + "type": "object" + }, + { + "maxLength": 5000, + "type": "string" } - }, - "title": "default_settings_params", - "type": "object" + ], + "description": "The card this token will represent. If you also pass in a customer, the card must be the ID of a card belonging to the customer. Otherwise, if you do not pass in a customer, this is a dictionary containing a user's credit card details, with the options described below.", + "x-stripeBypassValidation": true }, - "end_behavior": { - "description": "Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription.", - "enum": ["cancel", "none", "release", "renew"], + "customer": { + "description": "Create a token for the customer, which is owned by the application's account. You can only use this with an [OAuth access token](https://stripe.com/docs/connect/standard-accounts) or [Stripe-Account header](https://stripe.com/docs/connect/authentication). Learn more about [cloning saved payment methods](https://stripe.com/docs/connect/cloning-saved-payment-methods).", + "maxLength": 5000, "type": "string" }, + "cvc_update": { + "description": "The updated CVC value this token represents.", + "properties": { + "cvc": { + "maxLength": 5000, + "type": "string" + } + }, + "required": ["cvc"], + "title": "cvc_params", + "type": "object" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -75630,69 +146227,25 @@ }, "type": "array" }, - "from_subscription": { - "description": "Migrate an existing subscription to be managed by a subscription schedule. If this parameter is set, a subscription schedule will be created using the subscription's item(s), set to auto-renew using the subscription's interval. When using this parameter, other parameters (such as phase values) cannot be set. To create a subscription schedule with other modifications, we recommend making two separate API calls.", - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "phases": { - "description": "List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.", - "items": { - "properties": { - "add_invoice_items": { - "items": { + "person": { + "description": "Information for the person this token represents.", + "properties": { + "additional_tos_acceptances": { + "properties": { + "account": { "properties": { - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product"], - "title": "one_time_price_data", - "type": "object" - }, - "quantity": { + "date": { + "format": "unix-time", "type": "integer" }, - "tax_rates": { + "ip": { + "type": "string" + }, + "user_agent": { "anyOf": [ { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" + "maxLength": 5000, + "type": "string" }, { "enum": [""], @@ -75701,221 +146254,403 @@ ] } }, - "title": "add_invoice_item_entry", + "title": "settings_terms_of_service_specs", "type": "object" + } + }, + "title": "person_additional_tos_acceptances_specs", + "type": "object" + }, + "address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" }, - "type": "array" + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } }, - "application_fee_percent": { - "type": "number" + "title": "legal_entity_and_kyc_address_specs", + "type": "object" + }, + "address_kana": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } }, - "billing_cycle_anchor": { - "enum": ["automatic", "phase_start"], - "type": "string" + "title": "japan_address_kana_specs", + "type": "object" + }, + "address_kanji": { + "properties": { + "city": { + "maxLength": 5000, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + }, + "town": { + "maxLength": 5000, + "type": "string" + } }, - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "amount_gte": { - "type": "integer" - }, - "reset_billing_cycle_anchor": { - "type": "boolean" - } + "title": "japan_address_kanji_specs", + "type": "object" + }, + "dob": { + "anyOf": [ + { + "properties": { + "day": { + "type": "integer" }, - "title": "billing_thresholds_param", - "type": "object" + "month": { + "type": "integer" + }, + "year": { + "type": "integer" + } }, - { - "enum": [""], - "type": "string" - } - ] - }, - "collection_method": { - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "coupon": { - "maxLength": 5000, - "type": "string" + "required": ["day", "month", "year"], + "title": "date_of_birth_specs", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "documents": { + "properties": { + "company_authorization": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "passport": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + }, + "visa": { + "properties": { + "files": { + "items": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "type": "array" + } + }, + "title": "documents_param", + "type": "object" + } }, - "default_payment_method": { - "maxLength": 5000, - "type": "string" + "title": "person_documents_specs", + "type": "object" + }, + "email": { + "type": "string" + }, + "first_name": { + "maxLength": 5000, + "type": "string" + }, + "first_name_kana": { + "maxLength": 5000, + "type": "string" + }, + "first_name_kanji": { + "maxLength": 5000, + "type": "string" + }, + "full_name_aliases": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "gender": { + "type": "string" + }, + "id_number": { + "maxLength": 5000, + "type": "string" + }, + "id_number_secondary": { + "maxLength": 5000, + "type": "string" + }, + "last_name": { + "maxLength": 5000, + "type": "string" + }, + "last_name_kana": { + "maxLength": 5000, + "type": "string" + }, + "last_name_kanji": { + "maxLength": 5000, + "type": "string" + }, + "maiden_name": { + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + }, + "nationality": { + "maxLength": 5000, + "type": "string" + }, + "phone": { + "type": "string" + }, + "political_exposure": { + "maxLength": 5000, + "type": "string" + }, + "registered_address": { + "properties": { + "city": { + "maxLength": 100, + "type": "string" + }, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 200, + "type": "string" + }, + "line2": { + "maxLength": 200, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, + "type": "string" + } }, - "default_tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" + "title": "address_specs", + "type": "object" + }, + "relationship": { + "properties": { + "director": { + "type": "boolean" + }, + "executive": { + "type": "boolean" + }, + "legal_guardian": { + "type": "boolean" + }, + "owner": { + "type": "boolean" + }, + "percent_ownership": { + "anyOf": [ + { + "type": "number" }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "end_date": { - "format": "unix-time", - "type": "integer" - }, - "invoice_settings": { - "properties": { - "days_until_due": { - "type": "integer" - } + { + "enum": [""], + "type": "string" + } + ] }, - "title": "subscription_schedules_param", - "type": "object" + "representative": { + "type": "boolean" + }, + "title": { + "maxLength": 5000, + "type": "string" + } }, - "items": { - "items": { + "title": "relationship_specs", + "type": "object" + }, + "ssn_last_4": { + "type": "string" + }, + "verification": { + "properties": { + "additional_document": { "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "price": { - "maxLength": 5000, + "back": { + "maxLength": 500, "type": "string" }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": [ - "day", - "month", - "week", - "year" - ], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": [ - "currency", - "product", - "recurring" - ], - "title": "recurring_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] + "front": { + "maxLength": 500, + "type": "string" } }, - "title": "configuration_item_params", + "title": "person_verification_document_specs", "type": "object" }, - "type": "array" - }, - "iterations": { - "type": "integer" - }, - "proration_behavior": { - "enum": [ - "always_invoice", - "create_prorations", - "none" - ], - "type": "string" - }, - "transfer_data": { - "properties": { - "amount_percent": { - "type": "number" + "document": { + "properties": { + "back": { + "maxLength": 500, + "type": "string" + }, + "front": { + "maxLength": 500, + "type": "string" + } }, - "destination": { - "type": "string" - } - }, - "required": ["destination"], - "title": "transfer_data_specs", - "type": "object" - }, - "trial": { - "type": "boolean" + "title": "person_verification_document_specs", + "type": "object" + } }, - "trial_end": { - "format": "unix-time", - "type": "integer" - } - }, - "required": ["items"], - "title": "phase_configuration_params", - "type": "object" + "title": "person_verification_specs", + "type": "object" + } }, - "type": "array" + "title": "person_token_specs", + "type": "object" }, - "start_date": { - "anyOf": [ - { - "type": "integer" - }, - { - "enum": ["now"], + "pii": { + "description": "The PII this token represents.", + "properties": { + "id_number": { "maxLength": 5000, "type": "string" } - ], - "description": "When the subscription schedule starts. We recommend using `now` so that it starts the subscription immediately. You can also use a Unix timestamp to backdate the subscription so that it starts on a past date, or set a future date for the subscription to start on." + }, + "title": "pii_token_specs", + "type": "object" } }, "type": "object" @@ -75929,7 +146664,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription_schedule" + "$ref": "#/components/schemas/token" } } }, @@ -75948,10 +146683,10 @@ } } }, - "/v1/subscription_schedules/{schedule}": { + "/v1/tokens/{token}": { "get": { - "description": "

Retrieves the details of an existing subscription schedule. You only need to supply the unique subscription schedule identifier that was returned upon subscription schedule creation.

", - "operationId": "GetSubscriptionSchedulesSchedule", + "description": "

Retrieves the token with the given ID.

", + "operationId": "GetTokensToken", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -75970,7 +146705,7 @@ }, { "in": "path", - "name": "schedule", + "name": "token", "required": true, "schema": { "maxLength": 5000, @@ -75984,6 +146719,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -75996,7 +146732,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription_schedule" + "$ref": "#/components/schemas/token" } } }, @@ -76013,30 +146749,209 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates an existing subscription schedule.

", - "operationId": "PostSubscriptionSchedulesSchedule", + } + }, + "/v1/topups": { + "get": { + "description": "

Returns a list of top-ups.

", + "operationId": "GetTopups", "parameters": [ { - "in": "path", - "name": "schedule", - "required": true, + "description": "A positive integer representing how much to transfer.", + "explode": true, + "in": "query", + "name": "amount", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return top-ups that have the given status. One of `canceled`, `failed`, `pending` or `succeeded`.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["canceled", "failed", "pending", "succeeded"], + "maxLength": 5000, + "type": "string" + }, + "style": "form" } ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/topup" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/topups", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TopupList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Top up the balance of an account

", + "operationId": "PostTopups", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "default_settings": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" @@ -76044,89 +146959,22 @@ "metadata": { "explode": true, "style": "deepObject" - }, - "phases": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "default_settings": { - "description": "Object representing the subscription schedule's default settings.", - "properties": { - "application_fee_percent": { - "type": "number" - }, - "billing_cycle_anchor": { - "enum": ["automatic", "phase_start"], - "type": "string" - }, - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "amount_gte": { - "type": "integer" - }, - "reset_billing_cycle_anchor": { - "type": "boolean" - } - }, - "title": "billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "collection_method": { - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "default_payment_method": { - "maxLength": 5000, - "type": "string" - }, - "invoice_settings": { - "properties": { - "days_until_due": { - "type": "integer" - } - }, - "title": "subscription_schedules_param", - "type": "object" - }, - "transfer_data": { - "anyOf": [ - { - "properties": { - "amount_percent": { - "type": "number" - }, - "destination": { - "type": "string" - } - }, - "required": ["destination"], - "title": "transfer_data_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "default_settings_params", - "type": "object" + "amount": { + "description": "A positive integer representing how much to transfer.", + "type": "integer" }, - "end_behavior": { - "description": "Configures how the subscription schedule behaves when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running.`cancel` will end the subscription schedule and cancel the underlying subscription.", - "enum": ["cancel", "none", "release", "renew"], + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, "type": "string" }, "expand": { @@ -76152,306 +147000,34 @@ ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "phases": { - "description": "List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase. Note that past phases can be omitted.", - "items": { - "properties": { - "add_invoice_items": { - "items": { - "properties": { - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product"], - "title": "one_time_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "add_invoice_item_entry", - "type": "object" - }, - "type": "array" - }, - "application_fee_percent": { - "type": "number" - }, - "billing_cycle_anchor": { - "enum": ["automatic", "phase_start"], - "type": "string" - }, - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "amount_gte": { - "type": "integer" - }, - "reset_billing_cycle_anchor": { - "type": "boolean" - } - }, - "title": "billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "collection_method": { - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "coupon": { - "maxLength": 5000, - "type": "string" - }, - "default_payment_method": { - "maxLength": 5000, - "type": "string" - }, - "default_tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "end_date": { - "anyOf": [ - { - "type": "integer" - }, - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - } - ] - }, - "invoice_settings": { - "properties": { - "days_until_due": { - "type": "integer" - } - }, - "title": "subscription_schedules_param", - "type": "object" - }, - "items": { - "items": { - "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": [ - "day", - "month", - "week", - "year" - ], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": [ - "currency", - "product", - "recurring" - ], - "title": "recurring_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "configuration_item_params", - "type": "object" - }, - "type": "array" - }, - "iterations": { - "type": "integer" - }, - "proration_behavior": { - "enum": [ - "always_invoice", - "create_prorations", - "none" - ], - "type": "string" - }, - "start_date": { - "anyOf": [ - { - "type": "integer" - }, - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - } - ] - }, - "transfer_data": { - "properties": { - "amount_percent": { - "type": "number" - }, - "destination": { - "type": "string" - } - }, - "required": ["destination"], - "title": "transfer_data_specs", - "type": "object" - }, - "trial": { - "type": "boolean" - }, - "trial_end": { - "anyOf": [ - { - "type": "integer" - }, - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - } - ] - } - }, - "required": ["items"], - "title": "phase_configuration_params", - "type": "object" - }, - "type": "array" + "source": { + "description": "The ID of a source to transfer funds from. For most users, this should be left unspecified which will use the bank account that was set up in the dashboard for the specified currency. In test mode, this can be a test bank token (see [Testing Top-ups](https://stripe.com/docs/connect/testing#testing-top-ups)).", + "maxLength": 5000, + "type": "string" }, - "proration_behavior": { - "description": "If the update changes the current phase, indicates if the changes should be prorated. Possible values are `create_prorations` or `none`, and the default value is `create_prorations`.", - "enum": ["always_invoice", "create_prorations", "none"], + "statement_descriptor": { + "description": "Extra information about a top-up for the source's bank statement. Limited to 15 ASCII characters.", + "maxLength": 15, + "type": "string" + }, + "transfer_group": { + "description": "A string that identifies this top-up as part of a group.", "type": "string" } }, + "required": ["amount", "currency"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription_schedule" + "$ref": "#/components/schemas/topup" } } }, @@ -76470,14 +147046,80 @@ } } }, - "/v1/subscription_schedules/{schedule}/cancel": { + "/v1/topups/{topup}": { + "get": { + "description": "

Retrieves the details of a top-up that has previously been created. Supply the unique top-up ID that was returned from your previous request, and Stripe will return the corresponding top-up information.

", + "operationId": "GetTopupsTopup", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "topup", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/topup" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, "post": { - "description": "

Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active.

", - "operationId": "PostSubscriptionSchedulesScheduleCancel", + "description": "

Updates the metadata of a top-up. Other top-up details are not editable by design.

", + "operationId": "PostTopupsTopup", "parameters": [ { "in": "path", - "name": "schedule", + "name": "topup", "required": true, "schema": { "maxLength": 5000, @@ -76493,10 +147135,20 @@ "expand": { "explode": true, "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "type": "string" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -76505,13 +147157,20 @@ }, "type": "array" }, - "invoice_now": { - "description": "If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Defaults to `true`.", - "type": "boolean" - }, - "prorate": { - "description": "If the subscription schedule is `active`, indicates if the cancellation should be prorated. Defaults to `true`.", - "type": "boolean" + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." } }, "type": "object" @@ -76525,7 +147184,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription_schedule" + "$ref": "#/components/schemas/topup" } } }, @@ -76544,14 +147203,14 @@ } } }, - "/v1/subscription_schedules/{schedule}/release": { + "/v1/topups/{topup}/cancel": { "post": { - "description": "

Releases the subscription schedule immediately, which will stop scheduling of its phases, but leave any existing subscription in place. A schedule can only be released if its status is not_started or active. If the subscription schedule is currently associated with a subscription, releasing it will remove its subscription property and set the subscription’s ID to the released_subscription property.

", - "operationId": "PostSubscriptionSchedulesScheduleRelease", + "description": "

Cancels a top-up. Only pending top-ups can be canceled.

", + "operationId": "PostTopupsTopupCancel", "parameters": [ { "in": "path", - "name": "schedule", + "name": "topup", "required": true, "schema": { "maxLength": 5000, @@ -76570,6 +147229,7 @@ } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -76578,10 +147238,6 @@ "type": "string" }, "type": "array" - }, - "preserve_cancel_date": { - "description": "Keep any cancellation on the subscription that the schedule has set", - "type": "boolean" } }, "type": "object" @@ -76595,7 +147251,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription_schedule" + "$ref": "#/components/schemas/topup" } } }, @@ -76614,23 +147270,13 @@ } } }, - "/v1/subscriptions": { + "/v1/transfers": { "get": { - "description": "

By default, returns a list of subscriptions that have not been canceled. In order to list canceled subscriptions, specify status=canceled.

", - "operationId": "GetSubscriptions", + "description": "

Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.

", + "operationId": "GetTransfers", "parameters": [ { - "description": "The collection method of the subscriptions to retrieve. Either `charge_automatically` or `send_invoice`.", - "in": "query", - "name": "collection_method", - "required": false, - "schema": { - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "style": "form" - }, - { + "description": "Only return transfers that were created during the given date interval.", "explode": true, "in": "query", "name": "created", @@ -76663,73 +147309,9 @@ "style": "deepObject" }, { - "explode": true, - "in": "query", - "name": "current_period_end", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "explode": true, - "in": "query", - "name": "current_period_start", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "The ID of the customer whose subscriptions will be retrieved.", + "description": "Only return transfers for the destination specified by this account ID.", "in": "query", - "name": "customer", + "name": "destination", "required": false, "schema": { "maxLength": 5000, @@ -76773,17 +147355,6 @@ }, "style": "form" }, - { - "description": "Filter for subscriptions that contain this recurring price ID.", - "in": "query", - "name": "price", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -76796,22 +147367,12 @@ "style": "form" }, { - "description": "The status of the subscriptions to retrieve. Passing in a value of `canceled` will return all canceled subscriptions, including those belonging to deleted customers. Pass `ended` to find subscriptions that are canceled and subscriptions that are expired due to [incomplete payment](https://stripe.com/docs/billing/subscriptions/overview#subscription-statuses). Passing in a value of `all` will return subscriptions of all statuses.", + "description": "Only return transfers with the specified transfer group.", "in": "query", - "name": "status", + "name": "transfer_group", "required": false, "schema": { - "enum": [ - "active", - "all", - "canceled", - "ended", - "incomplete", - "incomplete_expired", - "past_due", - "trialing", - "unpaid" - ], + "maxLength": 5000, "type": "string" }, "style": "form" @@ -76822,6 +147383,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -76837,8 +147399,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/subscription" + "$ref": "#/components/schemas/transfer" }, "type": "array" }, @@ -76854,11 +147417,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/subscriptions", + "pattern": "^/v1/transfers", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "TransferList", "type": "object", "x-expandableFields": ["data"] } @@ -76879,194 +147443,41 @@ } }, "post": { - "description": "

Creates a new subscription on an existing customer. Each customer can have up to 500 active or scheduled subscriptions.

", - "operationId": "PostSubscriptions", + "description": "

To send funds from your Stripe account to a connected account, you create a new transfer object. Your Stripe balance must be able to cover the transfer amount, or you’ll receive an “Insufficient Funds” error.

", + "operationId": "PostTransfers", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "add_invoice_items": { - "explode": true, - "style": "deepObject" - }, - "billing_thresholds": { - "explode": true, - "style": "deepObject" - }, - "default_tax_rates": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" }, - "items": { - "explode": true, - "style": "deepObject" - }, "metadata": { "explode": true, "style": "deepObject" - }, - "pending_invoice_item_interval": { - "explode": true, - "style": "deepObject" - }, - "transfer_data": { - "explode": true, - "style": "deepObject" - }, - "trial_end": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "add_invoice_items": { - "description": "A list of prices and quantities that will generate invoice items appended to the first invoice for this subscription. You may pass up to 10 items.", - "items": { - "properties": { - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product"], - "title": "one_time_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "add_invoice_item_entry", - "type": "object" - }, - "type": "array" - }, - "application_fee_percent": { - "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).", - "type": "number" - }, - "backdate_start_date": { - "description": "For new subscriptions, a past timestamp to backdate the subscription's start date to. If set, the first invoice will contain a proration for the timespan between the start date and the current time. Can be combined with trials and the billing cycle anchor.", - "format": "unix-time", - "type": "integer" - }, - "billing_cycle_anchor": { - "description": "A future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices.", - "format": "unix-time", - "type": "integer", - "x-stripeBypassValidation": true - }, - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "amount_gte": { - "type": "integer" - }, - "reset_billing_cycle_anchor": { - "type": "boolean" - } - }, - "title": "billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." - }, - "cancel_at": { - "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.", - "format": "unix-time", + "amount": { + "description": "A positive integer in cents (or local equivalent) representing how much to transfer.", "type": "integer" }, - "cancel_at_period_end": { - "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", - "type": "boolean" - }, - "collection_method": { - "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`.", - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "coupon": { - "description": "The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription.", - "maxLength": 5000, - "type": "string" - }, - "customer": { - "description": "The identifier of the customer to subscribe.", - "maxLength": 5000, + "currency": { + "description": "Three-letter [ISO code for currency](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. Must be a [supported currency](https://docs.stripe.com/currencies).", "type": "string" }, - "days_until_due": { - "description": "Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.", - "type": "integer" - }, - "default_payment_method": { - "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", "maxLength": 5000, "type": "string" }, - "default_source": { - "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", - "maxLength": 5000, + "destination": { + "description": "The ID of a connected Stripe account. See the Connect documentation for details.", "type": "string" }, - "default_tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription." - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -77075,197 +147486,30 @@ }, "type": "array" }, - "items": { - "description": "A list of up to 20 subscription items, each with an attached price.", - "items": { - "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product", "recurring"], - "title": "recurring_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "subscription_item_create_params", - "type": "object" - }, - "type": "array" - }, "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" }, - "off_session": { - "description": "Indicates if a customer is on or off-session while an invoice payment is attempted.", - "type": "boolean" + "source_transaction": { + "description": "You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-availability) for details.", + "type": "string" }, - "payment_behavior": { - "description": "Use `allow_incomplete` to create subscriptions with `status=incomplete` if the first invoice cannot be paid. Creating subscriptions with this status allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.\n\n`pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription.", - "enum": [ - "allow_incomplete", - "error_if_incomplete", - "pending_if_incomplete" - ], + "source_type": { + "description": "The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`.", + "enum": ["bank_account", "card", "fpx"], + "maxLength": 5000, "type": "string", "x-stripeBypassValidation": true }, - "pending_invoice_item_interval": { - "anyOf": [ - { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "pending_invoice_item_interval_params", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval." - }, - "promotion_code": { - "description": "The API ID of a promotion code to apply to this subscription. A promotion code applied to a subscription will only affect invoices created for that particular subscription.", - "maxLength": 5000, - "type": "string" - }, - "proration_behavior": { - "description": "Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) resulting from the `billing_cycle_anchor`. Valid values are `create_prorations` or `none`.\n\nPassing `create_prorations` will cause proration invoice items to be created when applicable. Prorations can be disabled by passing `none`. If no value is passed, the default is `create_prorations`.", - "enum": ["always_invoice", "create_prorations", "none"], + "transfer_group": { + "description": "A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.", "type": "string" - }, - "transfer_data": { - "description": "If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.", - "properties": { - "amount_percent": { - "type": "number" - }, - "destination": { - "type": "string" - } - }, - "required": ["destination"], - "title": "transfer_data_specs", - "type": "object" - }, - "trial_end": { - "anyOf": [ - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - }, - { - "format": "unix-time", - "type": "integer" - } - ], - "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`." - }, - "trial_from_plan": { - "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed.", - "type": "boolean" - }, - "trial_period_days": { - "description": "Integer representing the number of trial period days before the customer is charged for the first time. This will always overwrite any trials that might apply via a subscribed plan.", - "type": "integer" } }, - "required": ["customer"], + "required": ["currency", "destination"], "type": "object" } } @@ -77277,7 +147521,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription" + "$ref": "#/components/schemas/transfer" } } }, @@ -77296,14 +147540,139 @@ } } }, - "/v1/subscriptions/{subscription_exposed_id}": { - "delete": { - "description": "

Cancels a customer’s subscription immediately. The customer will not be charged again for the subscription.

\n\n

Note, however, that any pending invoice items that you’ve created will still be charged for at the end of the period, unless manually deleted. If you’ve set the subscription to cancel at the end of the period, any pending prorations will also be left in place and collected at the end of the period. But if the subscription is set to cancel immediately, pending prorations will be removed.

\n\n

By default, upon subscription cancellation, Stripe will stop automatic collection of all finalized invoices for the customer. This is intended to prevent unexpected payment attempts after the customer has canceled a subscription. However, you can resume automatic collection of the invoices manually after subscription cancellation to have us proceed. Or, you could check for unpaid invoices before allowing the customer to cancel the subscription at all.

", - "operationId": "DeleteSubscriptionsSubscriptionExposedId", + "/v1/transfers/{id}/reversals": { + "get": { + "description": "

You can see a list of the reversals belonging to a specific transfer. Note that the 10 most recent reversals are always available by default on the transfer object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional reversals.

", + "operationId": "GetTransfersIdReversals", + "parameters": [ + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/transfer_reversal" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TransferReversalList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

When you create a new reversal, you must specify a transfer to create it on.

\n\n

When reversing transfers, you can optionally reverse part of the transfer. You can do so as many times as you wish until the entire transfer has been reversed.

\n\n

Once entirely reversed, a transfer can’t be reversed again. This method will return an error when called on an already-reversed transfer, or when trying to reverse more money than is left on a transfer.

", + "operationId": "PostTransfersIdReversals", "parameters": [ { "in": "path", - "name": "subscription_exposed_id", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -77319,10 +147688,24 @@ "expand": { "explode": true, "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { + "amount": { + "description": "A positive integer in cents (or local equivalent) representing how much of this transfer to reverse. Can only reverse up to the unreversed amount remaining of the transfer. Partial transfer reversals are only allowed for transfers to Stripe Accounts. Defaults to the entire transfer amount.", + "type": "integer" + }, + "description": { + "description": "An arbitrary string which you can attach to a reversal object. This will be unset if you POST an empty value.", + "maxLength": 5000, + "type": "string" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -77331,12 +147714,23 @@ }, "type": "array" }, - "invoice_now": { - "description": "Will generate a final invoice that invoices for any un-invoiced metered usage and new/pending proration invoice items.", - "type": "boolean" + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." }, - "prorate": { - "description": "Will generate a proration invoice item that credits remaining unused time until the subscription period end.", + "refund_application_fee": { + "description": "Boolean indicating whether the application fee should be refunded when reversing this transfer. If a full transfer reversal is given, the full application fee will be refunded. Otherwise, the application fee will be refunded with an amount proportional to the amount of the transfer reversed.", "type": "boolean" } }, @@ -77351,7 +147745,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription" + "$ref": "#/components/schemas/transfer_reversal" } } }, @@ -77368,10 +147762,12 @@ "description": "Error response." } } - }, + } + }, + "/v1/transfers/{transfer}": { "get": { - "description": "

Retrieves the subscription with the given ID.

", - "operationId": "GetSubscriptionsSubscriptionExposedId", + "description": "

Retrieves the details of an existing transfer. Supply the unique transfer ID from either a transfer creation request or the transfer list, and Stripe will return the corresponding transfer information.

", + "operationId": "GetTransfersTransfer", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -77390,7 +147786,7 @@ }, { "in": "path", - "name": "subscription_exposed_id", + "name": "transfer", "required": true, "schema": { "maxLength": 5000, @@ -77404,6 +147800,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -77416,7 +147813,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription" + "$ref": "#/components/schemas/transfer" } } }, @@ -77435,12 +147832,12 @@ } }, "post": { - "description": "

Updates an existing subscription on a customer to match the specified parameters. When changing plans or quantities, we will optionally prorate the price we charge next month to make up for any price changes. To preview how the proration will be calculated, use the upcoming invoice endpoint.

", - "operationId": "PostSubscriptionsSubscriptionExposedId", + "description": "

Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

This request accepts only metadata as an argument.

", + "operationId": "PostTransfersTransfer", "parameters": [ { "in": "path", - "name": "subscription_exposed_id", + "name": "transfer", "required": true, "schema": { "maxLength": 5000, @@ -77453,195 +147850,23 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "add_invoice_items": { - "explode": true, - "style": "deepObject" - }, - "billing_thresholds": { - "explode": true, - "style": "deepObject" - }, - "cancel_at": { - "explode": true, - "style": "deepObject" - }, - "default_tax_rates": { - "explode": true, - "style": "deepObject" - }, "expand": { "explode": true, "style": "deepObject" }, - "items": { - "explode": true, - "style": "deepObject" - }, "metadata": { "explode": true, "style": "deepObject" - }, - "pause_collection": { - "explode": true, - "style": "deepObject" - }, - "pending_invoice_item_interval": { - "explode": true, - "style": "deepObject" - }, - "transfer_data": { - "explode": true, - "style": "deepObject" - }, - "trial_end": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "add_invoice_items": { - "description": "A list of prices and quantities that will generate invoice items appended to the first invoice for this subscription. You may pass up to 10 items.", - "items": { - "properties": { - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product"], - "title": "one_time_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "add_invoice_item_entry", - "type": "object" - }, - "type": "array" - }, - "application_fee_percent": { - "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice subtotal that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).", - "type": "number" - }, - "billing_cycle_anchor": { - "description": "Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", - "enum": ["now", "unchanged"], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "amount_gte": { - "type": "integer" - }, - "reset_billing_cycle_anchor": { - "type": "boolean" - } - }, - "title": "billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." - }, - "cancel_at": { - "anyOf": [ - { - "format": "unix-time", - "type": "integer" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period." - }, - "cancel_at_period_end": { - "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", - "type": "boolean" - }, - "collection_method": { - "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`.", - "enum": ["charge_automatically", "send_invoice"], - "type": "string" - }, - "coupon": { - "description": "The code of the coupon to apply to this subscription. A coupon applied to a subscription will only affect invoices created for that particular subscription.", - "maxLength": 5000, - "type": "string" - }, - "days_until_due": { - "description": "Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.", - "type": "integer" - }, - "default_payment_method": { - "description": "ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", - "maxLength": 5000, - "type": "string" - }, - "default_source": { - "description": "ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).", + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", "maxLength": 5000, "type": "string" }, - "default_tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates." - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -77650,115 +147875,6 @@ }, "type": "array" }, - "items": { - "description": "A list of up to 20 subscription items, each with an attached price.", - "items": { - "properties": { - "billing_thresholds": { - "anyOf": [ - { - "properties": { - "usage_gte": { - "type": "integer" - } - }, - "required": ["usage_gte"], - "title": "item_billing_thresholds_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "clear_usage": { - "type": "boolean" - }, - "deleted": { - "type": "boolean" - }, - "id": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "price": { - "maxLength": 5000, - "type": "string" - }, - "price_data": { - "properties": { - "currency": { - "type": "string" - }, - "product": { - "maxLength": 5000, - "type": "string" - }, - "recurring": { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "recurring_adhoc", - "type": "object" - }, - "unit_amount": { - "type": "integer" - }, - "unit_amount_decimal": { - "format": "decimal", - "type": "string" - } - }, - "required": ["currency", "product", "recurring"], - "title": "recurring_price_data", - "type": "object" - }, - "quantity": { - "type": "integer" - }, - "tax_rates": { - "anyOf": [ - { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - { - "enum": [""], - "type": "string" - } - ] - } - }, - "title": "subscription_item_update_params", - "type": "object" - }, - "type": "array" - }, "metadata": { "anyOf": [ { @@ -77773,126 +147889,6 @@ } ], "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "off_session": { - "description": "Indicates if a customer is on or off-session while an invoice payment is attempted.", - "type": "boolean" - }, - "pause_collection": { - "anyOf": [ - { - "properties": { - "behavior": { - "enum": [ - "keep_as_draft", - "mark_uncollectible", - "void" - ], - "type": "string" - }, - "resumes_at": { - "format": "unix-time", - "type": "integer" - } - }, - "required": ["behavior"], - "title": "pause_collection_param", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "If specified, payment collection for this subscription will be paused." - }, - "payment_behavior": { - "description": "Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.\n\nUse `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).\n\nUse `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.", - "enum": [ - "allow_incomplete", - "error_if_incomplete", - "pending_if_incomplete" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "pending_invoice_item_interval": { - "anyOf": [ - { - "properties": { - "interval": { - "enum": ["day", "month", "week", "year"], - "type": "string" - }, - "interval_count": { - "type": "integer" - } - }, - "required": ["interval"], - "title": "pending_invoice_item_interval_params", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval." - }, - "promotion_code": { - "description": "The promotion code to apply to this subscription. A promotion code applied to a subscription will only affect invoices created for that particular subscription.", - "maxLength": 5000, - "type": "string" - }, - "proration_behavior": { - "description": "Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. Valid values are `create_prorations`, `none`, or `always_invoice`.\n\nPassing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.\n\nProrations can be disabled by passing `none`.", - "enum": ["always_invoice", "create_prorations", "none"], - "type": "string" - }, - "proration_date": { - "description": "If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same proration that was previewed with [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint. It can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.", - "format": "unix-time", - "type": "integer" - }, - "transfer_data": { - "anyOf": [ - { - "properties": { - "amount_percent": { - "type": "number" - }, - "destination": { - "type": "string" - } - }, - "required": ["destination"], - "title": "transfer_data_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value." - }, - "trial_end": { - "anyOf": [ - { - "enum": ["now"], - "maxLength": 5000, - "type": "string" - }, - { - "format": "unix-time", - "type": "integer" - } - ], - "description": "Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`." - }, - "trial_from_plan": { - "description": "Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed.", - "type": "boolean" } }, "type": "object" @@ -77906,7 +147902,85 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/subscription" + "$ref": "#/components/schemas/transfer" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/transfers/{transfer}/reversals/{id}": { + "get": { + "description": "

By default, you can see the 10 most recent reversals stored directly on the transfer object, but you can also retrieve details about a specific reversal stored on the transfer.

", + "operationId": "GetTransfersTransferReversalsId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "transfer", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/transfer_reversal" } } }, @@ -77923,16 +147997,24 @@ "description": "Error response." } } - } - }, - "/v1/subscriptions/{subscription_exposed_id}/discount": { - "delete": { - "description": "

Removes the currently applied discount on a subscription.

", - "operationId": "DeleteSubscriptionsSubscriptionExposedIdDiscount", + }, + "post": { + "description": "

Updates the specified reversal by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

This request only accepts metadata and description as arguments.

", + "operationId": "PostTransfersTransferReversalsId", "parameters": [ { "in": "path", - "name": "subscription_exposed_id", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "in": "path", + "name": "transfer", "required": true, "schema": { "maxLength": 5000, @@ -77944,9 +148026,43 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": {}, + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, "schema": { - "properties": {}, + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + } + }, "type": "object" } } @@ -77958,7 +148074,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_discount" + "$ref": "#/components/schemas/transfer_reversal" } } }, @@ -77977,54 +148093,11 @@ } } }, - "/v1/tax_rates": { + "/v1/treasury/credit_reversals": { "get": { - "description": "

Returns a list of your tax rates. Tax rates are returned sorted by creation date, with the most recently created tax rates appearing first.

", - "operationId": "GetTaxRates", + "description": "

Returns a list of CreditReversals.

", + "operationId": "GetTreasuryCreditReversals", "parameters": [ - { - "description": "Optional flag to filter by tax rates that are either active or inactive (archived).", - "in": "query", - "name": "active", - "required": false, - "schema": { - "type": "boolean" - }, - "style": "form" - }, - { - "description": "Optional range for filtering created date.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -78052,12 +148125,12 @@ "style": "deepObject" }, { - "description": "Optional flag to filter by tax rates that are inclusive (or those that are not inclusive).", + "description": "Returns objects associated with this FinancialAccount.", "in": "query", - "name": "inclusive", - "required": false, + "name": "financial_account", + "required": true, "schema": { - "type": "boolean" + "type": "string" }, "style": "form" }, @@ -78071,6 +148144,17 @@ }, "style": "form" }, + { + "description": "Only return CreditReversals for the ReceivedCredit ID.", + "in": "query", + "name": "received_credit", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -78081,6 +148165,17 @@ "type": "string" }, "style": "form" + }, + { + "description": "Only return CreditReversals for a given status.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["canceled", "posted", "processing"], + "type": "string" + }, + "style": "form" } ], "requestBody": { @@ -78088,6 +148183,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -78103,8 +148199,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/tax_rate" + "$ref": "#/components/schemas/treasury.credit_reversal" }, "type": "array" }, @@ -78120,11 +148217,11 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/tax_rates", "type": "string" } }, "required": ["data", "has_more", "object", "url"], + "title": "TreasuryReceivedCreditsResourceCreditReversalList", "type": "object", "x-expandableFields": ["data"] } @@ -78145,8 +148242,8 @@ } }, "post": { - "description": "

Creates a new tax rate.

", - "operationId": "PostTaxRates", + "description": "

Reverses a ReceivedCredit and creates a CreditReversal object.

", + "operationId": "PostTreasuryCreditReversals", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -78161,26 +148258,8 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.", - "type": "boolean" - }, - "country": { - "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", - "maxLength": 5000, - "type": "string" - }, - "description": { - "description": "An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.", - "maxLength": 5000, - "type": "string" - }, - "display_name": { - "description": "The display name of the tax rate, which will be shown to users.", - "maxLength": 50, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -78189,15 +148268,6 @@ }, "type": "array" }, - "inclusive": { - "description": "This specifies if the tax rate is inclusive or exclusive.", - "type": "boolean" - }, - "jurisdiction": { - "description": "The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.", - "maxLength": 50, - "type": "string" - }, "metadata": { "additionalProperties": { "type": "string" @@ -78205,17 +148275,13 @@ "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" }, - "percentage": { - "description": "This represents the tax rate percent out of 100.", - "type": "number" - }, - "state": { - "description": "[ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, \"NY\" for New York, United States.", - "maxLength": 2, + "received_credit": { + "description": "The ReceivedCredit to reverse.", + "maxLength": 5000, "type": "string" } }, - "required": ["display_name", "inclusive", "percentage"], + "required": ["received_credit"], "type": "object" } } @@ -78227,7 +148293,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/tax_rate" + "$ref": "#/components/schemas/treasury.credit_reversal" } } }, @@ -78246,11 +148312,21 @@ } } }, - "/v1/tax_rates/{tax_rate}": { + "/v1/treasury/credit_reversals/{credit_reversal}": { "get": { - "description": "

Retrieves a tax rate with the given ID

", - "operationId": "GetTaxRatesTaxRate", + "description": "

Retrieves the details of an existing CreditReversal by passing the unique CreditReversal ID from either the CreditReversal creation request or CreditReversal list

", + "operationId": "GetTreasuryCreditReversalsCreditReversal", "parameters": [ + { + "in": "path", + "name": "credit_reversal", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -78265,16 +148341,6 @@ "type": "array" }, "style": "deepObject" - }, - { - "in": "path", - "name": "tax_rate", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" } ], "requestBody": { @@ -78282,6 +148348,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -78294,7 +148361,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/tax_rate" + "$ref": "#/components/schemas/treasury.credit_reversal" } } }, @@ -78311,22 +148378,170 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates an existing tax rate.

", - "operationId": "PostTaxRatesTaxRate", + } + }, + "/v1/treasury/debit_reversals": { + "get": { + "description": "

Returns a list of DebitReversals.

", + "operationId": "GetTreasuryDebitReversals", "parameters": [ { - "in": "path", - "name": "tax_rate", + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "Returns objects associated with this FinancialAccount.", + "in": "query", + "name": "financial_account", "required": true, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "Only return DebitReversals for the ReceivedDebit ID.", + "in": "query", + "name": "received_debit", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" + }, + { + "description": "Only return DebitReversals for a given resolution.", + "in": "query", + "name": "resolution", + "required": false, + "schema": { + "enum": ["lost", "won"], + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return DebitReversals for a given status.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["canceled", "completed", "processing"], + "type": "string" + }, + "style": "form" } ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/treasury.debit_reversal" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TreasuryReceivedDebitsResourceDebitReversalList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Reverses a ReceivedDebit and creates a DebitReversal object.

", + "operationId": "PostTreasuryDebitReversals", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -78341,26 +148556,8 @@ } }, "schema": { + "additionalProperties": false, "properties": { - "active": { - "description": "Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.", - "type": "boolean" - }, - "country": { - "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", - "maxLength": 5000, - "type": "string" - }, - "description": { - "description": "An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.", - "maxLength": 5000, - "type": "string" - }, - "display_name": { - "description": "The display name of the tax rate, which will be shown to users.", - "maxLength": 50, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -78369,44 +148566,32 @@ }, "type": "array" }, - "jurisdiction": { - "description": "The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.", - "maxLength": 50, - "type": "string" - }, "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" }, - "state": { - "description": "[ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, \"NY\" for New York, United States.", - "maxLength": 2, + "received_debit": { + "description": "The ReceivedDebit to reverse.", + "maxLength": 5000, "type": "string" } }, + "required": ["received_debit"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/tax_rate" + "$ref": "#/components/schemas/treasury.debit_reversal" } } }, @@ -78425,35 +148610,44 @@ } } }, - "/v1/terminal/connection_tokens": { - "post": { - "description": "

To connect to a reader the Stripe Terminal SDK needs to retrieve a short-lived connection token from Stripe, proxied through your server. On your backend, add an endpoint that creates and returns a connection token.

", - "operationId": "PostTerminalConnectionTokens", + "/v1/treasury/debit_reversals/{debit_reversal}": { + "get": { + "description": "

Retrieves a DebitReversal object.

", + "operationId": "GetTreasuryDebitReversalsDebitReversal", + "parameters": [ + { + "in": "path", + "name": "debit_reversal", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "location": { - "description": "The id of the location that this connection token is scoped to. If specified the connection token will only be usable with readers assigned to that location, otherwise the connection token will be usable with all readers.", - "maxLength": 5000, - "type": "string" - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -78465,32 +148659,65 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/terminal.connection_token" + "$ref": "#/components/schemas/treasury.debit_reversal" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/treasury/financial_accounts": { + "get": { + "description": "

Returns a list of FinancialAccounts.

", + "operationId": "GetTreasuryFinancialAccounts", + "parameters": [ + { + "description": "Only return FinancialAccounts that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" } - } + ] }, - "description": "Successful response." + "style": "deepObject" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/terminal/locations": { - "get": { - "description": "

Returns a list of Location objects.

", - "operationId": "GetTerminalLocations", - "parameters": [ { - "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "description": "An object ID cursor for use in pagination.", "in": "query", "name": "ending_before", "required": false, @@ -78516,7 +148743,7 @@ "style": "deepObject" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "description": "A limit ranging from 1 to 100 (defaults to 10).", "in": "query", "name": "limit", "required": false, @@ -78526,7 +148753,7 @@ "style": "form" }, { - "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "description": "An object ID cursor for use in pagination.", "in": "query", "name": "starting_after", "required": false, @@ -78542,6 +148769,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -78558,7 +148786,7 @@ "properties": { "data": { "items": { - "$ref": "#/components/schemas/terminal.location" + "$ref": "#/components/schemas/treasury.financial_account" }, "type": "array" }, @@ -78574,12 +148802,12 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/terminal/locations", + "pattern": "^/v1/treasury/financial_accounts", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "TerminalLocationLocationList", + "title": "TreasuryFinancialAccountsResourceFinancialAccountList", "type": "object", "x-expandableFields": ["data"] } @@ -78600,89 +148828,197 @@ } }, "post": { - "description": "

Creates a new Location object.

", - "operationId": "PostTerminalLocations", + "description": "

Creates a new FinancialAccount. For now, each connected account can only have one FinancialAccount.

", + "operationId": "PostTreasuryFinancialAccounts", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { - "address": { + "expand": { "explode": true, "style": "deepObject" }, - "expand": { + "features": { "explode": true, "style": "deepObject" }, "metadata": { "explode": true, "style": "deepObject" + }, + "platform_restrictions": { + "explode": true, + "style": "deepObject" + }, + "supported_currencies": { + "explode": true, + "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "address": { - "description": "The full address of the location.", + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "features": { + "description": "Encodes whether a FinancialAccount has access to a particular feature. Stripe or the platform can control features via the requested field.", "properties": { - "city": { - "maxLength": 5000, - "type": "string" + "card_issuing": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" }, - "country": { - "maxLength": 5000, - "type": "string" + "deposit_insurance": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" }, - "line1": { - "maxLength": 5000, - "type": "string" + "financial_addresses": { + "properties": { + "aba": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "aba_access", + "type": "object" + } + }, + "title": "financial_addresses", + "type": "object" }, - "line2": { - "maxLength": 5000, - "type": "string" + "inbound_transfers": { + "properties": { + "ach": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access_with_ach_details", + "type": "object" + } + }, + "title": "inbound_transfers", + "type": "object" }, - "postal_code": { - "maxLength": 5000, + "intra_stripe_flows": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + }, + "outbound_payments": { + "properties": { + "ach": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access_with_ach_details", + "type": "object" + }, + "us_domestic_wire": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + } + }, + "title": "outbound_payments", + "type": "object" + }, + "outbound_transfers": { + "properties": { + "ach": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access_with_ach_details", + "type": "object" + }, + "us_domestic_wire": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + } + }, + "title": "outbound_transfers", + "type": "object" + } + }, + "title": "feature_access", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "platform_restrictions": { + "description": "The set of functionalities that the platform can restrict on the FinancialAccount.", + "properties": { + "inbound_flows": { + "enum": ["restricted", "unrestricted"], "type": "string" }, - "state": { - "maxLength": 5000, + "outbound_flows": { + "enum": ["restricted", "unrestricted"], "type": "string" } }, - "required": ["country"], - "title": "create_location_address_param", + "title": "platform_restrictions", "type": "object" }, - "display_name": { - "description": "A name for the location.", - "maxLength": 1000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", + "supported_currencies": { + "description": "The currencies the FinancialAccount can hold a balance in.", "items": { "maxLength": 5000, "type": "string" }, "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." } }, - "required": ["address", "display_name"], + "required": ["supported_currencies"], "type": "object" } } @@ -78694,7 +149030,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/terminal.location" + "$ref": "#/components/schemas/treasury.financial_account" } } }, @@ -78713,14 +149049,29 @@ } } }, - "/v1/terminal/locations/{location}": { - "delete": { - "description": "

Deletes a Location object.

", - "operationId": "DeleteTerminalLocationsLocation", + "/v1/treasury/financial_accounts/{financial_account}": { + "get": { + "description": "

Retrieves the details of a FinancialAccount.

", + "operationId": "GetTreasuryFinancialAccountsFinancialAccount", "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, { "in": "path", - "name": "location", + "name": "financial_account", "required": true, "schema": { "maxLength": 5000, @@ -78734,6 +149085,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -78746,7 +149098,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/deleted_terminal.location" + "$ref": "#/components/schemas/treasury.financial_account" } } }, @@ -78764,9 +149116,231 @@ } } }, + "post": { + "description": "

Updates the details of a FinancialAccount.

", + "operationId": "PostTreasuryFinancialAccountsFinancialAccount", + "parameters": [ + { + "in": "path", + "name": "financial_account", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "features": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "platform_restrictions": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "features": { + "description": "Encodes whether a FinancialAccount has access to a particular feature, with a status enum and associated `status_details`. Stripe or the platform may control features via the requested field.", + "properties": { + "card_issuing": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + }, + "deposit_insurance": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + }, + "financial_addresses": { + "properties": { + "aba": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "aba_access", + "type": "object" + } + }, + "title": "financial_addresses", + "type": "object" + }, + "inbound_transfers": { + "properties": { + "ach": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access_with_ach_details", + "type": "object" + } + }, + "title": "inbound_transfers", + "type": "object" + }, + "intra_stripe_flows": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + }, + "outbound_payments": { + "properties": { + "ach": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access_with_ach_details", + "type": "object" + }, + "us_domestic_wire": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + } + }, + "title": "outbound_payments", + "type": "object" + }, + "outbound_transfers": { + "properties": { + "ach": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access_with_ach_details", + "type": "object" + }, + "us_domestic_wire": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + } + }, + "title": "outbound_transfers", + "type": "object" + } + }, + "title": "feature_access", + "type": "object" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "platform_restrictions": { + "description": "The set of functionalities that the platform can restrict on the FinancialAccount.", + "properties": { + "inbound_flows": { + "enum": ["restricted", "unrestricted"], + "type": "string" + }, + "outbound_flows": { + "enum": ["restricted", "unrestricted"], + "type": "string" + } + }, + "title": "platform_restrictions", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/treasury.financial_account" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/treasury/financial_accounts/{financial_account}/features": { "get": { - "description": "

Retrieves a Location object.

", - "operationId": "GetTerminalLocationsLocation", + "description": "

Retrieves Features information associated with the FinancialAccount.

", + "operationId": "GetTreasuryFinancialAccountsFinancialAccountFeatures", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -78785,7 +149359,7 @@ }, { "in": "path", - "name": "location", + "name": "financial_account", "required": true, "schema": { "maxLength": 5000, @@ -78799,6 +149373,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -78811,7 +149386,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/terminal.location" + "$ref": "#/components/schemas/treasury.financial_account_features" } } }, @@ -78830,12 +149405,12 @@ } }, "post": { - "description": "

Updates a Location object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostTerminalLocationsLocation", + "description": "

Updates the Features associated with a FinancialAccount.

", + "operationId": "PostTreasuryFinancialAccountsFinancialAccountFeatures", "parameters": [ { "in": "path", - "name": "location", + "name": "financial_account", "required": true, "schema": { "maxLength": 5000, @@ -78848,7 +149423,11 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { - "address": { + "card_issuing": { + "explode": true, + "style": "deepObject" + }, + "deposit_insurance": { "explode": true, "style": "deepObject" }, @@ -78856,48 +149435,51 @@ "explode": true, "style": "deepObject" }, - "metadata": { + "financial_addresses": { + "explode": true, + "style": "deepObject" + }, + "inbound_transfers": { + "explode": true, + "style": "deepObject" + }, + "intra_stripe_flows": { + "explode": true, + "style": "deepObject" + }, + "outbound_payments": { + "explode": true, + "style": "deepObject" + }, + "outbound_transfers": { "explode": true, "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { - "address": { - "description": "The full address of the location.", + "card_issuing": { + "description": "Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.", "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" + "requested": { + "type": "boolean" } }, - "title": "optional_fields_address", + "required": ["requested"], + "title": "access", "type": "object" }, - "display_name": { - "description": "A name for the location.", - "maxLength": 1000, - "type": "string" + "deposit_insurance": { + "description": "Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.", + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" }, "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -78907,20 +149489,104 @@ }, "type": "array" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" + "financial_addresses": { + "description": "Contains Features that add FinancialAddresses to the FinancialAccount.", + "properties": { + "aba": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "aba_access", + "type": "object" + } + }, + "title": "financial_addresses", + "type": "object" + }, + "inbound_transfers": { + "description": "Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.", + "properties": { + "ach": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access_with_ach_details", + "type": "object" + } + }, + "title": "inbound_transfers", + "type": "object" + }, + "intra_stripe_flows": { + "description": "Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).", + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + }, + "outbound_payments": { + "description": "Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.", + "properties": { + "ach": { + "properties": { + "requested": { + "type": "boolean" + } }, + "required": ["requested"], + "title": "access_with_ach_details", "type": "object" }, - { - "enum": [""], - "type": "string" + "us_domestic_wire": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "title": "outbound_payments", + "type": "object" + }, + "outbound_transfers": { + "description": "Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.", + "properties": { + "ach": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access_with_ach_details", + "type": "object" + }, + "us_domestic_wire": { + "properties": { + "requested": { + "type": "boolean" + } + }, + "required": ["requested"], + "title": "access", + "type": "object" + } + }, + "title": "outbound_transfers", + "type": "object" } }, "type": "object" @@ -78934,7 +149600,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/terminal.location" + "$ref": "#/components/schemas/treasury.financial_account_features" } } }, @@ -78946,30 +149612,18 @@ "schema": { "$ref": "#/components/schemas/error" } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/terminal/readers": { - "get": { - "description": "

Returns a list of Reader objects.

", - "operationId": "GetTerminalReaders", - "parameters": [ - { - "description": "Filters readers by device type", - "in": "query", - "name": "device_type", - "required": false, - "schema": { - "enum": ["bbpos_chipper2x", "verifone_P400"], - "type": "string", - "x-stripeBypassValidation": true + } }, - "style": "form" - }, + "description": "Error response." + } + } + } + }, + "/v1/treasury/inbound_transfers": { + "get": { + "description": "

Returns a list of InboundTransfers sent from the specified FinancialAccount.

", + "operationId": "GetTreasuryInboundTransfers", + "parameters": [ { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -78997,23 +149651,22 @@ "style": "deepObject" }, { - "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "description": "Returns objects associated with this FinancialAccount.", "in": "query", - "name": "limit", - "required": false, + "name": "financial_account", + "required": true, "schema": { - "type": "integer" + "type": "string" }, "style": "form" }, { - "description": "A location ID to filter the response list to only readers at the specific location", + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", - "name": "location", + "name": "limit", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "type": "integer" }, "style": "form" }, @@ -79029,12 +149682,12 @@ "style": "form" }, { - "description": "A status filter to filter readers to only offline or online readers", + "description": "Only return InboundTransfers that have the given status: `processing`, `succeeded`, `failed` or `canceled`.", "in": "query", "name": "status", "required": false, "schema": { - "enum": ["offline", "online"], + "enum": ["canceled", "failed", "processing", "succeeded"], "type": "string" }, "style": "form" @@ -79045,6 +149698,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -79060,9 +149714,9 @@ "description": "", "properties": { "data": { - "description": "A list of readers", + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/terminal.reader" + "$ref": "#/components/schemas/treasury.inbound_transfer" }, "type": "array" }, @@ -79082,7 +149736,7 @@ } }, "required": ["data", "has_more", "object", "url"], - "title": "TerminalReaderRetrieveReader", + "title": "TreasuryInboundTransfersResourceInboundTransferList", "type": "object", "x-expandableFields": ["data"] } @@ -79103,8 +149757,8 @@ } }, "post": { - "description": "

Creates a new Reader object.

", - "operationId": "PostTerminalReaders", + "description": "

Creates an InboundTransfer.

", + "operationId": "PostTreasuryInboundTransfers", "requestBody": { "content": { "application/x-www-form-urlencoded": { @@ -79119,7 +149773,21 @@ } }, "schema": { + "additionalProperties": false, "properties": { + "amount": { + "description": "Amount (in cents) to be transferred.", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "type": "string" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -79128,38 +149796,34 @@ }, "type": "array" }, - "label": { - "description": "Custom label given to the reader for easier identification. If no label is specified, the registration code will be used.", - "maxLength": 5000, - "type": "string" - }, - "location": { - "description": "The location to assign the reader to. If no location is specified, the reader will be assigned to the account's default location.", - "maxLength": 5000, + "financial_account": { + "description": "The FinancialAccount to send funds to.", "type": "string" }, "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" }, - "registration_code": { - "description": "A code generated by the reader used for registering to an account.", + "origin_payment_method": { + "description": "The origin payment method to be debited for the InboundTransfer.", "maxLength": 5000, "type": "string" + }, + "statement_descriptor": { + "description": "The complete description that appears on your customers' statements. Maximum 10 characters.", + "maxLength": 10, + "type": "string" } }, - "required": ["registration_code"], + "required": [ + "amount", + "currency", + "financial_account", + "origin_payment_method" + ], "type": "object" } } @@ -79171,7 +149835,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/terminal.reader" + "$ref": "#/components/schemas/treasury.inbound_transfer" } } }, @@ -79190,60 +149854,10 @@ } } }, - "/v1/terminal/readers/{reader}": { - "delete": { - "description": "

Deletes a Reader object.

", - "operationId": "DeleteTerminalReadersReader", - "parameters": [ - { - "in": "path", - "name": "reader", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/deleted_terminal.reader" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, + "/v1/treasury/inbound_transfers/{id}": { "get": { - "description": "

Retrieves a Reader object.

", - "operationId": "GetTerminalReadersReader", + "description": "

Retrieves the details of an existing InboundTransfer.

", + "operationId": "GetTreasuryInboundTransfersId", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -79262,7 +149876,7 @@ }, { "in": "path", - "name": "reader", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -79276,6 +149890,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -79288,7 +149903,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/terminal.reader" + "$ref": "#/components/schemas/treasury.inbound_transfer" } } }, @@ -79305,14 +149920,16 @@ "description": "Error response." } } - }, + } + }, + "/v1/treasury/inbound_transfers/{inbound_transfer}/cancel": { "post": { - "description": "

Updates a Reader object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

", - "operationId": "PostTerminalReadersReader", + "description": "

Cancels an InboundTransfer.

", + "operationId": "PostTreasuryInboundTransfersInboundTransferCancel", "parameters": [ { "in": "path", - "name": "reader", + "name": "inbound_transfer", "required": true, "schema": { "maxLength": 5000, @@ -79328,13 +149945,10 @@ "expand": { "explode": true, "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -79343,26 +149957,6 @@ "type": "string" }, "type": "array" - }, - "label": { - "description": "The new label of the reader.", - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." } }, "type": "object" @@ -79376,7 +149970,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/terminal.reader" + "$ref": "#/components/schemas/treasury.inbound_transfer" } } }, @@ -79395,362 +149989,307 @@ } } }, - "/v1/tokens": { - "post": { - "description": "

Creates a single-use token that represents a bank account’s details.\nThis token can be used with any API method in place of a bank account dictionary. This token can be used only once, by attaching it to a Custom account.

", - "operationId": "PostTokens", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "account": { - "explode": true, - "style": "deepObject" - }, - "bank_account": { - "explode": true, - "style": "deepObject" - }, - "card": { - "explode": true, - "style": "deepObject" - }, - "cvc_update": { - "explode": true, - "style": "deepObject" - }, - "expand": { - "explode": true, - "style": "deepObject" - }, - "person": { - "explode": true, - "style": "deepObject" + "/v1/treasury/outbound_payments": { + "get": { + "description": "

Returns a list of OutboundPayments sent from the specified FinancialAccount.

", + "operationId": "GetTreasuryOutboundPayments", + "parameters": [ + { + "description": "Only return OutboundPayments that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" }, - "pii": { - "explode": true, - "style": "deepObject" + { + "type": "integer" } + ] + }, + "style": "deepObject" + }, + { + "description": "Only return OutboundPayments sent to this customer.", + "in": "query", + "name": "customer", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "Returns objects associated with this FinancialAccount.", + "in": "query", + "name": "financial_account", + "required": true, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, + { + "description": "Only return OutboundPayments that have the given status: `processing`, `failed`, `posted`, `returned`, or `canceled`.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": [ + "canceled", + "failed", + "posted", + "processing", + "returned" + ], + "type": "string" + }, + "style": "form" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, "schema": { - "properties": { - "account": { - "description": "Information for the account this token will represent.", - "properties": { - "business_type": { - "enum": [ - "company", - "government_entity", - "individual", - "non_profit" - ], - "type": "string", - "x-stripeBypassValidation": true + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/treasury.outbound_payment" }, - "company": { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kana_specs", - "type": "object" - }, - "address_kanji": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "japan_address_kanji_specs", - "type": "object" - }, - "directors_provided": { - "type": "boolean" - }, - "executives_provided": { - "type": "boolean" - }, - "name": { - "maxLength": 100, - "type": "string" - }, - "name_kana": { - "maxLength": 100, - "type": "string" - }, - "name_kanji": { - "maxLength": 100, - "type": "string" - }, - "owners_provided": { - "type": "boolean" - }, - "phone": { - "maxLength": 5000, - "type": "string" - }, - "registration_number": { - "maxLength": 5000, - "type": "string" - }, - "structure": { - "enum": [ - "", - "government_instrumentality", - "governmental_unit", - "incorporated_non_profit", - "limited_liability_partnership", - "multi_member_llc", - "private_company", - "private_corporation", - "private_partnership", - "public_company", - "public_corporation", - "public_partnership", - "sole_proprietorship", - "tax_exempt_government_instrumentality", - "unincorporated_association", - "unincorporated_non_profit" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "tax_id": { - "maxLength": 5000, - "type": "string" - }, - "tax_id_registrar": { - "maxLength": 5000, - "type": "string" - }, - "vat_id": { - "maxLength": 5000, - "type": "string" - }, - "verification": { - "properties": { - "document": { + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/treasury/outbound_payments", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TreasuryOutboundPaymentsResourceOutboundPaymentList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Creates an OutboundPayment.

", + "operationId": "PostTreasuryOutboundPayments", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "destination_payment_method_data": { + "explode": true, + "style": "deepObject" + }, + "destination_payment_method_options": { + "explode": true, + "style": "deepObject" + }, + "end_user_details": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "amount": { + "description": "Amount (in cents) to be transferred.", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "customer": { + "description": "ID of the customer to whom the OutboundPayment is sent. Must match the Customer attached to the `destination_payment_method` passed in.", + "maxLength": 5000, + "type": "string" + }, + "description": { + "description": "An arbitrary string attached to the object. Often useful for displaying to users.", + "maxLength": 5000, + "type": "string" + }, + "destination_payment_method": { + "description": "The PaymentMethod to use as the payment instrument for the OutboundPayment. Exclusive with `destination_payment_method_data`.", + "maxLength": 5000, + "type": "string" + }, + "destination_payment_method_data": { + "description": "Hash used to generate the PaymentMethod to be used for this OutboundPayment. Exclusive with `destination_payment_method`.", + "properties": { + "billing_details": { + "properties": { + "address": { + "anyOf": [ + { "properties": { - "back": { - "maxLength": 500, + "city": { + "maxLength": 5000, "type": "string" }, - "front": { - "maxLength": 500, + "country": { + "maxLength": 5000, + "type": "string" + }, + "line1": { + "maxLength": 5000, + "type": "string" + }, + "line2": { + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "maxLength": 5000, + "type": "string" + }, + "state": { + "maxLength": 5000, "type": "string" } }, - "title": "verification_document_specs", + "title": "billing_details_address", "type": "object" - } - }, - "title": "verification_specs", - "type": "object" - } - }, - "title": "company_specs", - "type": "object" - }, - "individual": { - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" - }, - "address_kana": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" }, - "town": { - "maxLength": 5000, + { + "enum": [""], "type": "string" } - }, - "title": "japan_address_kana_specs", - "type": "object" + ] }, - "address_kanji": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, + "email": { + "anyOf": [ + { "type": "string" }, - "town": { - "maxLength": 5000, + { + "enum": [""], "type": "string" } - }, - "title": "japan_address_kanji_specs", - "type": "object" + ] }, - "dob": { + "name": { "anyOf": [ { - "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" - }, - "year": { - "type": "integer" - } - }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" + "maxLength": 5000, + "type": "string" }, { "enum": [""], @@ -79758,405 +150297,79 @@ } ] }, - "email": { - "type": "string" - }, - "first_name": { - "maxLength": 100, - "type": "string" - }, - "first_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "gender": { - "type": "string" - }, - "id_number": { - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "maxLength": 100, - "type": "string" - }, - "last_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "last_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "maiden_name": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { + "phone": { "anyOf": [ { - "additionalProperties": { - "type": "string" - }, - "type": "object" + "maxLength": 5000, + "type": "string" }, { "enum": [""], "type": "string" } ] - }, - "phone": { - "type": "string" - }, - "political_exposure": { - "enum": ["existing", "none"], - "type": "string" - }, - "ssn_last_4": { - "maxLength": 5000, - "type": "string" - }, - "verification": { - "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - } - }, - "title": "person_verification_specs", - "type": "object" - } - }, - "title": "individual_specs", - "type": "object" - }, - "tos_shown_and_accepted": { - "type": "boolean" - } - }, - "title": "connect_js_account_token_specs", - "type": "object" - }, - "bank_account": { - "description": "The bank account this token will represent.", - "properties": { - "account_holder_name": { - "maxLength": 5000, - "type": "string" - }, - "account_holder_type": { - "enum": ["company", "individual"], - "maxLength": 5000, - "type": "string" - }, - "account_number": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "type": "string" - }, - "routing_number": { - "maxLength": 5000, - "type": "string" - } - }, - "required": ["account_number", "country"], - "title": "token_create_bank_account", - "type": "object", - "x-stripeBypassValidation": true - }, - "card": { - "anyOf": [ - { - "properties": { - "address_city": { - "maxLength": 5000, - "type": "string" - }, - "address_country": { - "maxLength": 5000, - "type": "string" - }, - "address_line1": { - "maxLength": 5000, - "type": "string" - }, - "address_line2": { - "maxLength": 5000, - "type": "string" - }, - "address_state": { - "maxLength": 5000, - "type": "string" - }, - "address_zip": { - "maxLength": 5000, - "type": "string" - }, - "currency": { - "maxLength": 5000, - "type": "string" - }, - "cvc": { - "maxLength": 5000, - "type": "string" - }, - "exp_month": { - "maxLength": 5000, - "type": "string" - }, - "exp_year": { - "maxLength": 5000, - "type": "string" - }, - "name": { - "maxLength": 5000, - "type": "string" - }, - "number": { - "maxLength": 5000, - "type": "string" } }, - "required": ["exp_month", "exp_year", "number"], - "title": "credit_card_specs", + "title": "billing_details_inner_params", "type": "object" }, - { - "maxLength": 5000, - "type": "string" - } - ], - "x-stripeBypassValidation": true - }, - "customer": { - "description": "The customer (owned by the application's account) for which to create a token. This can be used only with an [OAuth access token](https://stripe.com/docs/connect/standard-accounts) or [Stripe-Account header](https://stripe.com/docs/connect/authentication). For more details, see [Cloning Saved Payment Methods](https://stripe.com/docs/connect/cloning-saved-payment-methods).", - "maxLength": 5000, - "type": "string" - }, - "cvc_update": { - "description": "The updated CVC value this token will represent.", - "properties": { - "cvc": { - "maxLength": 5000, + "financial_account": { "type": "string" - } - }, - "required": ["cvc"], - "title": "cvc_params", - "type": "object" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "person": { - "description": "Information for the person this token will represent.", - "properties": { - "address": { - "properties": { - "city": { - "maxLength": 100, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 200, - "type": "string" - }, - "line2": { - "maxLength": 200, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "address_specs", - "type": "object" }, - "address_kana": { - "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, - "type": "string" - }, - "line2": { - "maxLength": 5000, - "type": "string" - }, - "postal_code": { - "maxLength": 5000, - "type": "string" - }, - "state": { - "maxLength": 5000, - "type": "string" - }, - "town": { - "maxLength": 5000, - "type": "string" - } + "metadata": { + "additionalProperties": { + "type": "string" }, - "title": "japan_address_kana_specs", "type": "object" }, - "address_kanji": { + "type": { + "enum": ["financial_account", "us_bank_account"], + "type": "string" + }, + "us_bank_account": { "properties": { - "city": { - "maxLength": 5000, - "type": "string" - }, - "country": { - "maxLength": 5000, - "type": "string" - }, - "line1": { - "maxLength": 5000, + "account_holder_type": { + "enum": ["company", "individual"], "type": "string" }, - "line2": { + "account_number": { "maxLength": 5000, "type": "string" }, - "postal_code": { - "maxLength": 5000, + "account_type": { + "enum": ["checking", "savings"], "type": "string" }, - "state": { + "financial_connections_account": { "maxLength": 5000, "type": "string" }, - "town": { + "routing_number": { "maxLength": 5000, "type": "string" } }, - "title": "japan_address_kanji_specs", + "title": "payment_method_param", "type": "object" - }, - "dob": { + } + }, + "required": ["type"], + "title": "payment_method_data", + "type": "object" + }, + "destination_payment_method_options": { + "description": "Payment method-specific configuration for this OutboundPayment.", + "properties": { + "us_bank_account": { "anyOf": [ { "properties": { - "day": { - "type": "integer" - }, - "month": { - "type": "integer" - }, - "year": { - "type": "integer" + "network": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" } }, - "required": ["day", "month", "year"], - "title": "date_of_birth_specs", - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "email": { - "type": "string" - }, - "first_name": { - "maxLength": 5000, - "type": "string" - }, - "first_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "first_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "gender": { - "type": "string" - }, - "id_number": { - "maxLength": 5000, - "type": "string" - }, - "last_name": { - "maxLength": 5000, - "type": "string" - }, - "last_name_kana": { - "maxLength": 5000, - "type": "string" - }, - "last_name_kanji": { - "maxLength": 5000, - "type": "string" - }, - "maiden_name": { - "maxLength": 5000, - "type": "string" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, + "title": "payment_method_options_param", "type": "object" }, { @@ -80164,116 +150377,63 @@ "type": "string" } ] - }, - "nationality": { - "maxLength": 5000, - "type": "string" - }, - "phone": { - "type": "string" - }, - "political_exposure": { - "maxLength": 5000, - "type": "string" - }, - "relationship": { - "properties": { - "director": { - "type": "boolean" - }, - "executive": { - "type": "boolean" - }, - "owner": { - "type": "boolean" - }, - "percent_ownership": { - "anyOf": [ - { - "type": "number" - }, - { - "enum": [""], - "type": "string" - } - ] - }, - "representative": { - "type": "boolean" - }, - "title": { - "maxLength": 5000, - "type": "string" - } - }, - "title": "relationship_specs", - "type": "object" - }, - "ssn_last_4": { - "type": "string" - }, - "verification": { - "properties": { - "additional_document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - }, - "document": { - "properties": { - "back": { - "maxLength": 500, - "type": "string" - }, - "front": { - "maxLength": 500, - "type": "string" - } - }, - "title": "person_verification_document_specs", - "type": "object" - } - }, - "title": "person_verification_specs", - "type": "object" } }, - "title": "person_token_specs", + "title": "payment_method_options", "type": "object" }, - "pii": { - "description": "The PII this token will represent.", + "end_user_details": { + "description": "End user details.", "properties": { - "id_number": { - "maxLength": 5000, + "ip_address": { "type": "string" + }, + "present": { + "type": "boolean" } }, - "title": "pii_token_specs", + "required": ["present"], + "title": "end_user_details_params", + "type": "object" + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "financial_account": { + "description": "The FinancialAccount to pull funds from.", + "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", "type": "object" + }, + "statement_descriptor": { + "description": "The description that appears on the receiving end for this OutboundPayment (for example, bank statement for external bank transfer). Maximum 10 characters for `ach` payments, 140 characters for `us_domestic_wire` payments, or 500 characters for `stripe` network transfers. The default value is \"payment\".", + "maxLength": 5000, + "type": "string" } }, + "required": ["amount", "currency", "financial_account"], "type": "object" } } }, - "required": false + "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/token" + "$ref": "#/components/schemas/treasury.outbound_payment" } } }, @@ -80292,10 +150452,10 @@ } } }, - "/v1/tokens/{token}": { + "/v1/treasury/outbound_payments/{id}": { "get": { - "description": "

Retrieves the token with the given ID.

", - "operationId": "GetTokensToken", + "description": "

Retrieves the details of an existing OutboundPayment by passing the unique OutboundPayment ID from either the OutboundPayment creation request or OutboundPayment list.

", + "operationId": "GetTreasuryOutboundPaymentsId", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -80314,7 +150474,7 @@ }, { "in": "path", - "name": "token", + "name": "id", "required": true, "schema": { "maxLength": 5000, @@ -80328,6 +150488,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -80340,7 +150501,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/token" + "$ref": "#/components/schemas/treasury.outbound_payment" } } }, @@ -80359,77 +150520,78 @@ } } }, - "/v1/topups": { - "get": { - "description": "

Returns a list of top-ups.

", - "operationId": "GetTopups", + "/v1/treasury/outbound_payments/{id}/cancel": { + "post": { + "description": "

Cancel an OutboundPayment.

", + "operationId": "PostTreasuryOutboundPaymentsIdCancel", "parameters": [ { - "description": "A positive integer representing how much to transfer.", - "explode": true, - "in": "query", - "name": "amount", - "required": false, + "in": "path", + "name": "id", + "required": true, "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" + "type": "array" + } }, - { - "type": "integer" + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/treasury.outbound_payment" } - ] + } }, - "style": "deepObject" + "description": "Successful response." }, - { - "description": "A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.", - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" } - ] + } }, - "style": "deepObject" - }, + "description": "Error response." + } + } + } + }, + "/v1/treasury/outbound_transfers": { + "get": { + "description": "

Returns a list of OutboundTransfers sent from the specified FinancialAccount.

", + "operationId": "GetTreasuryOutboundTransfers", + "parameters": [ { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -80456,6 +150618,16 @@ }, "style": "deepObject" }, + { + "description": "Returns objects associated with this FinancialAccount.", + "in": "query", + "name": "financial_account", + "required": true, + "schema": { + "type": "string" + }, + "style": "form" + }, { "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", @@ -80478,13 +150650,18 @@ "style": "form" }, { - "description": "Only return top-ups that have the given status. One of `canceled`, `failed`, `pending` or `succeeded`.", + "description": "Only return OutboundTransfers that have the given status: `processing`, `canceled`, `failed`, `posted`, or `returned`.", "in": "query", "name": "status", "required": false, "schema": { - "enum": ["canceled", "failed", "pending", "succeeded"], - "maxLength": 5000, + "enum": [ + "canceled", + "failed", + "posted", + "processing", + "returned" + ], "type": "string" }, "style": "form" @@ -80495,6 +150672,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -80510,8 +150688,9 @@ "description": "", "properties": { "data": { + "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/topup" + "$ref": "#/components/schemas/treasury.outbound_transfer" }, "type": "array" }, @@ -80527,12 +150706,11 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/topups", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "TopupList", + "title": "TreasuryOutboundTransfersResourceOutboundTransferList", "type": "object", "x-expandableFields": ["data"] } @@ -80553,12 +150731,16 @@ } }, "post": { - "description": "

Top up the balance of an account

", - "operationId": "PostTopups", + "description": "

Creates an OutboundTransfer.

", + "operationId": "PostTreasuryOutboundTransfers", "requestBody": { "content": { "application/x-www-form-urlencoded": { "encoding": { + "destination_payment_method_options": { + "explode": true, + "style": "deepObject" + }, "expand": { "explode": true, "style": "deepObject" @@ -80569,9 +150751,10 @@ } }, "schema": { + "additionalProperties": false, "properties": { "amount": { - "description": "A positive integer representing how much to transfer.", + "description": "Amount (in cents) to be transferred.", "type": "integer" }, "currency": { @@ -80583,6 +150766,36 @@ "maxLength": 5000, "type": "string" }, + "destination_payment_method": { + "description": "The PaymentMethod to use as the payment instrument for the OutboundTransfer.", + "maxLength": 5000, + "type": "string" + }, + "destination_payment_method_options": { + "description": "Hash describing payment method configuration details.", + "properties": { + "us_bank_account": { + "anyOf": [ + { + "properties": { + "network": { + "enum": ["ach", "us_domestic_wire"], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [""], + "type": "string" + } + ] + } + }, + "title": "payment_method_options", + "type": "object" + }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -80591,37 +150804,24 @@ }, "type": "array" }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "source": { - "description": "The ID of a source to transfer funds from. For most users, this should be left unspecified which will use the bank account that was set up in the dashboard for the specified currency. In test mode, this can be a test bank token (see [Testing Top-ups](https://stripe.com/docs/connect/testing#testing-top-ups)).", - "maxLength": 5000, + "financial_account": { + "description": "The FinancialAccount to pull funds from.", "type": "string" }, - "statement_descriptor": { - "description": "Extra information about a top-up for the source's bank statement. Limited to 15 ASCII characters.", - "maxLength": 15, - "type": "string" + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" }, - "transfer_group": { - "description": "A string that identifies this top-up as part of a group.", + "statement_descriptor": { + "description": "Statement descriptor to be shown on the receiving end of an OutboundTransfer. Maximum 10 characters for `ach` transfers or 140 characters for `us_domestic_wire` transfers. The default value is \"transfer\".", + "maxLength": 5000, "type": "string" } }, - "required": ["amount", "currency"], + "required": ["amount", "currency", "financial_account"], "type": "object" } } @@ -80633,7 +150833,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/topup" + "$ref": "#/components/schemas/treasury.outbound_transfer" } } }, @@ -80652,10 +150852,10 @@ } } }, - "/v1/topups/{topup}": { + "/v1/treasury/outbound_transfers/{outbound_transfer}": { "get": { - "description": "

Retrieves the details of a top-up that has previously been created. Supply the unique top-up ID that was returned from your previous request, and Stripe will return the corresponding top-up information.

", - "operationId": "GetTopupsTopup", + "description": "

Retrieves the details of an existing OutboundTransfer by passing the unique OutboundTransfer ID from either the OutboundTransfer creation request or OutboundTransfer list.

", + "operationId": "GetTreasuryOutboundTransfersOutboundTransfer", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -80674,57 +150874,7 @@ }, { "in": "path", - "name": "topup", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/topup" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates the metadata of a top-up. Other top-up details are not editable by design.

", - "operationId": "PostTopupsTopup", - "parameters": [ - { - "in": "path", - "name": "topup", + "name": "outbound_transfer", "required": true, "schema": { "maxLength": 5000, @@ -80732,51 +150882,14 @@ }, "style": "simple" } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "properties": { - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - } - }, + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -80788,7 +150901,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/topup" + "$ref": "#/components/schemas/treasury.outbound_transfer" } } }, @@ -80807,14 +150920,14 @@ } } }, - "/v1/topups/{topup}/cancel": { + "/v1/treasury/outbound_transfers/{outbound_transfer}/cancel": { "post": { - "description": "

Cancels a top-up. Only pending top-ups can be canceled.

", - "operationId": "PostTopupsTopupCancel", + "description": "

An OutboundTransfer can be canceled if the funds have not yet been paid out.

", + "operationId": "PostTreasuryOutboundTransfersOutboundTransferCancel", "parameters": [ { "in": "path", - "name": "topup", + "name": "outbound_transfer", "required": true, "schema": { "maxLength": 5000, @@ -80833,6 +150946,7 @@ } }, "schema": { + "additionalProperties": false, "properties": { "expand": { "description": "Specifies which fields in the response should be expanded.", @@ -80854,7 +150968,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/topup" + "$ref": "#/components/schemas/treasury.outbound_transfer" } } }, @@ -80873,54 +150987,11 @@ } } }, - "/v1/transfers": { + "/v1/treasury/received_credits": { "get": { - "description": "

Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.

", - "operationId": "GetTransfers", + "description": "

Returns a list of ReceivedCredits.

", + "operationId": "GetTreasuryReceivedCredits", "parameters": [ - { - "explode": true, - "in": "query", - "name": "created", - "required": false, - "schema": { - "anyOf": [ - { - "properties": { - "gt": { - "type": "integer" - }, - "gte": { - "type": "integer" - }, - "lt": { - "type": "integer" - }, - "lte": { - "type": "integer" - } - }, - "title": "range_query_specs", - "type": "object" - }, - { - "type": "integer" - } - ] - }, - "style": "deepObject" - }, - { - "description": "Only return transfers for the destination specified by this account ID.", - "in": "query", - "name": "destination", - "required": false, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "form" - }, { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", "in": "query", @@ -80947,6 +151018,16 @@ }, "style": "deepObject" }, + { + "description": "The FinancialAccount that received the funds.", + "in": "query", + "name": "financial_account", + "required": true, + "schema": { + "type": "string" + }, + "style": "form" + }, { "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", "in": "query", @@ -80957,6 +151038,31 @@ }, "style": "form" }, + { + "description": "Only return ReceivedCredits described by the flow.", + "explode": true, + "in": "query", + "name": "linked_flows", + "required": false, + "schema": { + "properties": { + "source_flow_type": { + "enum": [ + "credit_reversal", + "other", + "outbound_payment", + "payout" + ], + "type": "string", + "x-stripeBypassValidation": true + } + }, + "required": ["source_flow_type"], + "title": "linked_flows_param", + "type": "object" + }, + "style": "deepObject" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -80969,13 +151075,14 @@ "style": "form" }, { - "description": "Only return transfers with the specified transfer group.", + "description": "Only return ReceivedCredits that have the given status: `succeeded` or `failed`.", "in": "query", - "name": "transfer_group", + "name": "status", "required": false, "schema": { - "maxLength": 5000, - "type": "string" + "enum": ["failed", "succeeded"], + "type": "string", + "x-stripeBypassValidation": true }, "style": "form" } @@ -80985,6 +151092,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -81002,7 +151110,7 @@ "data": { "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/transfer" + "$ref": "#/components/schemas/treasury.received_credit" }, "type": "array" }, @@ -81018,12 +151126,11 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, - "pattern": "^/v1/transfers", "type": "string" } }, "required": ["data", "has_more", "object", "url"], - "title": "TransferList", + "title": "TreasuryReceivedCreditsResourceReceivedCreditList", "type": "object", "x-expandableFields": ["data"] } @@ -81042,86 +151149,58 @@ "description": "Error response." } } - }, - "post": { - "description": "

To send funds from your Stripe account to a connected account, you create a new transfer object. Your Stripe balance must be able to cover the transfer amount, or you’ll receive an “Insufficient Funds” error.

", - "operationId": "PostTransfers", + } + }, + "/v1/treasury/received_credits/{id}": { + "get": { + "description": "

Retrieves the details of an existing ReceivedCredit by passing the unique ReceivedCredit ID from the ReceivedCredit list.

", + "operationId": "GetTreasuryReceivedCreditsId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "amount": { - "description": "A positive integer in %s representing how much to transfer.", - "type": "integer" - }, - "currency": { - "description": "3-letter [ISO code for currency](https://stripe.com/docs/payouts).", - "type": "string" - }, - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 5000, - "type": "string" - }, - "destination": { - "description": "The ID of a connected Stripe account. See the Connect documentation for details.", - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "source_transaction": { - "description": "You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-availability) for details.", - "type": "string" - }, - "source_type": { - "description": "The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`.", - "enum": ["bank_account", "card", "fpx"], - "maxLength": 5000, - "type": "string", - "x-stripeBypassValidation": true - }, - "transfer_group": { - "description": "A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/charges-transfers#transfer-options) for details.", - "type": "string" - } - }, - "required": ["currency", "destination"], + "additionalProperties": false, + "properties": {}, "type": "object" } } }, - "required": true + "required": false }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/transfer" + "$ref": "#/components/schemas/treasury.received_credit" } } }, @@ -81140,10 +151219,10 @@ } } }, - "/v1/transfers/{id}/reversals": { + "/v1/treasury/received_debits": { "get": { - "description": "

You can see a list of the reversals belonging to a specific transfer. Note that the 10 most recent reversals are always available by default on the transfer object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional reversals.

", - "operationId": "GetTransfersIdReversals", + "description": "

Returns a list of ReceivedDebits.

", + "operationId": "GetTreasuryReceivedDebits", "parameters": [ { "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", @@ -81172,14 +151251,14 @@ "style": "deepObject" }, { - "in": "path", - "name": "id", + "description": "The FinancialAccount that funds were pulled from.", + "in": "query", + "name": "financial_account", "required": true, "schema": { - "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" }, { "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", @@ -81201,6 +151280,18 @@ "type": "string" }, "style": "form" + }, + { + "description": "Only return ReceivedDebits that have the given status: `succeeded` or `failed`.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["failed", "succeeded"], + "type": "string", + "x-stripeBypassValidation": true + }, + "style": "form" } ], "requestBody": { @@ -81208,6 +151299,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -81225,7 +151317,7 @@ "data": { "description": "Details about each object.", "items": { - "$ref": "#/components/schemas/transfer_reversal" + "$ref": "#/components/schemas/treasury.received_debit" }, "type": "array" }, @@ -81245,7 +151337,7 @@ } }, "required": ["data", "has_more", "object", "url"], - "title": "TransferReversalList", + "title": "TreasuryReceivedDebitsResourceReceivedDebitList", "type": "object", "x-expandableFields": ["data"] } @@ -81264,11 +151356,28 @@ "description": "Error response." } } - }, - "post": { - "description": "

When you create a new reversal, you must specify a transfer to create it on.

\n\n

When reversing transfers, you can optionally reverse part of the transfer. You can do so as many times as you wish until the entire transfer has been reversed.

\n\n

Once entirely reversed, a transfer can’t be reversed again. This method will return an error when called on an already-reversed transfer, or when trying to reverse more money than is left on a transfer.

", - "operationId": "PostTransfersIdReversals", + } + }, + "/v1/treasury/received_debits/{id}": { + "get": { + "description": "

Retrieves the details of an existing ReceivedDebit by passing the unique ReceivedDebit ID from the ReceivedDebit list

", + "operationId": "GetTreasuryReceivedDebitsId", "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, { "in": "path", "name": "id", @@ -81283,55 +151392,10 @@ "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "amount": { - "description": "A positive integer in %s representing how much of this transfer to reverse. Can only reverse up to the unreversed amount remaining of the transfer. Partial transfer reversals are only allowed for transfers to Stripe Accounts. Defaults to the entire transfer amount.", - "type": "integer" - }, - "description": { - "description": "An arbitrary string which you can attach to a reversal object. It is displayed alongside the reversal in the Dashboard. This will be unset if you POST an empty value.", - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - }, - "refund_application_fee": { - "description": "Boolean indicating whether the application fee should be refunded when reversing this transfer. If a full transfer reversal is given, the full application fee will be refunded. Otherwise, the application fee will be refunded with an amount proportional to the amount of the transfer reversed.", - "type": "boolean" - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -81343,7 +151407,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/transfer_reversal" + "$ref": "#/components/schemas/treasury.received_debit" } } }, @@ -81362,11 +151426,87 @@ } } }, - "/v1/transfers/{transfer}": { + "/v1/treasury/transaction_entries": { "get": { - "description": "

Retrieves the details of an existing transfer. Supply the unique transfer ID from either a transfer creation request or the transfer list, and Stripe will return the corresponding transfer information.

", - "operationId": "GetTransfersTransfer", + "description": "

Retrieves a list of TransactionEntry objects.

", + "operationId": "GetTreasuryTransactionEntries", "parameters": [ + { + "description": "Only return TransactionEntries that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "explode": true, + "in": "query", + "name": "effective_at", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -81383,110 +151523,66 @@ "style": "deepObject" }, { - "in": "path", - "name": "transfer", + "description": "Returns objects associated with this FinancialAccount.", + "in": "query", + "name": "financial_account", "required": true, "schema": { - "maxLength": 5000, "type": "string" }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "properties": {}, - "type": "object" - } - } + "style": "form" }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/transfer" - } - } + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" }, - "description": "Successful response." + "style": "form" }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } + { + "description": "The results are in reverse chronological order by `created` or `effective_at`. The default is `created`.", + "in": "query", + "name": "order_by", + "required": false, + "schema": { + "enum": ["created", "effective_at"], + "type": "string" }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

This request accepts only metadata as an argument.

", - "operationId": "PostTransfersTransfer", - "parameters": [ + "style": "form" + }, { - "in": "path", - "name": "transfer", - "required": true, + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" + }, + { + "description": "Only return TransactionEntries associated with this Transaction.", + "in": "query", + "name": "transaction", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "description": { - "description": "An arbitrary string attached to the object. Often useful for displaying to users.", - "maxLength": 5000, - "type": "string" - }, - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - } - }, + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -81498,7 +151594,35 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/transfer" + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/treasury.transaction_entry" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "pattern": "^/v1/treasury/transaction_entries", + "type": "string" + } + }, + "required": ["data", "has_more", "object", "url"], + "title": "TreasuryTransactionsResourceTransactionEntryList", + "type": "object", + "x-expandableFields": ["data"] } } }, @@ -81517,10 +151641,10 @@ } } }, - "/v1/transfers/{transfer}/reversals/{id}": { + "/v1/treasury/transaction_entries/{id}": { "get": { - "description": "

By default, you can see the 10 most recent reversals stored directly on the transfer object, but you can also retrieve details about a specific reversal stored on the transfer.

", - "operationId": "GetTransfersTransferReversalsId", + "description": "

Retrieves a TransactionEntry object.

", + "operationId": "GetTreasuryTransactionEntriesId", "parameters": [ { "description": "Specifies which fields in the response should be expanded.", @@ -81546,16 +151670,6 @@ "type": "string" }, "style": "simple" - }, - { - "in": "path", - "name": "transfer", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" } ], "requestBody": { @@ -81563,6 +151677,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -81575,7 +151690,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/transfer_reversal" + "$ref": "#/components/schemas/treasury.transaction_entry" } } }, @@ -81592,71 +151707,268 @@ "description": "Error response." } } - }, - "post": { - "description": "

Updates the specified reversal by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

\n\n

This request only accepts metadata and description as arguments.

", - "operationId": "PostTransfersTransferReversalsId", + } + }, + "/v1/treasury/transactions": { + "get": { + "description": "

Retrieves a list of Transaction objects.

", + "operationId": "GetTreasuryTransactions", "parameters": [ { - "in": "path", - "name": "id", - "required": true, + "description": "Only return Transactions that were created during the given date interval.", + "explode": true, + "in": "query", + "name": "created", + "required": false, + "schema": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + }, + "style": "deepObject" + }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" }, { - "in": "path", - "name": "transfer", + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "description": "Returns objects associated with this FinancialAccount.", + "in": "query", + "name": "financial_account", "required": true, + "schema": { + "type": "string" + }, + "style": "form" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "The results are in reverse chronological order by `created` or `posted_at`. The default is `created`.", + "in": "query", + "name": "order_by", + "required": false, + "schema": { + "enum": ["created", "posted_at"], + "type": "string", + "x-stripeBypassValidation": true + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, "schema": { "maxLength": 5000, "type": "string" }, - "style": "simple" + "style": "form" + }, + { + "description": "Only return Transactions that have the given status: `open`, `posted`, or `void`.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": ["open", "posted", "void"], + "type": "string" + }, + "style": "form" + }, + { + "description": "A filter for the `status_transitions.posted_at` timestamp. When using this filter, `status=posted` and `order_by=posted_at` must also be specified.", + "explode": true, + "in": "query", + "name": "status_transitions", + "required": false, + "schema": { + "properties": { + "posted_at": { + "anyOf": [ + { + "properties": { + "gt": { + "type": "integer" + }, + "gte": { + "type": "integer" + }, + "lt": { + "type": "integer" + }, + "lte": { + "type": "integer" + } + }, + "title": "range_query_specs", + "type": "object" + }, + { + "type": "integer" + } + ] + } + }, + "title": "status_transition_timestamp_specs", + "type": "object" + }, + "style": "deepObject" } ], "requestBody": { "content": { "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - } - }, + "encoding": {}, "schema": { - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "description": "", + "properties": { + "data": { + "description": "Details about each object.", + "items": { + "$ref": "#/components/schemas/treasury.transaction" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": ["list"], "type": "string" }, - "type": "array" + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } }, - "metadata": { - "anyOf": [ - { - "additionalProperties": { - "type": "string" - }, - "type": "object" - }, - { - "enum": [""], - "type": "string" - } - ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." - } - }, + "required": ["data", "has_more", "object", "url"], + "title": "TreasuryTransactionsResourceTransactionList", + "type": "object", + "x-expandableFields": ["data"] + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/treasury/transactions/{id}": { + "get": { + "description": "

Retrieves the details of an existing Transaction.

", + "operationId": "GetTreasuryTransactionsId", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "id", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, "type": "object" } } @@ -81668,7 +151980,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/transfer_reversal" + "$ref": "#/components/schemas/treasury.transaction" } } }, @@ -81745,6 +152057,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -81782,6 +152095,7 @@ } }, "required": ["data", "has_more", "object", "url"], + "title": "NotificationWebhookEndpointList", "type": "object", "x-expandableFields": ["data"] } @@ -81808,6 +152122,10 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { + "description": { + "explode": true, + "style": "deepObject" + }, "enabled_events": { "explode": true, "style": "deepObject" @@ -81822,6 +152140,7 @@ } }, "schema": { + "additionalProperties": false, "properties": { "api_version": { "description": "Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version.", @@ -81921,7 +152240,13 @@ "2019-11-05", "2019-12-03", "2020-03-02", - "2020-08-27" + "2020-08-27", + "2022-08-01", + "2022-11-15", + "2023-08-16", + "2023-10-16", + "2024-04-10", + "2024-06-20" ], "maxLength": 5000, "type": "string", @@ -81932,9 +152257,17 @@ "type": "boolean" }, "description": { - "description": "An optional description of what the webhook is used for.", - "maxLength": 5000, - "type": "string" + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "An optional description of what the webhook is used for." }, "enabled_events": { "description": "The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.", @@ -81951,9 +152284,12 @@ "application_fee.refund.updated", "application_fee.refunded", "balance.available", + "billing.alert.triggered", "billing_portal.configuration.created", "billing_portal.configuration.updated", + "billing_portal.session.created", "capability.updated", + "cash_balance.funds_available", "charge.captured", "charge.dispute.closed", "charge.dispute.created", @@ -81970,6 +152306,14 @@ "checkout.session.async_payment_failed", "checkout.session.async_payment_succeeded", "checkout.session.completed", + "checkout.session.expired", + "climate.order.canceled", + "climate.order.created", + "climate.order.delayed", + "climate.order.delivered", + "climate.order.product_substituted", + "climate.product.created", + "climate.product.pricing_updated", "coupon.created", "coupon.deleted", "coupon.updated", @@ -81987,20 +152331,38 @@ "customer.source.updated", "customer.subscription.created", "customer.subscription.deleted", + "customer.subscription.paused", "customer.subscription.pending_update_applied", "customer.subscription.pending_update_expired", + "customer.subscription.resumed", "customer.subscription.trial_will_end", "customer.subscription.updated", "customer.tax_id.created", "customer.tax_id.deleted", "customer.tax_id.updated", "customer.updated", + "customer_cash_balance_transaction.created", + "entitlements.active_entitlement_summary.updated", "file.created", + "financial_connections.account.created", + "financial_connections.account.deactivated", + "financial_connections.account.disconnected", + "financial_connections.account.reactivated", + "financial_connections.account.refreshed_balance", + "financial_connections.account.refreshed_ownership", + "financial_connections.account.refreshed_transactions", + "identity.verification_session.canceled", + "identity.verification_session.created", + "identity.verification_session.processing", + "identity.verification_session.redacted", + "identity.verification_session.requires_input", + "identity.verification_session.verified", "invoice.created", "invoice.deleted", "invoice.finalization_failed", "invoice.finalized", "invoice.marked_uncollectible", + "invoice.overdue", "invoice.paid", "invoice.payment_action_required", "invoice.payment_failed", @@ -82009,9 +152371,9 @@ "invoice.upcoming", "invoice.updated", "invoice.voided", + "invoice.will_be_due", "invoiceitem.created", "invoiceitem.deleted", - "invoiceitem.updated", "issuing_authorization.created", "issuing_authorization.request", "issuing_authorization.updated", @@ -82022,23 +152384,28 @@ "issuing_dispute.closed", "issuing_dispute.created", "issuing_dispute.funds_reinstated", + "issuing_dispute.funds_rescinded", "issuing_dispute.submitted", "issuing_dispute.updated", + "issuing_personalization_design.activated", + "issuing_personalization_design.deactivated", + "issuing_personalization_design.rejected", + "issuing_personalization_design.updated", + "issuing_token.created", + "issuing_token.updated", "issuing_transaction.created", "issuing_transaction.updated", "mandate.updated", - "order.created", - "order.payment_failed", - "order.payment_succeeded", - "order.updated", - "order_return.created", "payment_intent.amount_capturable_updated", "payment_intent.canceled", "payment_intent.created", + "payment_intent.partially_funded", "payment_intent.payment_failed", "payment_intent.processing", "payment_intent.requires_action", "payment_intent.succeeded", + "payment_link.created", + "payment_link.updated", "payment_method.attached", "payment_method.automatically_updated", "payment_method.detached", @@ -82047,6 +152414,7 @@ "payout.created", "payout.failed", "payout.paid", + "payout.reconciliation_completed", "payout.updated", "person.created", "person.deleted", @@ -82062,11 +152430,14 @@ "product.updated", "promotion_code.created", "promotion_code.updated", + "quote.accepted", + "quote.canceled", + "quote.created", + "quote.finalized", "radar.early_fraud_warning.created", "radar.early_fraud_warning.updated", - "recipient.created", - "recipient.deleted", - "recipient.updated", + "refund.created", + "refund.updated", "reporting.report_run.failed", "reporting.report_run.succeeded", "reporting.report_type.updated", @@ -82078,9 +152449,6 @@ "setup_intent.setup_failed", "setup_intent.succeeded", "sigma.scheduled_query_run.created", - "sku.created", - "sku.deleted", - "sku.updated", "source.canceled", "source.chargeable", "source.failed", @@ -82095,18 +152463,54 @@ "subscription_schedule.expiring", "subscription_schedule.released", "subscription_schedule.updated", + "tax.settings.updated", "tax_rate.created", "tax_rate.updated", + "terminal.reader.action_failed", + "terminal.reader.action_succeeded", + "test_helpers.test_clock.advancing", + "test_helpers.test_clock.created", + "test_helpers.test_clock.deleted", + "test_helpers.test_clock.internal_failure", + "test_helpers.test_clock.ready", "topup.canceled", "topup.created", "topup.failed", "topup.reversed", "topup.succeeded", "transfer.created", - "transfer.failed", - "transfer.paid", "transfer.reversed", - "transfer.updated" + "transfer.updated", + "treasury.credit_reversal.created", + "treasury.credit_reversal.posted", + "treasury.debit_reversal.completed", + "treasury.debit_reversal.created", + "treasury.debit_reversal.initial_credit_granted", + "treasury.financial_account.closed", + "treasury.financial_account.created", + "treasury.financial_account.features_status_updated", + "treasury.inbound_transfer.canceled", + "treasury.inbound_transfer.created", + "treasury.inbound_transfer.failed", + "treasury.inbound_transfer.succeeded", + "treasury.outbound_payment.canceled", + "treasury.outbound_payment.created", + "treasury.outbound_payment.expected_arrival_date_updated", + "treasury.outbound_payment.failed", + "treasury.outbound_payment.posted", + "treasury.outbound_payment.returned", + "treasury.outbound_payment.tracking_details_updated", + "treasury.outbound_transfer.canceled", + "treasury.outbound_transfer.created", + "treasury.outbound_transfer.expected_arrival_date_updated", + "treasury.outbound_transfer.failed", + "treasury.outbound_transfer.posted", + "treasury.outbound_transfer.returned", + "treasury.outbound_transfer.tracking_details_updated", + "treasury.received_credit.created", + "treasury.received_credit.failed", + "treasury.received_credit.succeeded", + "treasury.received_debit.created" ], "type": "string", "x-stripeBypassValidation": true @@ -82193,6 +152597,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -82258,6 +152663,7 @@ "application/x-www-form-urlencoded": { "encoding": {}, "schema": { + "additionalProperties": false, "properties": {}, "type": "object" } @@ -82307,6 +152713,10 @@ "content": { "application/x-www-form-urlencoded": { "encoding": { + "description": { + "explode": true, + "style": "deepObject" + }, "enabled_events": { "explode": true, "style": "deepObject" @@ -82321,11 +152731,20 @@ } }, "schema": { + "additionalProperties": false, "properties": { "description": { - "description": "An optional description of what the webhook is used for.", - "maxLength": 5000, - "type": "string" + "anyOf": [ + { + "maxLength": 5000, + "type": "string" + }, + { + "enum": [""], + "type": "string" + } + ], + "description": "An optional description of what the webhook is used for." }, "disabled": { "description": "Disable the webhook endpoint if set to true.", @@ -82346,9 +152765,12 @@ "application_fee.refund.updated", "application_fee.refunded", "balance.available", + "billing.alert.triggered", "billing_portal.configuration.created", "billing_portal.configuration.updated", + "billing_portal.session.created", "capability.updated", + "cash_balance.funds_available", "charge.captured", "charge.dispute.closed", "charge.dispute.created", @@ -82365,6 +152787,14 @@ "checkout.session.async_payment_failed", "checkout.session.async_payment_succeeded", "checkout.session.completed", + "checkout.session.expired", + "climate.order.canceled", + "climate.order.created", + "climate.order.delayed", + "climate.order.delivered", + "climate.order.product_substituted", + "climate.product.created", + "climate.product.pricing_updated", "coupon.created", "coupon.deleted", "coupon.updated", @@ -82382,20 +152812,38 @@ "customer.source.updated", "customer.subscription.created", "customer.subscription.deleted", + "customer.subscription.paused", "customer.subscription.pending_update_applied", "customer.subscription.pending_update_expired", + "customer.subscription.resumed", "customer.subscription.trial_will_end", "customer.subscription.updated", "customer.tax_id.created", "customer.tax_id.deleted", "customer.tax_id.updated", "customer.updated", + "customer_cash_balance_transaction.created", + "entitlements.active_entitlement_summary.updated", "file.created", + "financial_connections.account.created", + "financial_connections.account.deactivated", + "financial_connections.account.disconnected", + "financial_connections.account.reactivated", + "financial_connections.account.refreshed_balance", + "financial_connections.account.refreshed_ownership", + "financial_connections.account.refreshed_transactions", + "identity.verification_session.canceled", + "identity.verification_session.created", + "identity.verification_session.processing", + "identity.verification_session.redacted", + "identity.verification_session.requires_input", + "identity.verification_session.verified", "invoice.created", "invoice.deleted", "invoice.finalization_failed", "invoice.finalized", "invoice.marked_uncollectible", + "invoice.overdue", "invoice.paid", "invoice.payment_action_required", "invoice.payment_failed", @@ -82404,9 +152852,9 @@ "invoice.upcoming", "invoice.updated", "invoice.voided", + "invoice.will_be_due", "invoiceitem.created", "invoiceitem.deleted", - "invoiceitem.updated", "issuing_authorization.created", "issuing_authorization.request", "issuing_authorization.updated", @@ -82417,23 +152865,28 @@ "issuing_dispute.closed", "issuing_dispute.created", "issuing_dispute.funds_reinstated", + "issuing_dispute.funds_rescinded", "issuing_dispute.submitted", "issuing_dispute.updated", + "issuing_personalization_design.activated", + "issuing_personalization_design.deactivated", + "issuing_personalization_design.rejected", + "issuing_personalization_design.updated", + "issuing_token.created", + "issuing_token.updated", "issuing_transaction.created", "issuing_transaction.updated", "mandate.updated", - "order.created", - "order.payment_failed", - "order.payment_succeeded", - "order.updated", - "order_return.created", "payment_intent.amount_capturable_updated", "payment_intent.canceled", "payment_intent.created", + "payment_intent.partially_funded", "payment_intent.payment_failed", "payment_intent.processing", "payment_intent.requires_action", "payment_intent.succeeded", + "payment_link.created", + "payment_link.updated", "payment_method.attached", "payment_method.automatically_updated", "payment_method.detached", @@ -82442,6 +152895,7 @@ "payout.created", "payout.failed", "payout.paid", + "payout.reconciliation_completed", "payout.updated", "person.created", "person.deleted", @@ -82457,11 +152911,14 @@ "product.updated", "promotion_code.created", "promotion_code.updated", + "quote.accepted", + "quote.canceled", + "quote.created", + "quote.finalized", "radar.early_fraud_warning.created", "radar.early_fraud_warning.updated", - "recipient.created", - "recipient.deleted", - "recipient.updated", + "refund.created", + "refund.updated", "reporting.report_run.failed", "reporting.report_run.succeeded", "reporting.report_type.updated", @@ -82473,9 +152930,6 @@ "setup_intent.setup_failed", "setup_intent.succeeded", "sigma.scheduled_query_run.created", - "sku.created", - "sku.deleted", - "sku.updated", "source.canceled", "source.chargeable", "source.failed", @@ -82490,18 +152944,54 @@ "subscription_schedule.expiring", "subscription_schedule.released", "subscription_schedule.updated", + "tax.settings.updated", "tax_rate.created", "tax_rate.updated", + "terminal.reader.action_failed", + "terminal.reader.action_succeeded", + "test_helpers.test_clock.advancing", + "test_helpers.test_clock.created", + "test_helpers.test_clock.deleted", + "test_helpers.test_clock.internal_failure", + "test_helpers.test_clock.ready", "topup.canceled", "topup.created", "topup.failed", "topup.reversed", "topup.succeeded", "transfer.created", - "transfer.failed", - "transfer.paid", "transfer.reversed", - "transfer.updated" + "transfer.updated", + "treasury.credit_reversal.created", + "treasury.credit_reversal.posted", + "treasury.debit_reversal.completed", + "treasury.debit_reversal.created", + "treasury.debit_reversal.initial_credit_granted", + "treasury.financial_account.closed", + "treasury.financial_account.created", + "treasury.financial_account.features_status_updated", + "treasury.inbound_transfer.canceled", + "treasury.inbound_transfer.created", + "treasury.inbound_transfer.failed", + "treasury.inbound_transfer.succeeded", + "treasury.outbound_payment.canceled", + "treasury.outbound_payment.created", + "treasury.outbound_payment.expected_arrival_date_updated", + "treasury.outbound_payment.failed", + "treasury.outbound_payment.posted", + "treasury.outbound_payment.returned", + "treasury.outbound_payment.tracking_details_updated", + "treasury.outbound_transfer.canceled", + "treasury.outbound_transfer.created", + "treasury.outbound_transfer.expected_arrival_date_updated", + "treasury.outbound_transfer.failed", + "treasury.outbound_transfer.posted", + "treasury.outbound_transfer.returned", + "treasury.outbound_transfer.tracking_details_updated", + "treasury.received_credit.created", + "treasury.received_credit.failed", + "treasury.received_credit.succeeded", + "treasury.received_debit.created" ], "type": "string", "x-stripeBypassValidation": true diff --git a/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/payment_methods.json b/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/payment_methods.json index e6ece32c7f630..223dcd3423aca 100644 --- a/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/payment_methods.json +++ b/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/payment_methods.json @@ -1,5 +1,319 @@ { "$schema": "https://json-schema.org/draft-07/schema#", "additionalProperties": true, - "$ref": "payment_method.json" + "type": ["object", "null"], + "properties": { + "acss_debit": { + "properties": { + "bank_name": { + "type": ["null", "string"] + }, + "fingerprint": { + "type": ["null", "string"] + }, + "institution_number": { + "type": ["null", "string"] + }, + "last4": { + "type": ["null", "string"] + }, + "transit_number": { + "type": ["null", "string"] + } + }, + "type": ["null", "object"] + }, + "affirm": { + "type": ["null", "object"] + }, + "afterpay_clearpay": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "alipay": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "allow_redisplay": { + "type": ["null", "string"] + }, + "amazon_pay": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "au_becs_debit": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "bsb_number": { + "type": ["null", "string"] + }, + "fingerprint": { + "type": ["null", "string"] + }, + "last4": { + "type": ["null", "string"] + } + } + }, + "bacs_debit": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "fingerprint": { + "type": ["null", "string"] + }, + "last4": { + "type": ["null", "string"] + }, + "sort_code": { + "type": ["null", "string"] + } + } + }, + "bancontact": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "blik": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "boleto": { + "type": ["null", "object"], + "properties": { + "tax_id": { + "type": ["null", "string"] + } + } + }, + "cashapp": { + "properties": { + "buyer_id": { + "type": ["null", "string"] + }, + "cashtag": { + "type": ["null", "string"] + } + }, + "type": ["null", "object"] + }, + "billing_details": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "address": { + "$ref": "address.json" + }, + "email": { + "type": ["null", "string"] + }, + "name": { + "type": ["null", "string"] + }, + "phone": { + "type": ["null", "string"] + } + } + }, + "card": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "brand": { + "type": ["null", "string"] + }, + "checks": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "address_line1_check": { + "type": ["null", "string"] + }, + "address_postal_code_check": { + "type": ["null", "string"] + }, + "cvc_check": { + "type": ["null", "string"] + } + } + }, + "country": { + "type": ["null", "string"] + }, + "exp_month": { + "type": ["null", "integer"] + }, + "exp_year": { + "type": ["null", "integer"] + }, + "fingerprint": { + "type": ["null", "string"] + }, + "funding": { + "type": ["null", "string"] + }, + "generated_from": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "last4": { + "type": ["null", "string"] + }, + "networks": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "available": { + "type": ["null", "array"], + "items": { + "type": ["null", "string"] + } + }, + "preferred": { + "type": ["null", "string"] + } + } + }, + "three_d_secure_usage": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "supported": { + "type": ["null", "boolean"] + } + } + }, + "wallet": { + "additionalProperties": true, + "type": ["null", "object"] + } + } + }, + "card_present": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "created": { + "type": ["null", "integer"] + }, + "updated": { + "type": ["null", "integer"] + }, + "customer": { + "type": ["null", "string"] + }, + "eps": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "bank": { + "type": ["null", "string"] + } + } + }, + "fpx": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "bank": { + "type": ["null", "string"] + } + } + }, + "giropay": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "grabpay": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "id": { + "type": ["null", "string"] + }, + "ideal": { + "additionalProperties": true, + "type": ["null", "object"], + "properties": { + "bank": { + "type": ["null", "string"] + }, + "bic": { + "type": ["null", "string"] + } + } + }, + "interac_present": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "livemode": { + "type": ["null", "boolean"] + }, + "metadata": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "object": { + "type": ["null", "string"] + }, + "oxxo": { + "additionalProperties": true, + "type": ["null", "object"] + }, + "p24": { + "type": ["null", "object"], + "additionalProperties": true, + "properties": { + "bank": { + "type": ["null", "string"] + } + } + }, + "sepa_debit": { + "type": ["null", "object"], + "additionalProperties": true, + "properties": { + "bank_code": { + "type": ["null", "string"] + }, + "branch_code": { + "type": ["null", "string"] + }, + "country": { + "type": ["null", "string"] + }, + "fingerprint": { + "type": ["null", "string"] + }, + "generated_from": { + "type": ["null", "object"], + "properties": { + "charge": { + "type": ["null", "string"] + }, + "setup_attempt": { + "type": ["null", "string"] + } + } + }, + "last4": { + "type": ["null", "string"] + } + } + }, + "sofort": { + "type": ["null", "object"], + "additionalProperties": true, + "properties": { + "country": { + "type": ["null", "string"] + } + } + }, + "type": { + "type": ["null", "string"] + } + } } diff --git a/airbyte-integrations/connectors/source-stripe/source_stripe/source.py b/airbyte-integrations/connectors/source-stripe/source_stripe/source.py index d8468b2a0738d..14aa19ff31a52 100644 --- a/airbyte-integrations/connectors/source-stripe/source_stripe/source.py +++ b/airbyte-integrations/connectors/source-stripe/source_stripe/source.py @@ -8,9 +8,8 @@ from typing import Any, List, Mapping, MutableMapping, Optional, Tuple import pendulum -import stripe from airbyte_cdk.entrypoint import logger as entrypoint_logger -from airbyte_cdk.models import ConfiguredAirbyteCatalog, FailureType +from airbyte_cdk.models import ConfiguredAirbyteCatalog, FailureType, SyncMode from airbyte_cdk.sources.concurrent_source.concurrent_source import ConcurrentSource from airbyte_cdk.sources.concurrent_source.concurrent_source_adapter import ConcurrentSourceAdapter from airbyte_cdk.sources.connector_state_manager import ConnectorStateManager @@ -23,20 +22,19 @@ from airbyte_cdk.sources.streams.concurrent.state_converters.datetime_stream_state_converter import EpochValueConcurrentStreamStateConverter from airbyte_cdk.sources.streams.http.requests_native_auth import TokenAuthenticator from airbyte_cdk.utils.traced_exception import AirbyteTracedException -from airbyte_protocol.models import SyncMode from source_stripe.streams import ( CreatedCursorIncrementalStripeStream, CustomerBalanceTransactions, Events, IncrementalStripeStream, ParentIncrementalStipeSubStream, - Persons, SetupAttempts, StripeLazySubStream, StripeStream, StripeSubStream, UpdatedCursorIncrementalStripeLazySubStream, UpdatedCursorIncrementalStripeStream, + UpdatedCursorIncrementalStripeSubStream, ) logger = logging.getLogger("airbyte") @@ -107,14 +105,29 @@ def validate_and_fill_with_defaults(config: MutableMapping[str, Any]) -> Mutable return config def check_connection(self, logger: logging.Logger, config: MutableMapping[str, Any]) -> Tuple[bool, Any]: - self.validate_and_fill_with_defaults(config) - stripe.api_key = config["client_secret"] + args = self._get_stream_base_args(config) + account_stream = StripeStream(name="accounts", path="accounts", use_cache=USE_CACHE, **args) try: - stripe.Account.retrieve(config["account_id"]) - except (stripe.error.AuthenticationError, stripe.error.PermissionError) as e: - return False, str(e) + next(account_stream.read_records(sync_mode=SyncMode.full_refresh), None) + except AirbyteTracedException as error: + if error.failure_type == FailureType.config_error: + return False, error.message + raise error return True, None + def _get_stream_base_args(self, config: MutableMapping[str, Any]) -> MutableMapping[str, Any]: + config = self.validate_and_fill_with_defaults(config) + authenticator = TokenAuthenticator(config["client_secret"]) + start_timestamp = self._start_date_to_timestamp(config) + args = { + "authenticator": authenticator, + "account_id": config["account_id"], + "start_date": start_timestamp, + "slice_range": config["slice_range"], + "api_budget": self.get_api_call_budget(config), + } + return args + @staticmethod def customers(**args): # The Customers stream is instantiated in a dedicated method to allow parametrization and avoid duplicated code. @@ -174,17 +187,7 @@ def get_api_call_budget(self, config: Mapping[str, Any]) -> AbstractAPIBudget: return HttpAPIBudget(policies=policies) def streams(self, config: MutableMapping[str, Any]) -> List[Stream]: - config = self.validate_and_fill_with_defaults(config) - authenticator = TokenAuthenticator(config["client_secret"]) - - start_timestamp = self._start_date_to_timestamp(config) - args = { - "authenticator": authenticator, - "account_id": config["account_id"], - "start_date": start_timestamp, - "slice_range": config["slice_range"], - "api_budget": self.get_api_call_budget(config), - } + args = self._get_stream_base_args(config) incremental_args = {**args, "lookback_window_days": config["lookback_window_days"]} subscriptions = IncrementalStripeStream( name="subscriptions", @@ -288,7 +291,13 @@ def streams(self, config: MutableMapping[str, Any]) -> List[Stream]: response_filter=lambda record: record["object"] == "bank_account", **args, ), - Persons(**args), + UpdatedCursorIncrementalStripeSubStream( + name="persons", + path=lambda self, stream_slice, *args, **kwargs: f"accounts/{stream_slice['parent']['id']}/persons", + parent=StripeStream(name="accounts", path="accounts", use_cache=USE_CACHE, **args), + event_types=["person.created", "person.updated", "person.deleted"], + **args, + ), SetupAttempts(**incremental_args), StripeStream(name="accounts", path="accounts", use_cache=USE_CACHE, **args), CreatedCursorIncrementalStripeStream(name="shipping_rates", path="shipping_rates", **incremental_args), @@ -306,17 +315,6 @@ def streams(self, config: MutableMapping[str, Any]) -> List[Stream]: ], **args, ), - UpdatedCursorIncrementalStripeStream( - name="payment_methods", - path="payment_methods", - event_types=[ - "payment_method.attached", - "payment_method.automatically_updated", - "payment_method.detached", - "payment_method.updated", - ], - **args, - ), UpdatedCursorIncrementalStripeStream( name="credit_notes", path="credit_notes", @@ -483,6 +481,13 @@ def streams(self, config: MutableMapping[str, Any]) -> List[Stream]: sub_items_attr="refunds", **args, ), + UpdatedCursorIncrementalStripeSubStream( + name="payment_methods", + path=lambda self, stream_slice, *args, **kwargs: f"customers/{stream_slice['parent']['id']}/payment_methods", + parent=self.customers(**args), + event_types=["payment_method.*"], + **args, + ), UpdatedCursorIncrementalStripeLazySubStream( name="bank_accounts", path=lambda self, stream_slice, *args, **kwargs: f"customers/{stream_slice['parent']['id']}/bank_accounts", @@ -532,7 +537,7 @@ def streams(self, config: MutableMapping[str, Any]) -> List[Stream]: ), ] - state_manager = ConnectorStateManager(stream_instance_map={s.name: s for s in streams}, state=self._state) + state_manager = ConnectorStateManager(state=self._state) return [ self._to_concurrent( stream, diff --git a/airbyte-integrations/connectors/source-stripe/source_stripe/streams.py b/airbyte-integrations/connectors/source-stripe/source_stripe/streams.py index 5b13588403f22..199fa0135cf6d 100644 --- a/airbyte-integrations/connectors/source-stripe/source_stripe/streams.py +++ b/airbyte-integrations/connectors/source-stripe/source_stripe/streams.py @@ -331,7 +331,10 @@ def request_params( ) -> MutableMapping[str, Any]: params = super().request_params(stream_state=stream_state, stream_slice=stream_slice, next_page_token=next_page_token) if self.event_types: - params["types[]"] = self.event_types + if len(self.event_types) > 1: + params["types[]"] = self.event_types + else: + params["type"] = self.event_types return params def path(self, **kwargs): @@ -608,27 +611,6 @@ def request_params( return params -class Persons(UpdatedCursorIncrementalStripeStream, HttpSubStream): - """ - API docs: https://stripe.com/docs/api/persons/list - """ - - event_types = ["person.created", "person.updated", "person.deleted"] - - def __init__(self, *args, **kwargs): - parent = StripeStream(*args, name="accounts", path="accounts", use_cache=USE_CACHE, **kwargs) - super().__init__(*args, parent=parent, **kwargs) - - def path(self, stream_slice: Mapping[str, Any] = None, **kwargs): - return f"accounts/{stream_slice['parent']['id']}/persons" - - def stream_slices( - self, sync_mode: SyncMode, cursor_field: List[str] = None, stream_state: Mapping[str, Any] = None - ) -> Iterable[Optional[Mapping[str, Any]]]: - parent = HttpSubStream if not stream_state else UpdatedCursorIncrementalStripeStream - yield from parent.stream_slices(self, sync_mode, cursor_field=cursor_field, stream_state=stream_state) - - class StripeSubStream(StripeStream, HttpSubStream): pass @@ -835,3 +817,17 @@ def get_error_handler(self) -> Optional[ErrorHandler]: return ParentIncrementalStripeSubStreamErrorHandler( logger=self.logger, error_mapping=PARENT_INCREMENTAL_STRIPE_SUB_STREAM_ERROR_MAPPING ) + + +class UpdatedCursorIncrementalStripeSubStream(UpdatedCursorIncrementalStripeStream, HttpSubStream): + """ + This class behaves exactly the same as its parent, UpdatedCursorIncrementalStripeStream, but the initial/full refresh sync is performed using the parent stream. + """ + + def stream_slices( + self, sync_mode: SyncMode, cursor_field: List[str] = None, stream_state: Mapping[str, Any] = None + ) -> Iterable[Optional[Mapping[str, Any]]]: + if not stream_state: + yield from HttpSubStream.stream_slices(self, sync_mode, cursor_field, stream_state) + else: + yield from UpdatedCursorIncrementalStripeStream.stream_slices(self, sync_mode, cursor_field, stream_state) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/conftest.py b/airbyte-integrations/connectors/source-stripe/unit_tests/conftest.py index d4691fc3d3cfb..f0bcd0cb9e711 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/conftest.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/conftest.py @@ -13,6 +13,11 @@ os.environ["DEPLOYMENT_MODE"] = "testing" +def pytest_collection_modifyitems(items): + for item in items: + item.add_marker(pytest.mark.timeout(20)) + + @pytest.fixture(name="config") def config_fixture(): config = {"client_secret": "sk_test(live)_", "account_id": "", "start_date": "2020-05-01T00:00:00Z"} diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/config.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/config.py index d048407320d19..9f031974d93bf 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/config.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/config.py @@ -9,7 +9,7 @@ def __init__(self) -> None: self._config: Dict[str, Any] = { "client_secret": "ConfigBuilder default client secret", "account_id": "ConfigBuilder default account id", - "start_date": "2020-05-01T00:00:00Z" + "start_date": "2020-05-01T00:00:00Z", } def with_account_id(self, account_id: str) -> "ConfigBuilder": @@ -21,7 +21,7 @@ def with_client_secret(self, client_secret: str) -> "ConfigBuilder": return self def with_start_date(self, start_datetime: datetime) -> "ConfigBuilder": - self._config["start_date"] = start_datetime.isoformat()[:-13]+"Z" + self._config["start_date"] = start_datetime.isoformat()[:-13] + "Z" return self def with_lookback_window_in_days(self, number_of_days: int) -> "ConfigBuilder": diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/helpers.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/helpers.py index 7f311610af692..4f95359a8ebfe 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/helpers.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/helpers.py @@ -7,7 +7,7 @@ from airbyte_cdk.models import AirbyteStreamStatus -def assert_stream_did_not_run(output, stream_name: str, expected_error_message_pattern: Optional[str]=None): +def assert_stream_did_not_run(output, stream_name: str, expected_error_message_pattern: Optional[str] = None): # right now, no stream status AirbyteStreamStatus.RUNNING means stream not running expected = [ AirbyteStreamStatus.STARTED, @@ -18,10 +18,10 @@ def assert_stream_did_not_run(output, stream_name: str, expected_error_message_p assert output.records == [] if expected_error_message_pattern: + def contains_substring(message, expected_message_pattern): return expected_message_pattern in message.log.message # Use any to check if any message contains the substring found = any(contains_substring(message, expected_error_message_pattern) for message in output.logs) assert found, f"Expected message '{expected_error_message_pattern}' not found in logs." - diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/request_builder.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/request_builder.py index 7a2c8219c5d89..d45ab6e3b5b23 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/request_builder.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/request_builder.py @@ -8,7 +8,6 @@ class StripeRequestBuilder: - @classmethod def accounts_endpoint(cls, account_id: str, client_secret: str) -> "StripeRequestBuilder": return cls("accounts", account_id, client_secret) @@ -50,11 +49,16 @@ def issuing_transactions_endpoint(cls, account_id: str, client_secret: str) -> " return cls("issuing/transactions", account_id, client_secret) @classmethod - def payment_methods_endpoint(cls, account_id: str, client_secret: str) -> "StripeRequestBuilder": - return cls("payment_methods", account_id, client_secret) + def payment_methods_endpoint(cls, customer_id: str, account_id: str, client_secret: str) -> "StripeRequestBuilder": + return cls(f"customers/{customer_id}/payment_methods", account_id, client_secret) @classmethod - def persons_endpoint(cls, parent_account_id: str, account_id: str, client_secret: str, ) -> "StripeRequestBuilder": + def persons_endpoint( + cls, + parent_account_id: str, + account_id: str, + client_secret: str, + ) -> "StripeRequestBuilder": return cls(f"accounts/{parent_account_id}/persons", account_id, client_secret) @classmethod @@ -125,7 +129,10 @@ def build(self) -> HttpRequest: if self._starting_after_id: query_params["starting_after"] = self._starting_after_id if self._types: - query_params["types[]"] = self._types + if len(self._types) > 1: + query_params["types[]"] = self._types + else: + query_params["type"] = self._types if self._object: query_params["object"] = self._object if self._expands: @@ -133,7 +140,9 @@ def build(self) -> HttpRequest: if self._any_query_params: if query_params: - raise ValueError(f"Both `any_query_params` and {list(query_params.keys())} were configured. Provide only one of none but not both.") + raise ValueError( + f"Both `any_query_params` and {list(query_params.keys())} were configured. Provide only one of none but not both." + ) query_params = ANY_QUERY_PARAMS return HttpRequest( diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_accounts.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_accounts.py index db793ae0976b8..35c72a1938748 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_accounts.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_accounts.py @@ -4,6 +4,7 @@ from unittest import TestCase import freezegun +from airbyte_cdk.models import ConfiguredAirbyteCatalog, SyncMode from airbyte_cdk.test.catalog_builder import CatalogBuilder from airbyte_cdk.test.entrypoint_wrapper import read from airbyte_cdk.test.mock_http import HttpMocker @@ -16,7 +17,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import ConfiguredAirbyteCatalog, SyncMode from integration.config import ConfigBuilder from integration.pagination import StripePaginationStrategy from integration.request_builder import StripeRequestBuilder diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_application_fees.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_application_fees.py index 42ad218a4acc1..9e8ca1c2628cb 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_application_fees.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_application_fees.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, AirbyteStateMessage, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder from airbyte_cdk.test.entrypoint_wrapper import EntrypointOutput, read @@ -20,7 +21,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, AirbyteStateMessage, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -71,11 +71,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _an_application_fee() -> RecordBuilder: @@ -89,17 +85,12 @@ def _an_application_fee() -> RecordBuilder: def _application_fees_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_ENDPOINT_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_ENDPOINT_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[List[AirbyteStateMessage]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[List[AirbyteStateMessage]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -108,7 +99,6 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -124,10 +114,18 @@ def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMoc def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( _application_fees_request().with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), - _application_fees_response().with_pagination().with_record(_an_application_fee().with_id("last_record_id_from_first_page")).build(), + _application_fees_response() + .with_pagination() + .with_record(_an_application_fee().with_id("last_record_id_from_first_page")) + .build(), ) http_mocker.get( - _application_fees_request().with_starting_after("last_record_id_from_first_page").with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), + _application_fees_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(_A_START_DATE) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _application_fees_response().with_record(_an_application_fee()).with_record(_an_application_fee()).build(), ) @@ -168,7 +166,11 @@ def test_given_slice_range_when_read_then_perform_multiple_requests(self, http_m _application_fees_response().build(), ) http_mocker.get( - _application_fees_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).build(), + _application_fees_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _application_fees_response().build(), ) @@ -223,19 +225,17 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock _application_fees_request().with_any_query_params().build(), a_response_with_status(500), ) - with patch.object(HttpStatusErrorHandler, 'max_retries', new=0): + with patch.object(HttpStatusErrorHandler, "max_retries", new=0): output = self._read(_config(), expecting_exception=True) # concurrent read processor handles exceptions as config errors after complete the max_retries assert output.errors[-1].trace.error.failure_type == FailureType.config_error - def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> EntrypointOutput: return _read(config, SyncMode.full_refresh, expecting_exception=expecting_exception) @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_application_fees_endpoint(self, http_mocker: HttpMocker) -> None: cursor_value = int(_A_START_DATE.timestamp()) + 1 @@ -255,10 +255,15 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_application_fee().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_application_fee().build())) + .build(), ) output = self._read( @@ -274,16 +279,26 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_application_fee().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_application_fee().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - self._an_application_fee_event() - ).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response().with_record(self._an_application_fee_event()).build(), ) output = self._read( @@ -300,11 +315,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_application_fee_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_application_fee_event()).with_record(self._an_application_fee_event()).build(), ) @@ -316,14 +341,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # application fees endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_application_fee_event()).build(), ) @@ -337,5 +369,7 @@ def test_given_state_earlier_than_30_days_when_read_then_query_events_using_type def _an_application_fee_event(self) -> RecordBuilder: return _an_event().with_field(_DATA_FIELD, _an_application_fee().build()) - def _read(self, config: ConfigBuilder, state: Optional[List[AirbyteStateMessage]], expecting_exception: bool = False) -> EntrypointOutput: + def _read( + self, config: ConfigBuilder, state: Optional[List[AirbyteStateMessage]], expecting_exception: bool = False + ) -> EntrypointOutput: return _read(config, SyncMode.incremental, state, expecting_exception) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_application_fees_refunds.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_application_fees_refunds.py index 4a1a532c4c088..1e8b500ea9886 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_application_fees_refunds.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_application_fees_refunds.py @@ -8,6 +8,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -23,7 +24,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -80,11 +80,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _an_application_fee() -> RecordBuilder: @@ -98,9 +94,7 @@ def _an_application_fee() -> RecordBuilder: def _application_fees_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_APPLICATION_FEES_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_APPLICATION_FEES_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) @@ -115,9 +109,7 @@ def _a_refund() -> RecordBuilder: def _refunds_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_REFUNDS_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_REFUNDS_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) @@ -126,10 +118,7 @@ def _as_dict(response_builder: HttpResponseBuilder) -> Dict[str, Any]: def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -144,20 +133,12 @@ def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMoc _application_fees_request().with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), _application_fees_response() .with_record( - _an_application_fee() - .with_field( - _REFUNDS_FIELD, - _as_dict( - _refunds_response() - .with_record(_a_refund()) - .with_record(_a_refund()) - ) + _an_application_fee().with_field( + _REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund()).with_record(_a_refund())) ) ) - .with_record( - _an_application_fee() - .with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund()))) - ).build(), + .with_record(_an_application_fee().with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund())))) + .build(), ) output = self._read(_config().with_start_date(_A_START_DATE)) @@ -173,14 +154,10 @@ def test_given_multiple_refunds_pages_when_read_then_query_pagination_on_child(s _an_application_fee() .with_id("parent_id") .with_field( - _REFUNDS_FIELD, - _as_dict( - _refunds_response() - .with_pagination() - .with_record(_a_refund().with_id("latest_refund_id")) - ) + _REFUNDS_FIELD, _as_dict(_refunds_response().with_pagination().with_record(_a_refund().with_id("latest_refund_id"))) ) - ).build(), + ) + .build(), ) http_mocker.get( # we do not use slice boundaries here because: @@ -204,28 +181,20 @@ def test_given_multiple_application_fees_pages_when_read_then_query_pagination_o .with_record( _an_application_fee() .with_id("parent_id") - .with_field( - _REFUNDS_FIELD, - _as_dict( - _refunds_response() - .with_record(_a_refund()) - ) - ) - ).build(), + .with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund()))) + ) + .build(), ) http_mocker.get( - _application_fees_request().with_starting_after("parent_id").with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), + _application_fees_request() + .with_starting_after("parent_id") + .with_created_gte(_A_START_DATE) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _application_fees_response() - .with_record( - _an_application_fee() - .with_field( - _REFUNDS_FIELD, - _as_dict( - _refunds_response() - .with_record(_a_refund()) - ) - ) - ).build(), + .with_record(_an_application_fee().with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund())))) + .build(), ) output = self._read(_config().with_start_date(_A_START_DATE)) @@ -251,17 +220,19 @@ def test_given_slice_range_when_read_then_perform_multiple_requests(self, http_m http_mocker.get( _application_fees_request().with_created_gte(start_date).with_created_lte(slice_datetime).with_limit(100).build(), - _application_fees_response().with_record( - _an_application_fee() - .with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund()))) - ).build(), + _application_fees_response() + .with_record(_an_application_fee().with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund())))) + .build(), ) http_mocker.get( - _application_fees_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).build(), - _application_fees_response().with_record( - _an_application_fee() - .with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund()))) - ).build(), + _application_fees_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .build(), + _application_fees_response() + .with_record(_an_application_fee().with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund())))) + .build(), ) output = self._read(_config().with_start_date(start_date).with_slice_range_in_days(slice_range.days)) @@ -279,22 +250,19 @@ def test_given_slice_range_and_refunds_pagination_when_read_then_do_not_slice_ch http_mocker.get( StripeRequestBuilder.application_fees_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), - _application_fees_response().build() + _application_fees_response().build(), ) # catching subsequent slicing request that we don't really care for this test http_mocker.get( _application_fees_request().with_created_gte(start_date).with_created_lte(slice_datetime).with_limit(100).build(), - _application_fees_response().with_record( + _application_fees_response() + .with_record( _an_application_fee() .with_id("parent_id") .with_field( - _REFUNDS_FIELD, - _as_dict( - _refunds_response() - .with_pagination() - .with_record(_a_refund().with_id("latest_refund_id")) - ) + _REFUNDS_FIELD, _as_dict(_refunds_response().with_pagination().with_record(_a_refund().with_id("latest_refund_id"))) ) - ).build(), + ) + .build(), ) http_mocker.get( # slice range is not applied here @@ -322,16 +290,8 @@ def test_given_one_page_when_read_then_cursor_field_is_set(self, http_mocker: Ht http_mocker.get( _application_fees_request().with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), _application_fees_response() - .with_record( - _an_application_fee() - .with_field( - _REFUNDS_FIELD, - _as_dict( - _refunds_response() - .with_record(_a_refund()) - ) - ) - ).build(), + .with_record(_an_application_fee().with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund())))) + .build(), ) output = self._read(_config().with_start_date(_A_START_DATE)) @@ -353,13 +313,9 @@ def test_given_rate_limited_when_read_then_retry_and_return_records(self, http_m _application_fees_request().with_any_query_params().build(), [ a_response_with_status(429), - _application_fees_response().with_record(_an_application_fee().with_field( - _REFUNDS_FIELD, - _as_dict( - _refunds_response() - .with_record(_a_refund()) - ) - )).build(), + _application_fees_response() + .with_record(_an_application_fee().with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund())))) + .build(), ], ) output = self._read(_config().with_start_date(_A_START_DATE)) @@ -372,7 +328,7 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock request, a_response_with_status(500), ) - with patch.object(HttpStatusErrorHandler, 'max_retries', new=0): + with patch.object(HttpStatusErrorHandler, "max_retries", new=0): output = self._read(_config(), expecting_exception=True) # concurrent read processor handles exceptions as config errors after complete the max_retries assert output.errors[-1].trace.error.failure_type == FailureType.config_error @@ -383,16 +339,18 @@ def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> Ent @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_application_fees_endpoint(self, http_mocker: HttpMocker) -> None: cursor_value = int(_A_START_DATE.timestamp()) + 1 http_mocker.get( _application_fees_request().with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), - _application_fees_response().with_record( - _an_application_fee() - .with_field(_REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund().with_cursor(cursor_value)))) - ).build(), + _application_fees_response() + .with_record( + _an_application_fee().with_field( + _REFUNDS_FIELD, _as_dict(_refunds_response().with_record(_a_refund().with_cursor(cursor_value))) + ) + ) + .build(), ) output = self._read(_config().with_start_date(_A_START_DATE), _NO_STATE) @@ -408,10 +366,13 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_refund().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response().with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_refund().build())).build(), ) output = self._read( @@ -427,13 +388,25 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_refund().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_refund().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_refund_event()).build(), ) @@ -451,11 +424,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_refund_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_refund_event()).with_record(self._a_refund_event()).build(), ) @@ -467,14 +450,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # application fees endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_refund_event()).build(), ) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_authorizations.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_authorizations.py index ba613437f65b8..cdb0da90e26a0 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_authorizations.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_authorizations.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -21,7 +22,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, AirbyteStreamState, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -72,11 +72,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _an_authorization() -> RecordBuilder: @@ -90,17 +86,12 @@ def _an_authorization() -> RecordBuilder: def _authorizations_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_ENDPOINT_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_ENDPOINT_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -109,7 +100,6 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -128,7 +118,12 @@ def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpM _authorizations_response().with_pagination().with_record(_an_authorization().with_id("last_record_id_from_first_page")).build(), ) http_mocker.get( - _authorizations_request().with_starting_after("last_record_id_from_first_page").with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), + _authorizations_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(_A_START_DATE) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _authorizations_response().with_record(_an_authorization()).with_record(_an_authorization()).build(), ) @@ -169,7 +164,11 @@ def test_given_slice_range_when_read_then_perform_multiple_requests(self, http_m _authorizations_response().build(), ) http_mocker.get( - _authorizations_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).build(), + _authorizations_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _authorizations_response().build(), ) @@ -222,18 +221,16 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock _authorizations_request().with_any_query_params().build(), a_response_with_status(500), ) - with patch.object(HttpStatusErrorHandler, 'max_retries', new=1): + with patch.object(HttpStatusErrorHandler, "max_retries", new=1): output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error - def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> EntrypointOutput: return _read(config, SyncMode.full_refresh, expecting_exception=expecting_exception) @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_authorizations_endpoint(self, http_mocker: HttpMocker) -> None: cursor_value = int(_A_START_DATE.timestamp()) + 1 @@ -253,10 +250,15 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_authorization().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_authorization().build())) + .build(), ) output = self._read( @@ -272,13 +274,25 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_authorization().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_authorization().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_authorization_event()).build(), ) @@ -296,11 +310,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_authorization_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_authorization_event()).with_record(self._an_authorization_event()).build(), ) @@ -312,14 +336,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # authorizations endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_authorization_event()).build(), ) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_bank_accounts.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_bank_accounts.py index 8498313f4f0b8..bafb8da0bb454 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_bank_accounts.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_bank_accounts.py @@ -8,6 +8,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -23,7 +24,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, AirbyteStreamState, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -84,11 +84,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _a_customer() -> RecordBuilder: @@ -102,9 +98,7 @@ def _a_customer() -> RecordBuilder: def _customers_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_CUSTOMERS_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_CUSTOMERS_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) @@ -118,9 +112,7 @@ def _a_bank_account() -> RecordBuilder: def _bank_accounts_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_BANK_ACCOUNTS_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_BANK_ACCOUNTS_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) @@ -129,10 +121,7 @@ def _as_dict(response_builder: HttpResponseBuilder) -> Dict[str, Any]: def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -147,20 +136,12 @@ def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMoc _customers_request().with_expands(_EXPANDS).with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), _customers_response() .with_record( - _a_customer() - .with_field( - _SOURCES_FIELD, - _as_dict( - _bank_accounts_response() - .with_record(_a_bank_account()) - .with_record(_a_bank_account()) - ) + _a_customer().with_field( + _SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account()).with_record(_a_bank_account())) ) ) - .with_record( - _a_customer() - .with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account()))) - ).build(), + .with_record(_a_customer().with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account())))) + .build(), ) output = self._read(_config().with_start_date(_A_START_DATE)) @@ -172,16 +153,8 @@ def test_given_source_is_not_bank_account_when_read_then_filter_record(self, htt http_mocker.get( _customers_request().with_expands(_EXPANDS).with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), _customers_response() - .with_record( - _a_customer() - .with_field( - _SOURCES_FIELD, - _as_dict( - _bank_accounts_response() - .with_record(_NOT_A_BANK_ACCOUNT) - ) - ) - ).build(), + .with_record(_a_customer().with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_NOT_A_BANK_ACCOUNT)))) + .build(), ) output = self._read(_config().with_start_date(_A_START_DATE)) @@ -198,13 +171,10 @@ def test_given_multiple_bank_accounts_pages_when_read_then_query_pagination_on_c .with_id("parent_id") .with_field( _SOURCES_FIELD, - _as_dict( - _bank_accounts_response() - .with_pagination() - .with_record(_a_bank_account().with_id("latest_bank_account_id")) - ) + _as_dict(_bank_accounts_response().with_pagination().with_record(_a_bank_account().with_id("latest_bank_account_id"))), ) - ).build(), + ) + .build(), ) http_mocker.get( # we do not use slice boundaries here because: @@ -228,28 +198,21 @@ def test_given_multiple_customers_pages_when_read_then_query_pagination_on_paren .with_record( _a_customer() .with_id("parent_id") - .with_field( - _SOURCES_FIELD, - _as_dict( - _bank_accounts_response() - .with_record(_a_bank_account()) - ) - ) - ).build(), + .with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account()))) + ) + .build(), ) http_mocker.get( - _customers_request().with_expands(_EXPANDS).with_starting_after("parent_id").with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), + _customers_request() + .with_expands(_EXPANDS) + .with_starting_after("parent_id") + .with_created_gte(_A_START_DATE) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _customers_response() - .with_record( - _a_customer() - .with_field( - _SOURCES_FIELD, - _as_dict( - _bank_accounts_response() - .with_record(_a_bank_account()) - ) - ) - ).build(), + .with_record(_a_customer().with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account())))) + .build(), ) output = self._read(_config().with_start_date(_A_START_DATE)) @@ -274,18 +237,26 @@ def test_given_slice_range_when_read_then_perform_multiple_requests(self, http_m slice_datetime = start_date + slice_range http_mocker.get( - _customers_request().with_expands(_EXPANDS).with_created_gte(start_date).with_created_lte(slice_datetime).with_limit(100).build(), - _customers_response().with_record( - _a_customer() - .with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account()))) - ).build(), + _customers_request() + .with_expands(_EXPANDS) + .with_created_gte(start_date) + .with_created_lte(slice_datetime) + .with_limit(100) + .build(), + _customers_response() + .with_record(_a_customer().with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account())))) + .build(), ) http_mocker.get( - _customers_request().with_expands(_EXPANDS).with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).build(), - _customers_response().with_record( - _a_customer() - .with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account()))) - ).build(), + _customers_request() + .with_expands(_EXPANDS) + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .build(), + _customers_response() + .with_record(_a_customer().with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account())))) + .build(), ) output = self._read(_config().with_start_date(start_date).with_slice_range_in_days(slice_range.days)) @@ -303,22 +274,25 @@ def test_given_slice_range_and_bank_accounts_pagination_when_read_then_do_not_sl http_mocker.get( StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), - _customers_response().build() + _customers_response().build(), ) # catching subsequent slicing request that we don't really care for this test http_mocker.get( - _customers_request().with_expands(_EXPANDS).with_created_gte(start_date).with_created_lte(slice_datetime).with_limit(100).build(), - _customers_response().with_record( + _customers_request() + .with_expands(_EXPANDS) + .with_created_gte(start_date) + .with_created_lte(slice_datetime) + .with_limit(100) + .build(), + _customers_response() + .with_record( _a_customer() .with_id("parent_id") .with_field( _SOURCES_FIELD, - _as_dict( - _bank_accounts_response() - .with_pagination() - .with_record(_a_bank_account().with_id("latest_bank_account_id")) - ) + _as_dict(_bank_accounts_response().with_pagination().with_record(_a_bank_account().with_id("latest_bank_account_id"))), ) - ).build(), + ) + .build(), ) http_mocker.get( # slice range is not applied here @@ -346,16 +320,8 @@ def test_given_one_page_when_read_then_cursor_field_is_set(self, http_mocker: Ht http_mocker.get( _customers_request().with_expands(_EXPANDS).with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), _customers_response() - .with_record( - _a_customer() - .with_field( - _SOURCES_FIELD, - _as_dict( - _bank_accounts_response() - .with_record(_a_bank_account()) - ) - ) - ).build(), + .with_record(_a_customer().with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account())))) + .build(), ) output = self._read(_config().with_start_date(_A_START_DATE)) @@ -377,13 +343,9 @@ def test_given_rate_limited_when_read_then_retry_and_return_records(self, http_m _customers_request().with_any_query_params().build(), [ a_response_with_status(429), - _customers_response().with_record(_a_customer().with_field( - _SOURCES_FIELD, - _as_dict( - _bank_accounts_response() - .with_record(_a_bank_account()) - ) - )).build(), + _customers_response() + .with_record(_a_customer().with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account())))) + .build(), ], ) output = self._read(_config().with_start_date(_A_START_DATE)) @@ -396,7 +358,7 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock request, a_response_with_status(500), ) - with patch.object(HttpStatusErrorHandler, 'max_retries', new=1): + with patch.object(HttpStatusErrorHandler, "max_retries", new=1): output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error @@ -406,17 +368,15 @@ def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> Ent @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_and_successful_sync_when_read_then_set_state_to_now(self, http_mocker: HttpMocker) -> None: # If stripe takes some time to ingest the data, we should recommend to use a lookback window when syncing the bank_accounts stream # to make sure that we don't lose data between the first and the second sync http_mocker.get( _customers_request().with_expands(_EXPANDS).with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), - _customers_response().with_record( - _a_customer() - .with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account()))) - ).build(), + _customers_response() + .with_record(_a_customer().with_field(_SOURCES_FIELD, _as_dict(_bank_accounts_response().with_record(_a_bank_account())))) + .build(), ) output = self._read(_config().with_start_date(_A_START_DATE), _NO_STATE) @@ -432,10 +392,15 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_bank_account().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_bank_account().build())) + .build(), ) output = self._read( @@ -451,13 +416,25 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_bank_account().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_bank_account().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_bank_account_event()).build(), ) @@ -475,11 +452,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_bank_account_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_bank_account_event()).with_record(self._a_bank_account_event()).build(), ) @@ -491,14 +478,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # customer endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_bank_account_event()).build(), ) @@ -513,10 +507,13 @@ def test_given_state_earlier_than_30_days_when_read_then_query_events_using_type def test_given_source_is_not_bank_account_when_read_then_filter_record(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_field(_DATA_FIELD, _NOT_A_BANK_ACCOUNT.build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response().with_record(_an_event().with_field(_DATA_FIELD, _NOT_A_BANK_ACCOUNT.build())).build(), ) output = self._read( diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_cards.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_cards.py index 410bbb5cddd11..660564ea96207 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_cards.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_cards.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -21,7 +22,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, AirbyteStreamState, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -72,11 +72,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _a_card() -> RecordBuilder: @@ -90,17 +86,12 @@ def _a_card() -> RecordBuilder: def _cards_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_ENDPOINT_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_ENDPOINT_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -109,7 +100,6 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -128,7 +118,12 @@ def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpM _cards_response().with_pagination().with_record(_a_card().with_id("last_record_id_from_first_page")).build(), ) http_mocker.get( - _cards_request().with_starting_after("last_record_id_from_first_page").with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), + _cards_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(_A_START_DATE) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _cards_response().with_record(_a_card()).with_record(_a_card()).build(), ) @@ -169,7 +164,11 @@ def test_given_slice_range_when_read_then_perform_multiple_requests(self, http_m _cards_response().build(), ) http_mocker.get( - _cards_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).build(), + _cards_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _cards_response().build(), ) @@ -222,16 +221,16 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock _cards_request().with_any_query_params().build(), a_response_with_status(500), ) - with patch.object(HttpStatusErrorHandler, 'max_retries', new=1): + with patch.object(HttpStatusErrorHandler, "max_retries", new=1): output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> EntrypointOutput: return _read(config, SyncMode.full_refresh, expecting_exception=expecting_exception) + @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_cards_endpoint(self, http_mocker: HttpMocker) -> None: cursor_value = int(_A_START_DATE.timestamp()) + 1 @@ -251,10 +250,13 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_card().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response().with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_card().build())).build(), ) output = self._read( @@ -270,13 +272,25 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_card().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_card().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_card_event()).build(), ) @@ -294,11 +308,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_card_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_card_event()).with_record(self._a_card_event()).build(), ) @@ -310,14 +334,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # cards endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_card_event()).build(), ) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_early_fraud_warnings.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_early_fraud_warnings.py index 541d3c3b64d56..b64ba61d6db85 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_early_fraud_warnings.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_early_fraud_warnings.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -21,7 +22,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -72,11 +72,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _an_early_fraud_warning() -> RecordBuilder: @@ -90,17 +86,12 @@ def _an_early_fraud_warning() -> RecordBuilder: def _early_fraud_warnings_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_ENDPOINT_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_ENDPOINT_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -109,7 +100,6 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -125,7 +115,10 @@ def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMoc def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( _early_fraud_warnings_request().with_limit(100).build(), - _early_fraud_warnings_response().with_pagination().with_record(_an_early_fraud_warning().with_id("last_record_id_from_first_page")).build(), + _early_fraud_warnings_response() + .with_pagination() + .with_record(_an_early_fraud_warning().with_id("last_record_id_from_first_page")) + .build(), ) http_mocker.get( _early_fraud_warnings_request().with_starting_after("last_record_id_from_first_page").with_limit(100).build(), @@ -192,18 +185,16 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock _early_fraud_warnings_request().with_any_query_params().build(), a_response_with_status(500), ) - with patch.object(HttpStatusErrorHandler, 'max_retries', new=1): + with patch.object(HttpStatusErrorHandler, "max_retries", new=1): output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error - def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> EntrypointOutput: return _read(config, SyncMode.full_refresh, expecting_exception=expecting_exception) @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_early_fraud_warnings_endpoint(self, http_mocker: HttpMocker) -> None: cursor_value = int(_A_START_DATE.timestamp()) + 1 @@ -223,10 +214,15 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_early_fraud_warning().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_early_fraud_warning().build())) + .build(), ) output = self._read( @@ -242,13 +238,25 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_early_fraud_warning().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_early_fraud_warning().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_early_fraud_warning_event()).build(), ) @@ -266,11 +274,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_early_fraud_warning_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_early_fraud_warning_event()).with_record(self._an_early_fraud_warning_event()).build(), ) @@ -282,14 +300,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # radar/early_fraud_warnings endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_early_fraud_warning_event()).build(), ) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_events.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_events.py index 739a029063a87..87c5494b755e2 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_events.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_events.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -20,7 +21,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -69,10 +69,7 @@ def _a_response() -> HttpResponseBuilder: def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -81,7 +78,6 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -98,14 +94,21 @@ def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpM _a_response().with_pagination().with_record(_a_record().with_id("last_record_id_from_first_page")).build(), ) http_mocker.get( - _a_request().with_starting_after("last_record_id_from_first_page").with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), + _a_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(_A_START_DATE) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _a_response().with_record(_a_record()).with_record(_a_record()).build(), ) output = self._read(_config().with_start_date(_A_START_DATE)) assert len(output.records) == 3 @HttpMocker() - def test_given_start_date_before_30_days_stripe_limit_and_slice_range_when_read_then_perform_request_before_30_days(self, http_mocker: HttpMocker) -> None: + def test_given_start_date_before_30_days_stripe_limit_and_slice_range_when_read_then_perform_request_before_30_days( + self, http_mocker: HttpMocker + ) -> None: """ This case is special because the source queries for a time range that is before 30 days. That being said as of 2023-12-13, the API mentions that "We only guarantee access to events through the Retrieve Event API for 30 days." (see @@ -119,7 +122,11 @@ def test_given_start_date_before_30_days_stripe_limit_and_slice_range_when_read_ _a_response().build(), ) http_mocker.get( - _a_request().with_created_gte(slice_datetime + _SECOND_REQUEST).with_created_lte(slice_datetime + slice_range + _SECOND_REQUEST).with_limit(100).build(), + _a_request() + .with_created_gte(slice_datetime + _SECOND_REQUEST) + .with_created_lte(slice_datetime + slice_range + _SECOND_REQUEST) + .with_limit(100) + .build(), _a_response().build(), ) http_mocker.get( @@ -205,7 +212,7 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock _a_request().with_any_query_params().build(), a_response_with_status(500), ) - with patch.object(HttpStatusErrorHandler, 'max_retries', new=0): + with patch.object(HttpStatusErrorHandler, "max_retries", new=0): output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error @@ -225,7 +232,6 @@ def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> Ent @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_initial_state_when_read_then_return_state_based_on_cursor_field(self, http_mocker: HttpMocker) -> None: cursor_value = int(_A_START_DATE.timestamp()) + 1 @@ -248,7 +254,7 @@ def test_given_state_when_read_then_use_state_for_query_params(self, http_mocker self._read( _config().with_start_date(_A_START_DATE), - StateBuilder().with_stream_state("events", {"created": int(state_value.timestamp())}).build() + StateBuilder().with_stream_state("events", {"created": int(state_value.timestamp())}).build(), ) # request matched http_mocker @@ -263,7 +269,7 @@ def test_given_state_more_recent_than_cursor_when_read_then_return_state_based_o output = self._read( _config().with_start_date(_A_START_DATE), - StateBuilder().with_stream_state("events", {"created": very_recent_cursor_state}).build() + StateBuilder().with_stream_state("events", {"created": very_recent_cursor_state}).build(), ) most_recent_state = output.most_recent_state diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_external_account_bank_accounts.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_external_account_bank_accounts.py index 690d986978f1b..c9f7142af0598 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_external_account_bank_accounts.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_external_account_bank_accounts.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -21,7 +22,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -73,11 +73,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _an_external_bank_account() -> RecordBuilder: @@ -90,17 +86,12 @@ def _an_external_bank_account() -> RecordBuilder: def _external_bank_accounts_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_ENDPOINT_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_ENDPOINT_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -109,7 +100,6 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -125,7 +115,10 @@ def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMoc def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( _external_accounts_request().with_object(_OBJECT).with_limit(100).build(), - _external_bank_accounts_response().with_pagination().with_record(_an_external_bank_account().with_id("last_record_id_from_first_page")).build(), + _external_bank_accounts_response() + .with_pagination() + .with_record(_an_external_bank_account().with_id("last_record_id_from_first_page")) + .build(), ) http_mocker.get( _external_accounts_request().with_starting_after("last_record_id_from_first_page").with_object(_OBJECT).with_limit(100).build(), @@ -192,18 +185,16 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock _external_accounts_request().with_any_query_params().build(), a_response_with_status(500), ) - with patch.object(HttpStatusErrorHandler, 'max_retries', new =0): + with patch.object(HttpStatusErrorHandler, "max_retries", new=0): output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error - def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> EntrypointOutput: return _read(config, SyncMode.full_refresh, expecting_exception=expecting_exception) @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_external_accounts_endpoint(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -222,10 +213,15 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_external_bank_account().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_external_bank_account().build())) + .build(), ) output = self._read( @@ -244,9 +240,7 @@ def test_given_object_is_not_back_account_when_read_then_filter_out(self, http_m http_mocker.get( StripeRequestBuilder.events_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), - _events_response().with_record( - _an_event().with_field(_DATA_FIELD, {"object": "not a bank account"}) - ).build(), + _events_response().with_record(_an_event().with_field(_DATA_FIELD, {"object": "not a bank account"})).build(), ) output = self._read( @@ -260,13 +254,25 @@ def test_given_object_is_not_back_account_when_read_then_filter_out(self, http_m def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_external_bank_account().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_external_bank_account().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_external_account_event()).build(), ) @@ -284,11 +290,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_external_account_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_external_account_event()).with_record(self._an_external_account_event()).build(), ) @@ -300,14 +316,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # external_accounts endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_external_account_event()).build(), ) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_external_account_cards.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_external_account_cards.py index fec44f5642601..918cab91a40d8 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_external_account_cards.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_external_account_cards.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -21,7 +22,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -73,11 +73,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _an_external_account_card() -> RecordBuilder: @@ -95,17 +91,12 @@ def _external_accounts_card_response() -> HttpResponseBuilder: tests, we will leave it as is for now. """ return create_response_builder( - find_template(_ENDPOINT_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_ENDPOINT_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -114,7 +105,6 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -130,7 +120,10 @@ def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMoc def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( _external_accounts_request().with_object(_OBJECT).with_limit(100).build(), - _external_accounts_card_response().with_pagination().with_record(_an_external_account_card().with_id("last_record_id_from_first_page")).build(), + _external_accounts_card_response() + .with_pagination() + .with_record(_an_external_account_card().with_id("last_record_id_from_first_page")) + .build(), ) http_mocker.get( _external_accounts_request().with_starting_after("last_record_id_from_first_page").with_object(_OBJECT).with_limit(100).build(), @@ -201,14 +194,12 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error - def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> EntrypointOutput: return _read(config, SyncMode.full_refresh, expecting_exception=expecting_exception) @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_external_accounts_endpoint(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -227,10 +218,15 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_external_account_card().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _an_external_account_card().build())) + .build(), ) output = self._read( @@ -249,9 +245,7 @@ def test_given_object_is_not_back_account_when_read_then_filter_out(self, http_m http_mocker.get( StripeRequestBuilder.events_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), - _events_response().with_record( - _an_event().with_field(_DATA_FIELD, {"object": "not a card"}) - ).build(), + _events_response().with_record(_an_event().with_field(_DATA_FIELD, {"object": "not a card"})).build(), ) output = self._read( @@ -265,13 +259,25 @@ def test_given_object_is_not_back_account_when_read_then_filter_out(self, http_m def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_external_account_card().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _an_external_account_card().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_external_account_event()).build(), ) @@ -289,11 +295,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_external_account_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_external_account_event()).with_record(self._an_external_account_event()).build(), ) @@ -305,14 +321,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # external_accounts endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._an_external_account_event()).build(), ) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_payment_methods.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_payment_methods.py index 7fecd4ac31373..f41f2efbbbf5c 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_payment_methods.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_payment_methods.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -21,20 +22,15 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy from integration.request_builder import StripeRequestBuilder from integration.response_builder import a_response_with_status +from integration.test_bank_accounts import _a_customer, _customers_response from source_stripe import SourceStripe -_EVENT_TYPES = [ - "payment_method.attached", - "payment_method.automatically_updated", - "payment_method.detached", - "payment_method.updated", -] +_EVENT_TYPES = ["payment_method.*"] _DATA_FIELD = NestedPath(["data", "object"]) _STREAM_NAME = "payment_methods" @@ -47,8 +43,8 @@ _AVOIDING_INCLUSIVE_BOUNDARIES = timedelta(seconds=1) -def _payment_methods_request() -> StripeRequestBuilder: - return StripeRequestBuilder.payment_methods_endpoint(_ACCOUNT_ID, _CLIENT_SECRET) +def _payment_methods_request(customer_id: str) -> StripeRequestBuilder: + return StripeRequestBuilder.payment_methods_endpoint(customer_id, _ACCOUNT_ID, _CLIENT_SECRET) def _events_request() -> StripeRequestBuilder: @@ -77,11 +73,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _a_payment_method() -> RecordBuilder: @@ -95,17 +87,12 @@ def _a_payment_method() -> RecordBuilder: def _payment_methods_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_ENDPOINT_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_ENDPOINT_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -114,11 +101,19 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( - _payment_methods_request().with_limit(100).build(), + StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), + _customers_response() + .with_record( + _a_customer() + .with_id("parent_id") + ) + .build(), + ) + http_mocker.get( + _payment_methods_request("parent_id").with_limit(100).build(), _payment_methods_response().with_record(_a_payment_method()).with_record(_a_payment_method()).build(), ) @@ -127,13 +122,25 @@ def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMoc assert len(output.records) == 2 @HttpMocker() - def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: + def test_given_two_pages_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: + http_mocker.get( + StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), + _customers_response() + .with_record( + _a_customer() + .with_id("parent_id") + ) + .build(), + ) http_mocker.get( - _payment_methods_request().with_limit(100).build(), - _payment_methods_response().with_pagination().with_record(_a_payment_method().with_id("last_record_id_from_first_page")).build(), + _payment_methods_request("parent_id").with_limit(100).build(), + _payment_methods_response() + .with_pagination() + .with_record(_a_payment_method().with_id("last_record_id_from_first_page")) + .build(), ) http_mocker.get( - _payment_methods_request().with_starting_after("last_record_id_from_first_page").with_limit(100).build(), + _payment_methods_request("parent_id").with_starting_after("last_record_id_from_first_page").with_limit(100).build(), _payment_methods_response().with_record(_a_payment_method()).with_record(_a_payment_method()).build(), ) @@ -144,7 +151,16 @@ def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpM @HttpMocker() def test_when_read_then_add_cursor_field(self, http_mocker: HttpMocker) -> None: http_mocker.get( - _payment_methods_request().with_limit(100).build(), + StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), + _customers_response() + .with_record( + _a_customer() + .with_id("parent_id") + ) + .build(), + ) + http_mocker.get( + _payment_methods_request("parent_id").with_limit(100).build(), _payment_methods_response().with_record(_a_payment_method()).build(), ) @@ -155,7 +171,16 @@ def test_when_read_then_add_cursor_field(self, http_mocker: HttpMocker) -> None: @HttpMocker() def test_given_http_status_400_when_read_then_stream_did_not_run(self, http_mocker: HttpMocker) -> None: http_mocker.get( - _payment_methods_request().with_any_query_params().build(), + StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), + _customers_response() + .with_record( + _a_customer() + .with_id("parent_id") + ) + .build(), + ) + http_mocker.get( + _payment_methods_request("parent_id").with_any_query_params().build(), a_response_with_status(400), ) output = self._read(_config()) @@ -164,7 +189,16 @@ def test_given_http_status_400_when_read_then_stream_did_not_run(self, http_mock @HttpMocker() def test_given_http_status_401_when_read_then_config_error(self, http_mocker: HttpMocker) -> None: http_mocker.get( - _payment_methods_request().with_any_query_params().build(), + StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), + _customers_response() + .with_record( + _a_customer() + .with_id("parent_id") + ) + .build(), + ) + http_mocker.get( + _payment_methods_request("parent_id").with_any_query_params().build(), a_response_with_status(401), ) output = self._read(_config(), expecting_exception=True) @@ -173,7 +207,16 @@ def test_given_http_status_401_when_read_then_config_error(self, http_mocker: Ht @HttpMocker() def test_given_rate_limited_when_read_then_retry_and_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( - _payment_methods_request().with_any_query_params().build(), + StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), + _customers_response() + .with_record( + _a_customer() + .with_id("parent_id") + ) + .build(), + ) + http_mocker.get( + _payment_methods_request("parent_id").with_any_query_params().build(), [ a_response_with_status(429), _payment_methods_response().with_record(_a_payment_method()).build(), @@ -185,7 +228,16 @@ def test_given_rate_limited_when_read_then_retry_and_return_records(self, http_m @HttpMocker() def test_given_http_status_500_once_before_200_when_read_then_retry_and_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( - _payment_methods_request().with_any_query_params().build(), + StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), + _customers_response() + .with_record( + _a_customer() + .with_id("parent_id") + ) + .build(), + ) + http_mocker.get( + _payment_methods_request("parent_id").with_any_query_params().build(), [a_response_with_status(500), _payment_methods_response().with_record(_a_payment_method()).build()], ) output = self._read(_config()) @@ -194,26 +246,42 @@ def test_given_http_status_500_once_before_200_when_read_then_retry_and_return_r @HttpMocker() def test_given_http_status_500_when_read_then_raise_config_error(self, http_mocker: HttpMocker) -> None: http_mocker.get( - _payment_methods_request().with_any_query_params().build(), + StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), + _customers_response() + .with_record( + _a_customer() + .with_id("parent_id") + ) + .build(), + ) + http_mocker.get( + _payment_methods_request("parent_id").with_any_query_params().build(), a_response_with_status(500), ) - with patch.object(HttpStatusErrorHandler, 'max_retries', new=0): + with patch.object(HttpStatusErrorHandler, "max_retries", new=0): output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error - def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> EntrypointOutput: return _read(config, SyncMode.full_refresh, expecting_exception=expecting_exception) @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_payment_methods_endpoint(self, http_mocker: HttpMocker) -> None: + http_mocker.get( + StripeRequestBuilder.customers_endpoint(_ACCOUNT_ID, _CLIENT_SECRET).with_any_query_params().build(), + _customers_response() + .with_record( + _a_customer() + .with_id("parent_id") + ) + .build(), + ) cursor_value = int(_A_START_DATE.timestamp()) + 1 http_mocker.get( - _payment_methods_request().with_limit(100).build(), + _payment_methods_request("parent_id").with_limit(100).build(), _payment_methods_response().with_record(_a_payment_method().with_cursor(cursor_value)).build(), ) output = self._read(_config().with_start_date(_A_START_DATE), _NO_STATE) @@ -228,10 +296,15 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_payment_method().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_payment_method().build())) + .build(), ) output = self._read( @@ -247,13 +320,25 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_payment_method().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_payment_method().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_payment_method_event()).build(), ) @@ -271,11 +356,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_payment_method_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_payment_method_event()).with_record(self._a_payment_method_event()).build(), ) @@ -287,14 +382,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # payment_methods endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_payment_method_event()).build(), ) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_persons.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_persons.py index c309663427659..7779b39bcd03f 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_persons.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_persons.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, AirbyteStreamStatus, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder from airbyte_cdk.test.entrypoint_wrapper import read @@ -20,7 +21,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, AirbyteStreamStatus, FailureType, Level, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -64,16 +64,13 @@ def _create_response() -> HttpResponseBuilder: return create_response_builder( response_template=find_template("accounts", __file__), records_path=FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + pagination_strategy=StripePaginationStrategy(), ) def _create_record(resource: str) -> RecordBuilder: return create_record_builder( - find_template(resource, __file__), - FieldPath("data"), - record_id_path=FieldPath("id"), - record_cursor_path=FieldPath("created") + find_template(resource, __file__), FieldPath("data"), record_id_path=FieldPath("id"), record_cursor_path=FieldPath("created") ) @@ -86,18 +83,19 @@ def _create_persons_event_record(event_type: str) -> RecordBuilder: ) person_record = create_record_builder( - find_template("persons", __file__), - FieldPath("data"), - record_id_path=FieldPath("id"), - record_cursor_path=FieldPath("created") + find_template("persons", __file__), FieldPath("data"), record_id_path=FieldPath("id"), record_cursor_path=FieldPath("created") ) return event_record.with_field(NestedPath(["data", "object"]), person_record.build()).with_field(NestedPath(["type"]), event_type) def emits_successful_sync_status_messages(status_messages: List[AirbyteStreamStatus]) -> bool: - return (len(status_messages) == 3 and status_messages[0] == AirbyteStreamStatus.STARTED - and status_messages[1] == AirbyteStreamStatus.RUNNING and status_messages[2] == AirbyteStreamStatus.COMPLETE) + return ( + len(status_messages) == 3 + and status_messages[0] == AirbyteStreamStatus.STARTED + and status_messages[1] == AirbyteStreamStatus.RUNNING + and status_messages[2] == AirbyteStreamStatus.COMPLETE + ) @freezegun.freeze_time(_NOW.isoformat()) @@ -157,14 +155,17 @@ def test_substream_pagination(self, http_mocker): # Persons stream first page request http_mocker.get( _create_persons_request().with_limit(100).build(), - _create_response().with_record(record=_create_record("persons")).with_record(record=_create_record("persons").with_id("last_page_record_id")).with_pagination().build(), + _create_response() + .with_record(record=_create_record("persons")) + .with_record(record=_create_record("persons").with_id("last_page_record_id")) + .with_pagination() + .build(), ) # Persons stream second page request http_mocker.get( _create_persons_request().with_limit(100).with_starting_after("last_page_record_id").build(), - _create_response().with_record(record=_create_record("persons")).with_record( - record=_create_record("persons")).build(), + _create_response().with_record(record=_create_record("persons")).with_record(record=_create_record("persons")).build(), ) source = SourceStripe(config=_CONFIG, catalog=_create_catalog(), state=_NO_STATE) @@ -259,8 +260,12 @@ def test_incremental_with_recent_state(self, http_mocker: HttpMocker): cursor_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES http_mocker.get( - _create_events_request().with_created_gte(cursor_datetime).with_created_lte(_NOW).with_limit(100).with_types( - ["person.created", "person.updated", "person.deleted"]).build(), + _create_events_request() + .with_created_gte(cursor_datetime) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(["person.created", "person.updated", "person.deleted"]) + .build(), _create_response().with_record(record=_create_persons_event_record(event_type="person.created")).build(), ) @@ -285,8 +290,12 @@ def test_incremental_with_deleted_event(self, http_mocker: HttpMocker): cursor_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES http_mocker.get( - _create_events_request().with_created_gte(cursor_datetime).with_created_lte(_NOW).with_limit(100).with_types( - ["person.created", "person.updated", "person.deleted"]).build(), + _create_events_request() + .with_created_gte(cursor_datetime) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(["person.created", "person.updated", "person.deleted"]) + .build(), _create_response().with_record(record=_create_persons_event_record(event_type="person.deleted")).build(), ) @@ -313,8 +322,12 @@ def test_incremental_with_newer_start_date(self, http_mocker): config = _create_config().with_start_date(start_datetime).build() http_mocker.get( - _create_events_request().with_created_gte(start_datetime).with_created_lte(_NOW).with_limit(100).with_types( - ["person.created", "person.updated", "person.deleted"]).build(), + _create_events_request() + .with_created_gte(start_datetime) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(["person.created", "person.updated", "person.deleted"]) + .build(), _create_response().with_record(record=_create_persons_event_record(event_type="person.created")).build(), ) @@ -366,7 +379,7 @@ def test_rate_limited_substream_persons(self, http_mocker: HttpMocker) -> None: [ a_response_with_status(429), _create_response().with_record(record=_create_record("persons")).with_record(record=_create_record("persons")).build(), - ] + ], ) source = SourceStripe(config=_CONFIG, catalog=_create_catalog(), state=_NO_STATE) @@ -381,12 +394,16 @@ def test_rate_limited_incremental_events(self, http_mocker: HttpMocker) -> None: cursor_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES http_mocker.get( - _create_events_request().with_created_gte(cursor_datetime).with_created_lte(_NOW).with_limit(100).with_types( - ["person.created", "person.updated", "person.deleted"]).build(), + _create_events_request() + .with_created_gte(cursor_datetime) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(["person.created", "person.updated", "person.deleted"]) + .build(), [ a_response_with_status(429), _create_response().with_record(record=_create_persons_event_record(event_type="person.created")).build(), - ] + ], ) state = StateBuilder().with_stream_state(_STREAM_NAME, {"updated": int(state_datetime.timestamp())}).build() @@ -413,7 +430,7 @@ def test_rate_limit_max_attempts_exceeded(self, http_mocker: HttpMocker) -> None http_mocker.get( _create_persons_request().with_limit(100).build(), - a_response_with_status(429), # Returns 429 on all subsequent requests to test the maximum number of retries + a_response_with_status(429), # Returns 429 on all subsequent requests to test the maximum number of retries ) with patch.object(HttpStatusErrorHandler, "max_retries", new=0): @@ -421,7 +438,10 @@ def test_rate_limit_max_attempts_exceeded(self, http_mocker: HttpMocker) -> None actual_messages = read(source, config=_CONFIG, catalog=_create_catalog()) # first error is the actual error, second is to break the Python app with code != 0 - assert list(map(lambda message: message.trace.error.failure_type, actual_messages.errors)) == [FailureType.system_error, FailureType.config_error] + assert list(map(lambda message: message.trace.error.failure_type, actual_messages.errors)) == [ + FailureType.system_error, + FailureType.config_error, + ] assert "Request rate limit exceeded" in actual_messages.errors[0].trace.error.internal_message @HttpMocker() @@ -430,8 +450,12 @@ def test_incremental_rate_limit_max_attempts_exceeded(self, http_mocker: HttpMoc cursor_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES http_mocker.get( - _create_events_request().with_created_gte(cursor_datetime).with_created_lte(_NOW).with_limit(100).with_types( - ["person.created", "person.updated", "person.deleted"]).build(), + _create_events_request() + .with_created_gte(cursor_datetime) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(["person.created", "person.updated", "person.deleted"]) + .build(), a_response_with_status(429), # Returns 429 on all subsequent requests to test the maximum number of retries ) @@ -463,7 +487,6 @@ def test_server_error_parent_stream_accounts(self, http_mocker: HttpMocker) -> N _create_response().with_record(record=_create_record("persons")).with_record(record=_create_record("persons")).build(), ) - source = SourceStripe(config=_CONFIG, catalog=_create_catalog(), state=_NO_STATE) actual_messages = read(source, config=_CONFIG, catalog=_create_catalog()) @@ -482,10 +505,9 @@ def test_server_error_substream_persons(self, http_mocker: HttpMocker) -> None: [ a_response_with_status(500), _create_response().with_record(record=_create_record("persons")).with_record(record=_create_record("persons")).build(), - ] + ], ) - source = SourceStripe(config=_CONFIG, catalog=_create_catalog(), state=_NO_STATE) actual_messages = read(source, config=_CONFIG, catalog=_create_catalog()) @@ -494,14 +516,14 @@ def test_server_error_substream_persons(self, http_mocker: HttpMocker) -> None: @HttpMocker() def test_server_error_max_attempts_exceeded(self, http_mocker: HttpMocker) -> None: - http_mocker.get( - _create_accounts_request().with_limit(100).build(), - a_response_with_status(500) - ) + http_mocker.get(_create_accounts_request().with_limit(100).build(), a_response_with_status(500)) with patch.object(HttpStatusErrorHandler, "max_retries", new=0): source = SourceStripe(config=_CONFIG, catalog=_create_catalog(), state=_NO_STATE) actual_messages = read(source, config=_CONFIG, catalog=_create_catalog()) # first error is the actual error, second is to break the Python app with code != 0 - assert list(map(lambda message: message.trace.error.failure_type, actual_messages.errors)) == [FailureType.system_error, FailureType.config_error] + assert list(map(lambda message: message.trace.error.failure_type, actual_messages.errors)) == [ + FailureType.system_error, + FailureType.config_error, + ] diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_reviews.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_reviews.py index 425120bc5bce6..13da98982181c 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_reviews.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_reviews.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -21,7 +22,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -72,11 +72,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _a_review() -> RecordBuilder: @@ -90,17 +86,12 @@ def _a_review() -> RecordBuilder: def _reviews_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_ENDPOINT_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_ENDPOINT_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -109,7 +100,6 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -128,7 +118,12 @@ def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpM _reviews_response().with_pagination().with_record(_a_review().with_id("last_record_id_from_first_page")).build(), ) http_mocker.get( - _reviews_request().with_starting_after("last_record_id_from_first_page").with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), + _reviews_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(_A_START_DATE) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _reviews_response().with_record(_a_review()).with_record(_a_review()).build(), ) @@ -169,7 +164,11 @@ def test_given_slice_range_when_read_then_perform_multiple_requests(self, http_m _reviews_response().build(), ) http_mocker.get( - _reviews_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).build(), + _reviews_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _reviews_response().build(), ) @@ -226,14 +225,12 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error - def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> EntrypointOutput: return _read(config, SyncMode.full_refresh, expecting_exception=expecting_exception) @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_reviews_endpoint(self, http_mocker: HttpMocker) -> None: cursor_value = int(_A_START_DATE.timestamp()) + 1 @@ -253,10 +250,13 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_review().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response().with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_review().build())).build(), ) output = self._read( @@ -272,13 +272,25 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_review().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_review().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_review_event()).build(), ) @@ -296,11 +308,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_review_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_review_event()).with_record(self._a_review_event()).build(), ) @@ -312,14 +334,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # reviews endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_review_event()).build(), ) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_transactions.py b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_transactions.py index 2ffaab5668b41..cf5b850124d0b 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_transactions.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/integration/test_transactions.py @@ -6,6 +6,7 @@ from unittest.mock import patch import freezegun +from airbyte_cdk.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from airbyte_cdk.sources.source import TState from airbyte_cdk.sources.streams.http.error_handlers.http_status_error_handler import HttpStatusErrorHandler from airbyte_cdk.test.catalog_builder import CatalogBuilder @@ -21,7 +22,6 @@ find_template, ) from airbyte_cdk.test.state_builder import StateBuilder -from airbyte_protocol.models import AirbyteStateBlob, ConfiguredAirbyteCatalog, FailureType, StreamDescriptor, SyncMode from integration.config import ConfigBuilder from integration.helpers import assert_stream_did_not_run from integration.pagination import StripePaginationStrategy @@ -72,11 +72,7 @@ def _an_event() -> RecordBuilder: def _events_response() -> HttpResponseBuilder: - return create_response_builder( - find_template("events", __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() - ) + return create_response_builder(find_template("events", __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy()) def _a_transaction() -> RecordBuilder: @@ -90,17 +86,12 @@ def _a_transaction() -> RecordBuilder: def _transactions_response() -> HttpResponseBuilder: return create_response_builder( - find_template(_ENDPOINT_TEMPLATE_NAME, __file__), - FieldPath("data"), - pagination_strategy=StripePaginationStrategy() + find_template(_ENDPOINT_TEMPLATE_NAME, __file__), FieldPath("data"), pagination_strategy=StripePaginationStrategy() ) def _read( - config_builder: ConfigBuilder, - sync_mode: SyncMode, - state: Optional[Dict[str, Any]] = None, - expecting_exception: bool = False + config_builder: ConfigBuilder, sync_mode: SyncMode, state: Optional[Dict[str, Any]] = None, expecting_exception: bool = False ) -> EntrypointOutput: catalog = _catalog(sync_mode) config = config_builder.build() @@ -109,7 +100,6 @@ def _read( @freezegun.freeze_time(_NOW.isoformat()) class FullRefreshTest(TestCase): - @HttpMocker() def test_given_one_page_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: http_mocker.get( @@ -128,7 +118,12 @@ def test_given_many_pages_when_read_then_return_records(self, http_mocker: HttpM _transactions_response().with_pagination().with_record(_a_transaction().with_id("last_record_id_from_first_page")).build(), ) http_mocker.get( - _transactions_request().with_starting_after("last_record_id_from_first_page").with_created_gte(_A_START_DATE).with_created_lte(_NOW).with_limit(100).build(), + _transactions_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(_A_START_DATE) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _transactions_response().with_record(_a_transaction()).with_record(_a_transaction()).build(), ) @@ -169,7 +164,11 @@ def test_given_slice_range_when_read_then_perform_multiple_requests(self, http_m _transactions_response().build(), ) http_mocker.get( - _transactions_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).build(), + _transactions_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .build(), _transactions_response().build(), ) @@ -226,14 +225,12 @@ def test_given_http_status_500_when_read_then_raise_config_error(self, http_mock output = self._read(_config(), expecting_exception=True) assert output.errors[-1].trace.error.failure_type == FailureType.config_error - def _read(self, config: ConfigBuilder, expecting_exception: bool = False) -> EntrypointOutput: return _read(config, SyncMode.full_refresh, expecting_exception=expecting_exception) @freezegun.freeze_time(_NOW.isoformat()) class IncrementalTest(TestCase): - @HttpMocker() def test_given_no_state_when_read_then_use_transactions_endpoint(self, http_mocker: HttpMocker) -> None: cursor_value = int(_A_START_DATE.timestamp()) + 1 @@ -253,10 +250,13 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu cursor_value = int(state_datetime.timestamp()) + 1 http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_record( - _an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_transaction().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response().with_record(_an_event().with_cursor(cursor_value).with_field(_DATA_FIELD, _a_transaction().build())).build(), ) output = self._read( @@ -272,13 +272,25 @@ def test_given_state_when_read_then_query_events_using_types_and_state_value_plu def test_given_state_and_pagination_when_read_then_return_records(self, http_mocker: HttpMocker) -> None: state_datetime = _NOW - timedelta(days=5) http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), - _events_response().with_pagination().with_record( - _an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_transaction().build()) - ).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), + _events_response() + .with_pagination() + .with_record(_an_event().with_id("last_record_id_from_first_page").with_field(_DATA_FIELD, _a_transaction().build())) + .build(), ) http_mocker.get( - _events_request().with_starting_after("last_record_id_from_first_page").with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_starting_after("last_record_id_from_first_page") + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_transaction_event()).build(), ) @@ -296,11 +308,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri slice_datetime = state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES + slice_range http_mocker.get( - _events_request().with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(slice_datetime).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(state_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(slice_datetime) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_transaction_event()).build(), ) http_mocker.get( - _events_request().with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(slice_datetime + _AVOIDING_INCLUSIVE_BOUNDARIES) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_transaction_event()).with_record(self._a_transaction_event()).build(), ) @@ -312,14 +334,21 @@ def test_given_state_and_small_slice_range_when_read_then_perform_multiple_queri assert len(output.records) == 3 @HttpMocker() - def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary(self, http_mocker: HttpMocker) -> None: + def test_given_state_earlier_than_30_days_when_read_then_query_events_using_types_and_event_lower_boundary( + self, http_mocker: HttpMocker + ) -> None: # this seems odd as we would miss some data between start_date and events_lower_boundary. In that case, we should hit the # transactions endpoint start_date = _NOW - timedelta(days=40) state_value = _NOW - timedelta(days=39) events_lower_boundary = _NOW - timedelta(days=30) http_mocker.get( - _events_request().with_created_gte(events_lower_boundary).with_created_lte(_NOW).with_limit(100).with_types(_EVENT_TYPES).build(), + _events_request() + .with_created_gte(events_lower_boundary) + .with_created_lte(_NOW) + .with_limit(100) + .with_types(_EVENT_TYPES) + .build(), _events_response().with_record(self._a_transaction_event()).build(), ) diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/test_source.py b/airbyte-integrations/connectors/source-stripe/unit_tests/test_source.py index 7b315392b0967..f386415db130e 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/test_source.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/test_source.py @@ -4,12 +4,9 @@ import datetime import logging from contextlib import nullcontext as does_not_raise -from unittest.mock import patch import pytest -import source_stripe -import stripe -from airbyte_cdk.models import ConfiguredAirbyteCatalog, SyncMode +from airbyte_cdk.models import ConfiguredAirbyteCatalog, ConfiguredAirbyteCatalogSerializer, SyncMode from airbyte_cdk.sources.streams.call_rate import CachedLimiterSession, LimiterSession, Rate from airbyte_cdk.sources.streams.concurrent.adapters import StreamFacade from airbyte_cdk.test.state_builder import StateBuilder @@ -17,7 +14,7 @@ from source_stripe import SourceStripe logger = logging.getLogger("airbyte") -_ANY_CATALOG = ConfiguredAirbyteCatalog.parse_obj({"streams": []}) +_ANY_CATALOG = ConfiguredAirbyteCatalogSerializer.load({"streams": []}) _ANY_CONFIG = {} _NO_STATE = StateBuilder().build() @@ -43,18 +40,13 @@ def with_stream(self, name: str, sync_mode: SyncMode) -> "CatalogBuilder": return self def build(self) -> ConfiguredAirbyteCatalog: - return ConfiguredAirbyteCatalog.parse_obj({"streams": self._streams}) + return ConfiguredAirbyteCatalogSerializer.load({"streams": self._streams}) def _a_valid_config(): return {"account_id": 1, "client_secret": "secret"} -@patch.object(source_stripe.source, "stripe") -def test_source_check_connection_ok(mocked_client, config): - assert SourceStripe(_ANY_CATALOG, _ANY_CONFIG, _NO_STATE).check_connection(logger, config=config) == (True, None) - - def test_streams_are_unique(config): stream_names = [s.name for s in SourceStripe(_ANY_CATALOG, _ANY_CONFIG, _NO_STATE).streams(config=config)] assert len(stream_names) == len(set(stream_names)) == 46 @@ -69,25 +61,10 @@ def test_streams_are_unique(config): (_a_valid_config(), None), ), ) -@patch.object(source_stripe.source.stripe, "Account") -def test_config_validation(mocked_client, input_config, expected_error_msg): +def test_config_validation(input_config, expected_error_msg): context = pytest.raises(AirbyteTracedException, match=expected_error_msg) if expected_error_msg else does_not_raise() with context: - SourceStripe(_ANY_CATALOG, _ANY_CONFIG, _NO_STATE).check_connection(logger, config=input_config) - - -@pytest.mark.parametrize( - "exception", - ( - stripe.error.AuthenticationError, - stripe.error.PermissionError, - ), -) -@patch.object(source_stripe.source.stripe, "Account") -def test_given_stripe_error_when_check_connection_then_connection_not_available(mocked_client, exception): - mocked_client.retrieve.side_effect = exception - is_available, _ = SourceStripe(_ANY_CATALOG, _ANY_CONFIG, _NO_STATE).check_connection(logger, config=_a_valid_config()) - assert not is_available + SourceStripe(_ANY_CATALOG, _ANY_CONFIG, _NO_STATE).validate_and_fill_with_defaults(config=input_config) def test_when_streams_return_full_refresh_as_concurrent(): diff --git a/airbyte-integrations/connectors/source-stripe/unit_tests/test_streams.py b/airbyte-integrations/connectors/source-stripe/unit_tests/test_streams.py index d76fa0757ec0e..75a8f884f77a2 100644 --- a/airbyte-integrations/connectors/source-stripe/unit_tests/test_streams.py +++ b/airbyte-integrations/connectors/source-stripe/unit_tests/test_streams.py @@ -7,7 +7,7 @@ import freezegun import pendulum import pytest -from source_stripe.streams import CustomerBalanceTransactions, Persons, SetupAttempts +from source_stripe.streams import CustomerBalanceTransactions, SetupAttempts, StripeStream, UpdatedCursorIncrementalStripeSubStream def read_from_stream(stream, sync_mode, state): @@ -208,9 +208,9 @@ def test_lazy_substream_data_is_filtered( "reference": "7901352802291512", "reference_status": "available", "reference_type": "acquirer_reference_number", - "type": "refund" + "type": "refund", }, - "type": "card" + "type": "card", }, "metadata": {}, "payment_intent": "pi_3NRL2GEcXtiJtvvh0OiNTz0f", @@ -218,25 +218,15 @@ def test_lazy_substream_data_is_filtered( "receipt_number": None, "source_transfer_reversal": None, "status": "succeeded", - "transfer_reversal": None + "transfer_reversal": None, }, - "previous_attributes": { - "destination_details": { - "card": { - "reference": None, - "reference_status": "pending" - } - } - } + "previous_attributes": {"destination_details": {"card": {"reference": None, "reference_status": "pending"}}}, }, "livemode": False, "pending_webhooks": 0, - "request": { - "id": None, - "idempotency_key": None - }, - "type": "charge.refund.updated" - } + "request": {"id": None, "idempotency_key": None}, + "type": "charge.refund.updated", + }, ] @@ -350,8 +340,7 @@ def test_lazy_substream_data_is_filtered( ), ( { - "/v1/events": - [ + "/v1/events": [ { "json": { "data": [refunds_api_objects[2]], @@ -374,9 +363,9 @@ def test_lazy_substream_data_is_filtered( "reference": "7901352802291512", "reference_status": "available", "reference_type": "acquirer_reference_number", - "type": "refund" + "type": "refund", }, - "type": "card" + "type": "card", }, "metadata": {}, "payment_intent": "pi_3NRL2GEcXtiJtvvh0OiNTz0f", @@ -385,7 +374,7 @@ def test_lazy_substream_data_is_filtered( "source_transfer_reversal": None, "status": "succeeded", "transfer_reversal": None, - "updated": 1666518588 + "updated": 1666518588, } ], [{}], @@ -613,7 +602,13 @@ def test_setup_attempts(requests_mock, incremental_stream_args): def test_persons_wo_state(requests_mock, stream_args): requests_mock.get("/v1/accounts", json={"data": [{"id": 1, "object": "account", "created": 111}]}) - stream = Persons(**stream_args) + stream = UpdatedCursorIncrementalStripeSubStream( + name="persons", + path=lambda self, stream_slice, *args, **kwargs: f"accounts/{stream_slice['parent']['id']}/persons", + parent=StripeStream(name="accounts", path="accounts", use_cache=False, **stream_args), + event_types=["person.created", "person.updated", "person.deleted"], + **stream_args, + ) slices = list(stream.stream_slices("full_refresh")) assert slices == [{"parent": {"id": 1, "object": "account", "created": 111}}] requests_mock.get("/v1/accounts/1/persons", json={"data": [{"id": 11, "object": "person", "created": 222}]}) @@ -642,7 +637,13 @@ def test_persons_w_state(requests_mock, stream_args): "has_more": False, }, ) - stream = Persons(**stream_args) + stream = UpdatedCursorIncrementalStripeSubStream( + name="persons", + path=lambda self, stream_slice, *args, **kwargs: f"accounts/{stream_slice['parent']['id']}/persons", + parent=StripeStream(name="accounts", path="accounts", use_cache=False, **stream_args), + event_types=["person.created", "person.updated", "person.deleted"], + **stream_args, + ) slices = list(stream.stream_slices("incremental", stream_state={"updated": pendulum.parse("2023-08-20T00:00:00").int_timestamp})) assert slices == [{}] records = [ diff --git a/airbyte-integrations/connectors/source-zendesk-support/integration_tests/configured_catalog.json b/airbyte-integrations/connectors/source-zendesk-support/integration_tests/configured_catalog.json index 329f8938a35dc..a7be2631ff3dd 100644 --- a/airbyte-integrations/connectors/source-zendesk-support/integration_tests/configured_catalog.json +++ b/airbyte-integrations/connectors/source-zendesk-support/integration_tests/configured_catalog.json @@ -12,6 +12,30 @@ "sync_mode": "full_refresh", "destination_sync_mode": "append" }, + { + "stream": { + "name": "automations", + "json_schema": {}, + "supported_sync_modes": ["full_refresh", "incremental"], + "source_defined_cursor": true, + "default_cursor_field": ["created_at"], + "source_defined_primary_key": [["id"]] + }, + "sync_mode": "full_refresh", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "triggers", + "json_schema": {}, + "supported_sync_modes": ["full_refresh", "incremental"], + "source_defined_cursor": true, + "default_cursor_field": ["created_at"], + "source_defined_primary_key": [["id"]] + }, + "sync_mode": "full_refresh", + "destination_sync_mode": "append" + }, { "stream": { "name": "group_memberships", diff --git a/airbyte-integrations/connectors/source-zendesk-support/integration_tests/expected_records.jsonl b/airbyte-integrations/connectors/source-zendesk-support/integration_tests/expected_records.jsonl index d663d9ef22c65..a8548e483d42c 100644 --- a/airbyte-integrations/connectors/source-zendesk-support/integration_tests/expected_records.jsonl +++ b/airbyte-integrations/connectors/source-zendesk-support/integration_tests/expected_records.jsonl @@ -71,3 +71,5 @@ {"stream": "attribute_definitions", "data": {"title": "Brand", "subject": "brand_id", "type": "list", "group": "ticket", "nullable": false, "repeatable": false, "operators": [{"value": "is", "title": "Is", "terminal": false}, {"value": "is_not", "title": "Is not", "terminal": false}], "values": [{"value": "360000358316", "title": "Airbyte", "enabled": true}], "condition": "all"}, "emitted_at": 1720179652468} {"stream": "attribute_definitions", "data": {"title": "Form", "subject": "ticket_form_id", "type": "list", "group": "ticket", "nullable": false, "repeatable": false, "operators": [{"value": "is", "title": "Is", "terminal": false}, {"value": "is_not", "title": "Is not", "terminal": false}], "values": [{"value": "360000084116", "title": "Default Ticket Form", "enabled": true}], "condition": "all"}, "emitted_at": 1720179652472} {"stream": "ticket_forms", "data": {"id": 360000084116, "raw_name": "Default Ticket Form", "raw_display_name": "Default Ticket Form", "end_user_visible": true, "position": 1, "ticket_field_ids": [360002833076, 360002833096, 360002833116, 360002833136, 360002833156, 360002833176, 360002833196], "active": true, "default": true, "in_all_brands": true, "restricted_brand_ids": [], "end_user_conditions": [], "agent_conditions": [], "url": "https://d3v-airbyte.zendesk.com/api/v2/ticket_forms/360000084116.json", "name": "Default Ticket Form", "display_name": "Default Ticket Form", "created_at": "2020-12-11T18:34:37Z", "updated_at": "2020-12-11T18:34:37Z"}, "emitted_at": 1720179653174} +{"stream":"automations","data":{"url":"https://d3v-airbyte.zendesk.com/api/v2/automations/6241378811151.json","id":6241378811151,"title":"Close ticket 4 days after status is set to solved","active":true,"updated_at":"2023-01-19T00:26:48Z","created_at":"2023-01-19T00:26:48Z","default":true,"actions":[{"field":"status","value":"closed"}],"conditions":{"all":[{"field":"status","operator":"is","value":"solved"},{"field":"SOLVED","operator":"greater_than","value":"480"}],"any":[]},"position":0,"raw_title":"Close ticket 4 days after status is set to solved"},"emitted_at":1725816608179} +{"stream":"triggers","data":{"url":"https://d3v-airbyte.zendesk.com/api/v2/triggers/7282769224079.json","id":7282769224079,"title":"Request customer satisfaction rating (social messaging)","active":true,"updated_at":"2023-06-26T10:48:19Z","created_at":"2023-06-26T10:48:19Z","default":false,"actions":[{"field":"notification_messaging_csat","value":"requester_id"}],"conditions":{"all":[{"field":"status","operator":"value","value":"solved"}],"any":[{"field":"via_id","operator":"is","value":"73"},{"field":"via_id","operator":"is","value":"72"},{"field":"via_id","operator":"is","value":"74"},{"field":"via_id","operator":"is","value":"78"},{"field":"via_id","operator":"is","value":"88"}]},"description":"Asks customer for a rating after the conversation is over. This trigger is created by the system.","position":8,"raw_title":"Request customer satisfaction rating (social messaging)","category_id":"1276235"},"emitted_at":1725816657977} diff --git a/airbyte-integrations/connectors/source-zendesk-support/metadata.yaml b/airbyte-integrations/connectors/source-zendesk-support/metadata.yaml index d66aa67bf5eb3..128787d37e2ce 100644 --- a/airbyte-integrations/connectors/source-zendesk-support/metadata.yaml +++ b/airbyte-integrations/connectors/source-zendesk-support/metadata.yaml @@ -11,7 +11,7 @@ data: connectorSubtype: api connectorType: source definitionId: 79c1aa37-dae3-42ae-b333-d1c105477715 - dockerImageTag: 4.1.1 + dockerImageTag: 4.2.0 dockerRepository: airbyte/source-zendesk-support documentationUrl: https://docs.airbyte.com/integrations/sources/zendesk-support githubIssueLabel: source-zendesk-support diff --git a/airbyte-integrations/connectors/source-zendesk-support/pyproject.toml b/airbyte-integrations/connectors/source-zendesk-support/pyproject.toml index 4bce08ed55c2e..cee0c2231291d 100644 --- a/airbyte-integrations/connectors/source-zendesk-support/pyproject.toml +++ b/airbyte-integrations/connectors/source-zendesk-support/pyproject.toml @@ -3,7 +3,7 @@ requires = [ "poetry-core>=1.0.0",] build-backend = "poetry.core.masonry.api" [tool.poetry] -version = "4.1.1" +version = "4.2.0" name = "source-zendesk-support" description = "Source implementation for Zendesk Support." authors = [ "Airbyte ",] diff --git a/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/manifest.yaml b/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/manifest.yaml index b37fbc297c807..3a12f65c05490 100644 --- a/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/manifest.yaml +++ b/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/manifest.yaml @@ -199,6 +199,17 @@ definitions: path: "tags" primary_key: "name" + automations_stream: + $ref: "#/definitions/base_stream" + retriever: + $ref: "#/definitions/retriever" + paginator: + $ref: "#/definitions/links_next_paginator" + $parameters: + name: "automations" + path: "automations" + primary_key: "id" + # Incremental cursor-based streams audit_logs_stream: $ref: "#/definitions/base_incremental_stream" @@ -554,6 +565,14 @@ definitions: cursor_field: "updated_at" primary_key: "id" + triggers_stream: + $ref: "#/definitions/semi_incremental_stream" + $parameters: + name: "triggers" + path: "triggers" + cursor_field: "updated_at" + primary_key: "id" + users_stream: $ref: "#/definitions/base_incremental_stream" retriever: @@ -581,6 +600,7 @@ streams: - $ref: "#/definitions/ticket_forms_stream" - $ref: "#/definitions/topics_stream" - $ref: "#/definitions/user_fields_stream" + - $ref: "#/definitions/automations_stream" # Incremental streams - $ref: "#/definitions/audit_logs_stream" - $ref: "#/definitions/groups_stream" @@ -595,4 +615,5 @@ streams: - $ref: "#/definitions/ticket_comments_stream" - $ref: "#/definitions/ticket_metric_events_stream" - $ref: "#/definitions/ticket_skips_stream" + - $ref: "#/definitions/triggers_stream" - $ref: "#/definitions/users_stream" diff --git a/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/schemas/automations.json b/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/schemas/automations.json new file mode 100644 index 0000000000000..e245a86817781 --- /dev/null +++ b/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/schemas/automations.json @@ -0,0 +1,93 @@ +{ + "$schema": "https://json-schema.org/draft-07/schema#", + "type": "object", + "properties": { + "actions": { + "type": "array", + "description": "An object describing what the automation will do", + "items": { + "type": ["object", "null"], + "properties": { + "field": { + "type": ["string", "null"] + }, + "value": { + "type": ["string", "null"] + } + } + } + }, + "active": { + "type": ["boolean", "null"], + "description": "Whether the automation is active" + }, + "conditions": { + "type": "object", + "description": "An object that describes the conditions under which the automation will execute", + "properties": { + "all": { + "type": "array", + "items": { + "type": ["object", "null"], + "properties": { + "field": { + "type": ["string", "null"] + }, + "operator": { + "type": ["string", "null"] + }, + "value": { + "type": ["string", "null"] + } + } + } + }, + "any": { + "type": "array", + "items": { + "type": ["object", "null"], + "properties": { + "field": { + "type": ["string", "null"] + }, + "operator": { + "type": ["string", "null"] + }, + "value": { + "type": ["string", "null"] + } + } + } + } + } + }, + "created_at": { + "description": "The time the automation was created", + "type": ["string", "null"] + }, + "default": { + "type": ["boolean", "null"], + "description": "If true, the automation is a default automation" + }, + "id": { + "type": ["integer", "null"], + "description": "Automatically assigned when created" + }, + "position": { + "type": ["integer", "null"], + "description": "The position of the automation which specifies the order it will be executed" + }, + "raw_title": { + "type": ["string", "null"], + "description": "The raw title of the automation" + }, + "title": { + "type": ["string", "null"], + "description": "The title of the automation" + }, + "updated_at": { + "description": "The time of the last update of the automation", + "type": ["string", "null"] + } + } +} diff --git a/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/schemas/triggers.json b/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/schemas/triggers.json new file mode 100644 index 0000000000000..27cad0b6456d7 --- /dev/null +++ b/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/schemas/triggers.json @@ -0,0 +1,105 @@ +{ + "$schema": "https://json-schema.org/draft-07/schema#", + "type": ["null", "object"], + "properties": { + "actions": { + "type": ["array", "null"], + "description": "An array of actions describing what the ticket trigger will do", + "items": { + "type": "object", + "properties": { + "field": { + "type": ["string", "null"] + }, + "value": { + "type": ["string", "null"] + } + } + } + }, + "active": { + "description": "Whether the ticket trigger is active", + "type": "boolean" + }, + "category_id": { + "description": "The ID of the category the ticket trigger belongs to", + "type": ["string", "null"] + }, + "conditions": { + "description": "An object that describes the circumstances under which the trigger performs its actions", + "type": "object", + "properties": { + "all": { + "type": ["array", "null"], + "items": { + "type": "object", + "properties": { + "field": { + "type": ["string", "null"] + }, + "operator": { + "type": ["string", "null"] + }, + "value": { + "type": ["string", "null"] + } + } + } + }, + "any": { + "type": ["array", "null"], + "items": { + "type": "object", + "properties": { + "field": { + "type": ["string", "null"] + }, + "operator": { + "type": ["string", "null"] + }, + "value": { + "type": ["string", "null"] + } + } + } + } + } + }, + "created_at": { + "description": "The time the ticket trigger was created", + "type": ["string", "null"] + }, + "default": { + "description": "If true, the ticket trigger is a standard trigger", + "type": "boolean" + }, + "description": { + "description": "The description of the ticket trigger", + "type": ["string", "null"] + }, + "id": { + "description": "Automatically assigned when created", + "type": "integer" + }, + "position": { + "description": "Position of the ticket trigger, determines the order they will execute in", + "type": "integer" + }, + "raw_title": { + "description": "The raw format of the title of the ticket trigger", + "type": ["string", "null"] + }, + "title": { + "description": "The title of the ticket trigger", + "type": ["string", "null"] + }, + "updated_at": { + "description": "The time of the last update of the ticket trigger", + "type": ["string", "null"] + }, + "url": { + "description": "The url of the ticket trigger", + "type": ["string", "null"] + } + } +} diff --git a/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/streams.py b/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/streams.py index f1887a03442ec..4095b6c50a5af 100644 --- a/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/streams.py +++ b/airbyte-integrations/connectors/source-zendesk-support/source_zendesk_support/streams.py @@ -431,6 +431,10 @@ class AuditLogs(CursorPaginationZendeskSupportStream): cursor_field = "created_at" +class Automations(FullRefreshZendeskSupportStream): + """Automations stream: https://developer.zendesk.com/api-reference/ticketing/business-rules/automations/#list-automations""" + + class Users(SourceZendeskIncrementalExportStream): """Users stream: https://developer.zendesk.com/api-reference/ticketing/ticket-management/incremental_exports/#incremental-user-export""" @@ -779,6 +783,10 @@ def path(self, **kwargs): return "community/topics" +class Triggers(CursorPaginationZendeskSupportStream): + """Triggers stream: https://developer.zendesk.com/api-reference/ticketing/business-rules/triggers/#list-ticket-triggers""" + + class SlaPolicies(IncrementalZendeskSupportStream): """SlaPolicies stream: https://developer.zendesk.com/api-reference/ticketing/business-rules/sla_policies/""" diff --git a/airbyte-integrations/connectors/source-zendesk-support/unit_tests/unit_test.py b/airbyte-integrations/connectors/source-zendesk-support/unit_tests/unit_test.py index 9a33e3802b344..f51adae5ccabd 100644 --- a/airbyte-integrations/connectors/source-zendesk-support/unit_tests/unit_test.py +++ b/airbyte-integrations/connectors/source-zendesk-support/unit_tests/unit_test.py @@ -185,11 +185,11 @@ def test_check(response, start_date, check_passed): @pytest.mark.parametrize( "ticket_forms_response, status_code, expected_n_streams, expected_warnings, reason", [ - ('{"ticket_forms": [{"id": 1, "updated_at": "2021-07-08T00:05:45Z"}]}', 200, 35, [], None), + ('{"ticket_forms": [{"id": 1, "updated_at": "2021-07-08T00:05:45Z"}]}', 200, 37, [], None), ( '{"error": "Not sufficient permissions"}', 403, - 32, + 34, [ "An exception occurred while trying to access TicketForms stream: Forbidden. You don't have permission to access this resource.. Skipping this stream." ], @@ -198,7 +198,7 @@ def test_check(response, start_date, check_passed): ( "", 404, - 32, + 34, [ "An exception occurred while trying to access TicketForms stream: Not found. The requested resource was not found on the server.. Skipping this stream." ], diff --git a/docs/contributing-to-airbyte/resources/qa-checks.md b/docs/contributing-to-airbyte/resources/qa-checks.md index 48ee995f01796..0a471d23d6e60 100644 --- a/docs/contributing-to-airbyte/resources/qa-checks.md +++ b/docs/contributing-to-airbyte/resources/qa-checks.md @@ -13,7 +13,7 @@ They are by no mean replacing the need for a manual review of the connector code _Applies to the following connector types: source, destination_ _Applies to the following connector languages: java, low-code, python, manifest-only_ _Applies to connector with any support level_ -_Applies to connector with any internal support level_ +_Applies to connector with 100 internal support level_ _Applies to connector with any Airbyte usage level_ When a breaking change is introduced, we check that a migration guide is available. It should be stored under `./docs/integrations/s/-migrations.md`. @@ -24,7 +24,7 @@ This document should contain a section for each breaking change, in order of the _Applies to the following connector types: source, destination_ _Applies to the following connector languages: java, low-code, python, manifest-only_ _Applies to connector with any support level_ -_Applies to connector with any internal support level_ +_Applies to connector with 100 internal support level_ _Applies to connector with any Airbyte usage level_ The user facing connector documentation should be stored under `./docs/integrations/s/.md`. @@ -251,7 +251,7 @@ Check verifies that Changelog header section content follows standard template: _Applies to the following connector types: source, destination_ _Applies to the following connector languages: java, low-code, python, manifest-only_ _Applies to connector with any support level_ -_Applies to connector with any internal support level_ +_Applies to connector with 100 internal support level_ _Applies to connector with any Airbyte usage level_ Each new version of a connector must have a changelog entry defined in the user facing documentation in `./docs/integrations/s/.md`. diff --git a/docs/integrations/destinations/databricks.md b/docs/integrations/destinations/databricks.md index b48664bda0a90..d049c7b447c2c 100644 --- a/docs/integrations/destinations/databricks.md +++ b/docs/integrations/destinations/databricks.md @@ -90,7 +90,8 @@ with the raw tables, and their format is subject to change without notice. Expand to review | Version | Date | Pull Request | Subject | -| :------ | :--------- | :------------------------------------------------------------------------------------------------------------------ | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +|:--------|:-----------|:--------------------------------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| 3.2.4 | 2024-09-09 | [#45208](https://github.com/airbytehq/airbyte/pull/45208) | Fix CHECK to create missing namespace if not exists. | | 3.2.3 | 2024-09-03 | [#45115](https://github.com/airbytehq/airbyte/pull/45115) | Clarify Unity Catalog Name option. | | 3.2.2 | 2024-08-22 | [#44941](https://github.com/airbytehq/airbyte/pull/44941) | Clarify Unity Catalog Path option. | | 3.2.1 | 2024-08-22 | [#44506](https://github.com/airbytehq/airbyte/pull/44506) | Handle uppercase/mixed-case stream name/namespaces | diff --git a/docs/integrations/sources/getlago.md b/docs/integrations/sources/getlago.md index 16be59ef4041a..217d61ae941b6 100644 --- a/docs/integrations/sources/getlago.md +++ b/docs/integrations/sources/getlago.md @@ -32,6 +32,7 @@ This source can sync data from the [Lago API](https://doc.getlago.com/docs/guide | Version | Date | Pull Request | Subject | | :------ | :--------- | :-------------------------------------------------------- | :---------------------------------------- | +| 0.6.0 | 2024-09-06 | [45193](https://github.com/airbytehq/airbyte/pull/45193) | Endpoint customer usage ignore 405 response | | 0.5.0 | 2024-08-23 | [44613](https://github.com/airbytehq/airbyte/pull/44613) | Refactor connector to manifest-only format | | 0.4.11 | 2024-08-17 | [44273](https://github.com/airbytehq/airbyte/pull/44273) | Update dependencies | | 0.4.10 | 2024-08-12 | [43800](https://github.com/airbytehq/airbyte/pull/43800) | Update dependencies | diff --git a/docs/integrations/sources/low-code.md b/docs/integrations/sources/low-code.md index 3f9fa36f6c170..9792f72b02f0b 100644 --- a/docs/integrations/sources/low-code.md +++ b/docs/integrations/sources/low-code.md @@ -9,6 +9,11 @@ The changelog below is automatically updated by the `bump_version` command as pa | Version | Date | Pull Request | Subject | | :------ | :--------- | :------------------------------------------------------- | :------------------------------------------------------------------- | +| 5.5.2 | 2024-09-10 | [36501](https://github.com/airbytehq/airbyte/pull/36501) | Bump CDK version to 5.5.2 | +| 5.5.1 | 2024-09-10 | [36501](https://github.com/airbytehq/airbyte/pull/36501) | Bump CDK version to 5.5.1 | +| 5.5.0 | 2024-09-10 | [36501](https://github.com/airbytehq/airbyte/pull/36501) | Bump CDK version to 5.5.0 | +| 5.4.0 | 2024-09-09 | [36501](https://github.com/airbytehq/airbyte/pull/36501) | Bump CDK version to 5.4.0 | +| 5.3.0 | 2024-09-09 | [36501](https://github.com/airbytehq/airbyte/pull/36501) | Bump CDK version to 5.3.0 | | 5.2.1 | 2024-09-06 | [36501](https://github.com/airbytehq/airbyte/pull/36501) | Bump CDK version to 5.2.1 | | 5.2.0 | 2024-09-06 | [36501](https://github.com/airbytehq/airbyte/pull/36501) | Bump CDK version to 5.2.0 | | 5.1.0 | 2024-09-06 | [36501](https://github.com/airbytehq/airbyte/pull/36501) | Bump CDK version to 5.1.0 | diff --git a/docs/integrations/sources/mssql.md b/docs/integrations/sources/mssql.md index 03778dbb1dea6..847204d28cc53 100644 --- a/docs/integrations/sources/mssql.md +++ b/docs/integrations/sources/mssql.md @@ -422,6 +422,8 @@ WHERE actor_definition_id ='b5ea17b1-f170-46dc-bc31-cc744ca984c1' AND (configura | Version | Date | Pull Request | Subject | |:--------|:-----------|:------------------------------------------------------------------------------------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------| +| 4.1.13 | 2024-09-05 | [45181](https://github.com/airbytehq/airbyte/pull/45181) | Fix incorrect categorizing resumable/nonresumable full refresh streams. | +| 4.1.12 | 2024-09-10 | [45368](https://github.com/airbytehq/airbyte/pull/45368) | Remove excessive debezium logging. | | 4.1.11 | 2024-09-04 | [45142](https://github.com/airbytehq/airbyte/pull/45142) | Fix incorrect datetimeoffset format in cursor state. | | 4.1.10 | 2024-08-27 | [44759](https://github.com/airbytehq/airbyte/pull/44759) | Improve null safety in parsing debezium change events. | | 4.1.9 | 2024-08-27 | [44841](https://github.com/airbytehq/airbyte/pull/44841) | Adopt latest CDK. | diff --git a/docs/integrations/sources/mysql.md b/docs/integrations/sources/mysql.md index 97c1f1a22df85..5b398ae5a2f8e 100644 --- a/docs/integrations/sources/mysql.md +++ b/docs/integrations/sources/mysql.md @@ -233,7 +233,8 @@ Any database or table encoding combination of charset and collation is supported | Version | Date | Pull Request | Subject | |:--------|:-----------|:-----------------------------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------| -| 3.7.1 | 2024-08-27 | [44841](https://github.com/airbytehq/airbyte/pull/44841) | Adopt latest CDK. | +| 3.7.2 | 2024-09-05 | [45181](https://github.com/airbytehq/airbyte/pull/45181) | Fix incorrect categorizing resumable/nonresumable full refresh streams. | +| 3.7.1 | 2024-08-27 | [44841](https://github.com/airbytehq/airbyte/pull/44841) | Adopt latest CDK. | | 3.7.0 | 2024-08-13 | [44013](https://github.com/airbytehq/airbyte/pull/44013) | Upgrading to Debezium 2.7.1.Final | | 3.6.9 | 2024-08-08 | [43410](https://github.com/airbytehq/airbyte/pull/43410) | Adopt latest CDK. | | 3.6.8 | 2024-07-30 | [42869](https://github.com/airbytehq/airbyte/pull/42869) | Adopt latest CDK. | diff --git a/docs/integrations/sources/sendgrid.md b/docs/integrations/sources/sendgrid.md index e834768f2b366..3aff3b814c873 100644 --- a/docs/integrations/sources/sendgrid.md +++ b/docs/integrations/sources/sendgrid.md @@ -88,27 +88,28 @@ The connector is restricted by normal Sendgrid [requests limitation](https://doc Expand to review | Version | Date | Pull Request | Subject | -| :------ | :--------- | :------------------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| 1.0.18 | 2024-09-07 | [45239](https://github.com/airbytehq/airbyte/pull/45239) | Update dependencies | -| 1.0.17 | 2024-08-31 | [44953](https://github.com/airbytehq/airbyte/pull/44953) | Update dependencies | -| 1.0.16 | 2024-08-24 | [44753](https://github.com/airbytehq/airbyte/pull/44753) | Update dependencies | -| 1.0.15 | 2024-08-17 | [44233](https://github.com/airbytehq/airbyte/pull/44233) | Update dependencies | -| 1.0.14 | 2024-08-12 | [43751](https://github.com/airbytehq/airbyte/pull/43751) | Update dependencies | -| 1.0.13 | 2024-08-10 | [43635](https://github.com/airbytehq/airbyte/pull/43635) | Update dependencies | -| 1.0.12 | 2024-08-03 | [43269](https://github.com/airbytehq/airbyte/pull/43269) | Update dependencies | -| 1.0.11 | 2024-07-27 | [42729](https://github.com/airbytehq/airbyte/pull/42729) | Update dependencies | -| 1.0.10 | 2024-07-20 | [42310](https://github.com/airbytehq/airbyte/pull/42310) | Update dependencies | -| 1.0.9 | 2024-07-13 | [41753](https://github.com/airbytehq/airbyte/pull/41753) | Update dependencies | -| 1.0.8 | 2024-07-10 | [41531](https://github.com/airbytehq/airbyte/pull/41531) | Update dependencies | -| 1.0.7 | 2024-07-09 | [41137](https://github.com/airbytehq/airbyte/pull/41137) | Update dependencies | -| 1.0.6 | 2024-07-06 | [40898](https://github.com/airbytehq/airbyte/pull/40898) | Update dependencies | -| 1.0.5 | 2024-06-25 | [40356](https://github.com/airbytehq/airbyte/pull/40356) | Update dependencies | -| 1.0.4 | 2024-06-22 | [40155](https://github.com/airbytehq/airbyte/pull/40155) | Update dependencies | -| 1.0.3 | 2024-06-06 | [39197](https://github.com/airbytehq/airbyte/pull/39197) | [autopull] Upgrade base image to v1.2.2 | -| 1.0.2 | 2024-05-21 | [38478](https://github.com/airbytehq/airbyte/pull/38478) | Update deprecated authenticator package | -| 1.0.1 | 2024-05-20 | [38264](https://github.com/airbytehq/airbyte/pull/38264) | Replace AirbyteLogger with logging.Logger | -| 1.0.0 | 2024-04-15 | [35776](https://github.com/airbytehq/airbyte/pull/35776) | Migration to low-code CDK. Breaking change that updates configuration keys, removes unsubscribe_groups stream, renames a stream to singlesend_stats, and adds the singlesends stream. | -| 0.5.0 | 2024-03-26 | [36455](https://github.com/airbytehq/airbyte/pull/36455) | Unpin CDK version, add record counts to state messages | +|:--------|:-----------| :------------------------------------------------------- |:--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| 1.1.0 | 2024-09-11 | [45191](https://github.com/airbytehq/airbyte/pull/45191) | Move Contacts stream to declarative async job | +| 1.0.18 | 2024-09-07 | [45239](https://github.com/airbytehq/airbyte/pull/45239) | Update dependencies | +| 1.0.17 | 2024-08-31 | [44953](https://github.com/airbytehq/airbyte/pull/44953) | Update dependencies | +| 1.0.16 | 2024-08-24 | [44753](https://github.com/airbytehq/airbyte/pull/44753) | Update dependencies | +| 1.0.15 | 2024-08-17 | [44233](https://github.com/airbytehq/airbyte/pull/44233) | Update dependencies | +| 1.0.14 | 2024-08-12 | [43751](https://github.com/airbytehq/airbyte/pull/43751) | Update dependencies | +| 1.0.13 | 2024-08-10 | [43635](https://github.com/airbytehq/airbyte/pull/43635) | Update dependencies | +| 1.0.12 | 2024-08-03 | [43269](https://github.com/airbytehq/airbyte/pull/43269) | Update dependencies | +| 1.0.11 | 2024-07-27 | [42729](https://github.com/airbytehq/airbyte/pull/42729) | Update dependencies | +| 1.0.10 | 2024-07-20 | [42310](https://github.com/airbytehq/airbyte/pull/42310) | Update dependencies | +| 1.0.9 | 2024-07-13 | [41753](https://github.com/airbytehq/airbyte/pull/41753) | Update dependencies | +| 1.0.8 | 2024-07-10 | [41531](https://github.com/airbytehq/airbyte/pull/41531) | Update dependencies | +| 1.0.7 | 2024-07-09 | [41137](https://github.com/airbytehq/airbyte/pull/41137) | Update dependencies | +| 1.0.6 | 2024-07-06 | [40898](https://github.com/airbytehq/airbyte/pull/40898) | Update dependencies | +| 1.0.5 | 2024-06-25 | [40356](https://github.com/airbytehq/airbyte/pull/40356) | Update dependencies | +| 1.0.4 | 2024-06-22 | [40155](https://github.com/airbytehq/airbyte/pull/40155) | Update dependencies | +| 1.0.3 | 2024-06-06 | [39197](https://github.com/airbytehq/airbyte/pull/39197) | [autopull] Upgrade base image to v1.2.2 | +| 1.0.2 | 2024-05-21 | [38478](https://github.com/airbytehq/airbyte/pull/38478) | Update deprecated authenticator package | +| 1.0.1 | 2024-05-20 | [38264](https://github.com/airbytehq/airbyte/pull/38264) | Replace AirbyteLogger with logging.Logger | +| 1.0.0 | 2024-04-15 | [35776](https://github.com/airbytehq/airbyte/pull/35776) | Migration to low-code CDK. Breaking change that updates configuration keys, removes unsubscribe_groups stream, renames a stream to singlesend_stats, and adds the singlesends stream. | +| 0.5.0 | 2024-03-26 | [36455](https://github.com/airbytehq/airbyte/pull/36455) | Unpin CDK version, add record counts to state messages | | 0.4.3 | 2024-02-21 | [35181](https://github.com/airbytehq/airbyte/pull/35343) | Handle uncompressed contacts downloads. | | 0.4.2 | 2024-02-12 | [35181](https://github.com/airbytehq/airbyte/pull/35181) | Manage dependencies with Poetry. | | 0.4.1 | 2023-10-18 | [31543](https://github.com/airbytehq/airbyte/pull/31543) | Base image migration: remove Dockerfile and use the python-connector-base image | diff --git a/docs/integrations/sources/stripe-migrations.md b/docs/integrations/sources/stripe-migrations.md index a132626b6892c..c29ba216d9c75 100644 --- a/docs/integrations/sources/stripe-migrations.md +++ b/docs/integrations/sources/stripe-migrations.md @@ -1,5 +1,44 @@ # Stripe Migration Guide +## Upgrading to 5.6.0 + +The `Payment Methods` stream previously sync data from Treasury flows. This version will now provide data about customers' payment methods. + +### Summary of changes: + +- The stream `Payment Methods` will now provide data about customers' payment methods. +- The stream `Payment Methods` now incrementally syncs using the `events` endpoint. +- `customer` field type will be changed from `object` to `string`. + +### Refresh affected schemas and reset data + +1. Select **Connections** in the main navbar. + 1. Select the connection(s) affected by the update. +2. Select the **Replication** tab. + 1. Select **Refresh source schema**. + 2. Select **OK**. + +```note +Any detected schema changes will be listed for your review. +``` + +3. Select **Save changes** at the bottom of the page. + 1. Ensure the **Reset affected streams** option is checked. + +```note +Depending on destination type you may not be prompted to reset your data. +``` + +4. Select **Save connection**. + +```note +This will reset the data in your destination and initiate a fresh sync. +``` + +For more information on resetting your data in Airbyte, see [this page](/operator-guides/clear). + + + ## Upgrading to 5.4.0 The `Refunds` stream previously did not sync incrementally correctly. Incremental syncs are now resolved, and the `Refunds` stream now receives the correct updates using the `events` endpoint. This version resolves incremental sync issues with the `Refunds` stream. diff --git a/docs/integrations/sources/stripe.md b/docs/integrations/sources/stripe.md index 9e32c5747a9f3..ac5cc91726f5c 100644 --- a/docs/integrations/sources/stripe.md +++ b/docs/integrations/sources/stripe.md @@ -108,7 +108,7 @@ The Stripe source connector supports the following streams: - [Invoice Line Items](https://stripe.com/docs/api/invoices/invoice_lines) - [Invoices](https://stripe.com/docs/api/invoices/list) \(Incremental\) - [Payment Intents](https://stripe.com/docs/api/payment_intents/list) \(Incremental\) -- [Payment Methods](https://stripe.com/docs/api/payment_methods/list) +- [Payment Methods](https://docs.stripe.com/api/payment_methods/customer_list?lang=curl) \(Incremental\) - [Payouts](https://stripe.com/docs/api/payouts/list) \(Incremental\) - [Promotion Code](https://stripe.com/docs/api/promotion_codes/list) \(Incremental\) - [Persons](https://stripe.com/docs/api/persons/list) \(Incremental\) @@ -238,38 +238,40 @@ Each record is marked with `is_deleted` flag when the appropriate event happens Expand to review | Version | Date | Pull Request | Subject | -|:--------|:-----------| :-------------------------------------------------------- |:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| 5.5.3 | 2024-09-03 | [45101](https://github.com/airbytehq/airbyte/pull/45101) | Fix regression followoing pagination issue fix | -| 5.5.2 | 2024-08-28 | [44862](https://github.com/airbytehq/airbyte/pull/44862) | Fix RFR pagination issue | -| 5.5.1 | 2024-08-10 | [43105](https://github.com/airbytehq/airbyte/pull/43105) | Update dependencies | -| 5.5.0 | 2024-08-08 | [43302](https://github.com/airbytehq/airbyte/pull/43302) | Fix problem with state not updating and upgrade cdk 4 -| 5.4.12 | 2024-07-31 | [41985](https://github.com/airbytehq/airbyte/pull/41985) | Expand Invoice discounts and tax rates -| 5.4.11 | 2024-07-27 | [42623](https://github.com/airbytehq/airbyte/pull/42623) | Update dependencies | -| 5.4.10 | 2024-07-20 | [42305](https://github.com/airbytehq/airbyte/pull/42305) | Update dependencies | -| 5.4.9 | 2024-07-13 | [41760](https://github.com/airbytehq/airbyte/pull/41760) | Update dependencies | -| 5.4.8 | 2024-07-10 | [41477](https://github.com/airbytehq/airbyte/pull/41477) | Update dependencies | -| 5.4.7 | 2024-07-09 | [40869](https://github.com/airbytehq/airbyte/pull/40869) | Update dependencies | -| 5.4.6 | 2024-07-08 | [41044](https://github.com/airbytehq/airbyte/pull/41044) | Use latest `CDK` version possible | -| 5.4.5 | 2024-06-25 | [40404](https://github.com/airbytehq/airbyte/pull/40404) | Update dependencies | -| 5.4.4 | 2024-06-22 | [40040](https://github.com/airbytehq/airbyte/pull/40040) | Update dependencies | -| 5.4.3 | 2024-06-06 | [39284](https://github.com/airbytehq/airbyte/pull/39284) | [autopull] Upgrade base image to v1.2.2 | -| 5.4.2 | 2024-06-11 | [39412](https://github.com/airbytehq/airbyte/pull/39412) | Removed `invoice.upcomming` event type from (incremental sync) for `Invoices` stream | -| 5.4.1 | 2024-06-11 | [39393](https://github.com/airbytehq/airbyte/pull/39393) | Added missing `event types` (incremental sync) for `Invoices` stream | -| 5.4.0 | 2024-06-05 | [39138](https://github.com/airbytehq/airbyte/pull/39138) | Fixed the `Refunds` stream missing data for the `incremental` sync | -| 5.3.9 | 2024-05-22 | [38550](https://github.com/airbytehq/airbyte/pull/38550) | Update authenticator package | -| 5.3.8 | 2024-05-15 | [38248](https://github.com/airbytehq/airbyte/pull/38248) | Replace AirbyteLogger with logging.Logger | -| 5.3.7 | 2024-04-24 | [36663](https://github.com/airbytehq/airbyte/pull/36663) | Schema descriptions | -| 5.3.6 | 2024-04-18 | [37448](https://github.com/airbytehq/airbyte/pull/37448) | Ensure AirbyteTracedException in concurrent CDK are emitted with the right type | -| 5.3.5 | 2024-04-18 | [37418](https://github.com/airbytehq/airbyte/pull/37418) | Ensure python return code != 0 in case of error | -| 5.3.4 | 2024-04-11 | [37406](https://github.com/airbytehq/airbyte/pull/37406) | Update CDK version to have partitioned state fix | -| 5.3.3 | 2024-04-11 | [37001](https://github.com/airbytehq/airbyte/pull/37001) | Update airbyte-cdk to flush print buffer for every message | -| 5.3.2 | 2024-04-11 | [36964](https://github.com/airbytehq/airbyte/pull/36964) | Update CDK version to fix breaking change before another devs work on it | -| 5.3.1 | 2024-04-10 | [36960](https://github.com/airbytehq/airbyte/pull/36960) | Remove unused imports | -| 5.3.0 | 2024-03-12 | [35978](https://github.com/airbytehq/airbyte/pull/35978) | Upgrade CDK to start emitting record counts with state and full refresh state | -| 5.2.4 | 2024-02-12 | [35137](https://github.com/airbytehq/airbyte/pull/35137) | Fix license in `pyproject.toml` | -| 5.2.3 | 2024-02-09 | [35068](https://github.com/airbytehq/airbyte/pull/35068) | Manage dependencies with Poetry. | -| 5.2.2 | 2024-01-31 | [34619](https://github.com/airbytehq/airbyte/pull/34619) | Events stream concurrent on incremental syncs | -| 5.2.1 | 2024-01-18 | [34495](https://github.com/airbytehq/airbyte/pull/34495) | Fix deadlock issue | +|:--------|:-----------|:----------------------------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| 5.6.0 | 2024-09-10 | [44891](https://github.com/airbytehq/airbyte/pull/44891) | Update `Payment Methods` stream | +| 5.5.4 | 2024-09-09 | [45348](https://github.com/airbytehq/airbyte/pull/45348) | Remove `stripe` python package | +| 5.5.3 | 2024-09-03 | [45101](https://github.com/airbytehq/airbyte/pull/45101) | Fix regression following pagination issue fix | +| 5.5.2 | 2024-08-28 | [44862](https://github.com/airbytehq/airbyte/pull/44862) | Fix RFR pagination issue | +| 5.5.1 | 2024-08-10 | [43105](https://github.com/airbytehq/airbyte/pull/43105) | Update dependencies | +| 5.5.0 | 2024-08-08 | [43302](https://github.com/airbytehq/airbyte/pull/43302) | Fix problem with state not updating and upgrade cdk 4 | +| 5.4.12 | 2024-07-31 | [41985](https://github.com/airbytehq/airbyte/pull/41985) | Expand Invoice discounts and tax rates | +| 5.4.11 | 2024-07-27 | [42623](https://github.com/airbytehq/airbyte/pull/42623) | Update dependencies | +| 5.4.10 | 2024-07-20 | [42305](https://github.com/airbytehq/airbyte/pull/42305) | Update dependencies | +| 5.4.9 | 2024-07-13 | [41760](https://github.com/airbytehq/airbyte/pull/41760) | Update dependencies | +| 5.4.8 | 2024-07-10 | [41477](https://github.com/airbytehq/airbyte/pull/41477) | Update dependencies | +| 5.4.7 | 2024-07-09 | [40869](https://github.com/airbytehq/airbyte/pull/40869) | Update dependencies | +| 5.4.6 | 2024-07-08 | [41044](https://github.com/airbytehq/airbyte/pull/41044) | Use latest `CDK` version possible | +| 5.4.5 | 2024-06-25 | [40404](https://github.com/airbytehq/airbyte/pull/40404) | Update dependencies | +| 5.4.4 | 2024-06-22 | [40040](https://github.com/airbytehq/airbyte/pull/40040) | Update dependencies | +| 5.4.3 | 2024-06-06 | [39284](https://github.com/airbytehq/airbyte/pull/39284) | [autopull] Upgrade base image to v1.2.2 | +| 5.4.2 | 2024-06-11 | [39412](https://github.com/airbytehq/airbyte/pull/39412) | Removed `invoice.upcomming` event type from (incremental sync) for `Invoices` stream | +| 5.4.1 | 2024-06-11 | [39393](https://github.com/airbytehq/airbyte/pull/39393) | Added missing `event types` (incremental sync) for `Invoices` stream | +| 5.4.0 | 2024-06-05 | [39138](https://github.com/airbytehq/airbyte/pull/39138) | Fixed the `Refunds` stream missing data for the `incremental` sync | +| 5.3.9 | 2024-05-22 | [38550](https://github.com/airbytehq/airbyte/pull/38550) | Update authenticator package | +| 5.3.8 | 2024-05-15 | [38248](https://github.com/airbytehq/airbyte/pull/38248) | Replace AirbyteLogger with logging.Logger | +| 5.3.7 | 2024-04-24 | [36663](https://github.com/airbytehq/airbyte/pull/36663) | Schema descriptions | +| 5.3.6 | 2024-04-18 | [37448](https://github.com/airbytehq/airbyte/pull/37448) | Ensure AirbyteTracedException in concurrent CDK are emitted with the right type | +| 5.3.5 | 2024-04-18 | [37418](https://github.com/airbytehq/airbyte/pull/37418) | Ensure python return code != 0 in case of error | +| 5.3.4 | 2024-04-11 | [37406](https://github.com/airbytehq/airbyte/pull/37406) | Update CDK version to have partitioned state fix | +| 5.3.3 | 2024-04-11 | [37001](https://github.com/airbytehq/airbyte/pull/37001) | Update airbyte-cdk to flush print buffer for every message | +| 5.3.2 | 2024-04-11 | [36964](https://github.com/airbytehq/airbyte/pull/36964) | Update CDK version to fix breaking change before another devs work on it | +| 5.3.1 | 2024-04-10 | [36960](https://github.com/airbytehq/airbyte/pull/36960) | Remove unused imports | +| 5.3.0 | 2024-03-12 | [35978](https://github.com/airbytehq/airbyte/pull/35978) | Upgrade CDK to start emitting record counts with state and full refresh state | +| 5.2.4 | 2024-02-12 | [35137](https://github.com/airbytehq/airbyte/pull/35137) | Fix license in `pyproject.toml` | +| 5.2.3 | 2024-02-09 | [35068](https://github.com/airbytehq/airbyte/pull/35068) | Manage dependencies with Poetry. | +| 5.2.2 | 2024-01-31 | [34619](https://github.com/airbytehq/airbyte/pull/34619) | Events stream concurrent on incremental syncs | +| 5.2.1 | 2024-01-18 | [34495](https://github.com/airbytehq/airbyte/pull/34495) | Fix deadlock issue | | 5.2.0 | 2024-01-18 | [34347](https://github.com/airbytehq/airbyte/pull//34347) | Add new fields invoices and subscription streams. Upgrade the CDK for better memory usage. | | 5.1.3 | 2023-12-18 | [33306](https://github.com/airbytehq/airbyte/pull/33306/) | Adding integration tests | | 5.1.2 | 2024-01-04 | [33414](https://github.com/airbytehq/airbyte/pull/33414) | Prepare for airbyte-lib | diff --git a/docs/integrations/sources/zendesk-support.md b/docs/integrations/sources/zendesk-support.md index b6aa46fd52ae2..55ee7060363ce 100644 --- a/docs/integrations/sources/zendesk-support.md +++ b/docs/integrations/sources/zendesk-support.md @@ -114,6 +114,7 @@ The Zendesk Support source connector supports the following streams: - [Article Comment Votes](https://developer.zendesk.com/api-reference/help_center/help-center-api/votes/#list-votes) \(Incremental\) - [Attribute Definitions](https://developer.zendesk.com/api-reference/ticketing/ticket-management/skill_based_routing/#list-routing-attribute-definitions) - [Audit Logs](https://developer.zendesk.com/api-reference/ticketing/account-configuration/audit_logs/#list-audit-logs)\(Incremental\) (Only available for enterprise accounts) +- [Automations](https://developer.zendesk.com/api-reference/ticketing/business-rules/automations/#list-automations) - [Brands](https://developer.zendesk.com/api-reference/ticketing/account-configuration/brands/#list-brands) - [Custom Roles](https://developer.zendesk.com/api-reference/ticketing/account-configuration/custom_roles/#list-custom-roles) \(Incremental\) - [Groups](https://developer.zendesk.com/rest_api/docs/support/groups) \(Incremental\) @@ -138,6 +139,7 @@ The Zendesk Support source connector supports the following streams: - [Ticket Metrics](https://developer.zendesk.com/rest_api/docs/support/ticket_metrics) \(Incremental\) - [Ticket Metric Events](https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_metric_events/) \(Incremental\) - [Topics](https://developer.zendesk.com/api-reference/help_center/help-center-api/topics/#list-topics) \(Incremental\) +- [Triggers](https://developer.zendesk.com/api-reference/ticketing/business-rules/triggers/#list-ticket-triggers) \(Incremental\) - [Ticket Skips](https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_skips/) \(Incremental\) - [Users](https://developer.zendesk.com/api-reference/ticketing/ticket-management/incremental_exports/#incremental-user-export) \(Incremental\) - [UserFields](https://developer.zendesk.com/api-reference/ticketing/users/user_fields/#list-user-fields) @@ -182,6 +184,7 @@ The Zendesk connector ideally should not run into Zendesk API limitations under | Version | Date | Pull Request | Subject | |:--------|:-----------|:---------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| 4.2.0 | 2024-09-10 | [44610](https://github.com/airbytehq/airbyte/pull/44610) | Add `Automations` and `Triggers` stream | | 4.1.1 | 2024-09-07 | [45215](https://github.com/airbytehq/airbyte/pull/45215) | Update dependencies | | 4.1.0 | 2024-09-06 | [45187](https://github.com/airbytehq/airbyte/pull/45187) | Migrate to CDK v5 | | 4.0.2 | 2024-08-31 | [44965](https://github.com/airbytehq/airbyte/pull/44965) | Update dependencies |